Author: thl
Update of /cvs/nonfree/rpms/gsview/devel
In directory se02.es.rpmfusion.net:/tmp/cvs-serv1034
Modified Files:
.cvsignore sources
Added Files:
gsview-4.4-xdg_open.patch gsview-4.7-dllversion.patch
gsview-4.7-letterpaper.patch gsview-4.8-libgs.patch
gsview.desktop gsview.spec
Log Message:
import version from free and release++
gsview-4.4-xdg_open.patch:
--- NEW FILE gsview-4.4-xdg_open.patch ---
--- gsview-4.4/srcunx/gvxreg.c.htmlview 2001-10-05 03:48:14.000000000 -0500
+++ gsview-4.4/srcunx/gvxreg.c 2003-04-28 11:28:15.000000000 -0500
@@ -76,7 +76,7 @@
{
if (debug & DEBUG_GENERAL)
gs_addmess("online_reg:\n");
- exec_program("netscape", "http://www.ghostgum.com.au/");
+ exec_program("xdg-open", "http://www.ghostgum.com.au/");
}
void modal_reg(GtkWidget *w, gpointer data)
--- gsview-4.4/srcunx/gvxhelp.txt.htmlview 2003-03-14 15:45:52.000000000 -0600
+++ gsview-4.4/srcunx/gvxhelp.txt 2003-04-28 11:29:54.000000000 -0500
@@ -18,11 +18,7 @@
TAG="#$2"
fi
-if mozilla -remote openFile\(file://$1$TAG\) ; then
- exit 0
-else
- mozilla file://$1$TAG
-fi
+xdg-open file://$1\$TAG
exit 0
gsview-4.7-dllversion.patch:
--- NEW FILE gsview-4.7-dllversion.patch ---
--- gsview-4.7/src/cdll.c.dllversion 2002-02-09 21:46:38.000000000 -0600
+++ gsview-4.7/src/cdll.c 2005-06-23 09:05:39.000000000 -0500
@@ -106,6 +106,10 @@
}
dll->revision_number = rv.revision;
+ /* Hack because FC5's ghostscript-8.15 reports 81500 instead of 815 -- Rex */
+ if ( dll->revision_number > (GS_REVISION_MIN*100) )
+ dll->revision_number = (long)(dll->revision_number / 100);
+
if ( (dll->revision_number < GS_REVISION_MIN) ||
(dll->revision_number > GS_REVISION_MAX) ) {
gs_addmessf("\nWrong version of DLL found.\n\
gsview-4.7-letterpaper.patch:
--- NEW FILE gsview-4.7-letterpaper.patch ---
--- gsview-4.7/src/gvcinit.c.letterpaper 2005-03-01 03:51:38.000000000 -0600
+++ gsview-4.7/src/gvcinit.c 2005-06-23 10:41:42.000000000 -0500
@@ -319,13 +319,13 @@
option.button_show = TRUE;
option.fit_page = FALSE; /* Changed after 2.1 */
option.safer = TRUE;
- option.media = IDM_A4;
- strcpy(option.medianame, "A4");
+ option.media = IDM_LETTER;
+ strcpy(option.medianame, "Letter");
option.media_rotate = FALSE;
option.user_width_warn = 5669; /* 2 metres */
option.user_height_warn = 5669;
- option.user_width = 595; /* A4 width 210mm */
- option.user_height = 842; /* A4 height 297mm */
+ option.user_width = 612; /* Letter width 8.5in */
+ option.user_height = 792; /* Letter height 11in */
option.epsf_clip = FALSE;
option.epsf_warn = FALSE;
option.ignore_dsc = FALSE;
gsview-4.8-libgs.patch:
--- NEW FILE gsview-4.8-libgs.patch ---
--- gsview-4.8/src/gvcver.h.libgs 2006-02-24 05:24:42.000000000 -0600
+++ gsview-4.8/src/gvcver.h 2006-05-07 20:43:57.000000000 -0500
@@ -57,7 +57,7 @@
/* Ghostscript */
#define GS_PRODUCT "AFPL Ghostscript"
#define GS_REVISION_MIN 704
-#define GS_REVISION 704
+#define GS_REVISION @@GS_REVISION@@
#define GS_REVISION_MAX 999
#ifdef _Windows
@@ -76,7 +76,7 @@
#if X11
#define INIFILE "gsview.ini"
#define GS_EXENAME "gs"
-#define GS_DLLNAME "libgs.so"
+#define GS_DLLNAME "libgs.so.@@SOMAJOR@@"
#else
#define GS_EXENAME "gsos2.exe"
#define GS_DLLNAME "gsdll2.dll"
--- NEW FILE gsview.desktop ---
[Desktop Entry]
Encoding=UTF-8
Name=GSview
GenericName=PS/PDF Viewer
Comment=EPS,PDF,PS Viewer
Exec=gsview
Icon=gsview
Terminal=false
Type=Application
MimeType=image/x-eps;application/postscript;application/pdf;
Categories=GTK;Graphics;Viewer;Publishing;
StartupWMClass=gsview
--- NEW FILE gsview.spec ---
Summary: PostScript and PDF previewer
Name: gsview
Version: 4.9
Release: 2%{?dist}
License: AFPL
Group: Applications/Publishing
Source:
ftp://mirror.cs.wisc.edu/pub/mirrors/ghost/ghostgum/gsview-%{version}.tar.gz
URL:
http://www.cs.wisc.edu/~ghost/gsview/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Source1: gsview.desktop
BuildRequires: gtk+-devel
BuildRequires: desktop-file-utils
BuildRequires: sed >= 4.0
BuildRequires: ghostscript-devel >= 7.07-15.3
%global gs_ver %(gs --version 2> /dev/null | cut -d. -f-2 )
%global gs_ver1 %(echo %{gs_ver} | cut -d. -f1 )
%if 0%{?gs_ver1} == 7
# See
http://www.redhat.com/archives/fedora-devel-list/2004-August/msg00068.html
Requires: ghostscript >= 7.07-15.3
%endif
Requires: xdg-utils
## Use xdg-open instead of hard-coded mozilla
Patch1: gsview-4.4-xdg_open.patch
# default to libgs.so.@@SOMAJOR@@ instead of libgs.so
Patch2: gsview-4.8-libgs.patch
# attempt to allow/use ghostscript-8.15 reported value of 81500.
#
http://bugzilla.redhat.com/159912
Patch3: gsview-4.7-dllversion.patch
# Change Paper default A4 -> Letter
Patch4: gsview-4.7-letterpaper.patch
%description
GSview is a graphical interface for Ghostscript.
Ghostscript is an interpreter for the PostScript page
description language used by laser printers.
For documents following the Adobe PostScript Document Structuring
Conventions, GSview allows selected pages to be viewed or printed.
%prep
%setup -q
%patch1 -p1 -b .xdg_open
# patch2 bits below
%patch3 -p1 -b .dllversion
%patch4 -p1 -b .letterpaper
# Determine GS_REVISION/SOMAJOR and substitute values (see patch2)
%patch2 -p1 -b .libgs
GS_REVISION=%(echo %{gs_ver} | tr -d '.' )
sed -i -e "s|@@GS_REVISION@@|${GS_REVISION}|g" src/gvcver.h
# Sanity check to make sure file exists
if [ ! -f "%(ls %{_libdir}/libgs.so.?)" ]; then
echo "Error: %{_libdir}/libgs.so.? doesn't exist"; exit 1
fi
SOMAJOR=$(basename %{_libdir}/libgs.so.? | sed -e 's@libgs.so.@(a)' )
sed -i -e "s|@@SOMAJOR@@|${SOMAJOR}|g" src/gvcver.h
%build
make -f srcunx/unx.mak \
RPM_OPT_FLAGS="%{!?debug_package:-g0} $RPM_OPT_FLAGS" \
GSVIEW_BASE=%{_prefix} \
GSVIEW_BINDIR=%{_bindir} \
GSVIEW_MANDIR=%{_mandir} \
GSVIEW_DOCPATH=%{_docdir} \
GSVIEW_ETCPATH=%{_sysconfdir}
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir},%{_docdir},%{_sysconfdir}}
make -f srcunx/unx.mak install \
GSVIEW_BASE=$RPM_BUILD_ROOT%{_prefix} \
GSVIEW_BINDIR=$RPM_BUILD_ROOT%{_bindir} \
GSVIEW_MANDIR=$RPM_BUILD_ROOT%{_mandir} \
GSVIEW_DOCPATH=$RPM_BUILD_ROOT%{_docdir} \
GSVIEW_ETCPATH=$RPM_BUILD_ROOT%{_sysconfdir}
# desktop/icon files
install -D -p -m644 binary/gsview48.png\
$RPM_BUILD_ROOT%{_datadir}/icons/hicolor/48x48/apps/gsview.png
desktop-file-install \
--dir="$RPM_BUILD_ROOT%{_datadir}/applications" \
--vendor="" \
%{SOURCE1}
## Unpackaged files
# nuke deprecated epstool, when (hopefully) packaged separately... someday.
#rm -f $RPM_BUILD_ROOT{%{_bindir}/epstool,%{_docdir}/*/epstool*}
%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null ||:
%postun
if [ $1 -eq 0 ] ; then
touch --no-create %{_datadir}/icons/hicolor &> /dev/null ||:
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null ||:
update-desktop-database -q %{_datadir}/applications > /dev/null 2>&1 || :
fi
%posttrans
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null ||:
update-desktop-database -q %{_datadir}/applications > /dev/null 2>&1 || :
%files
%defattr(-, root, root)
%{_bindir}/*
%dir %{_sysconfdir}/gsview
%config(noreplace) %{_sysconfdir}/gsview/printer.ini
%{_mandir}/man*/*
%{_datadir}/applications/*.desktop
%{_datadir}/icons/hicolor/*/*/*
%doc %{_docdir}/*
%clean
rm -rf $RPM_BUILD_ROOT
%changelog
* Wed Nov 11 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.9-2
- rebuild after movement to RPM Fusion nonfree
* Thu Oct 22 2009 Rex Dieter <rdieter(a)fedoraproject.org> 4.9-1
- gsview-4.9
- optimize scriptlets
- use xdg-open (instead of htmlview)
* Sun Mar 29 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.8-5
- rebuild for new F11 features
* Mon Sep 15 2008 Rex Dieter <rdieter(a)fedoraproject.org> 4.8-4
- cleanup .desktop file bits
* Sun Aug 03 2008 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info - 4.8-3
- rebuild
* Tue Oct 10 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.8-2
- respin
* Sun May 07 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.8-1
- 4.8
* Mon Apr 17 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-7
- rework for Livna
* Wed Mar 1 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-6
- %%(rpm -q --qf '%%{VERSION}' ghostscript) -> %%(gs --version)
- follow fdo icon spec
- restore epstool bits
* Fri Feb 10 2006 Rex Dieter <rexdieter[AT]users.sf.net>
- fc5: gcc/glibc respin
* Fri Oct 21 2005 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-5
- %%post/%%postun: update-desktop-database
* Fri Aug 5 2005 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-4
- ExcludeArch: ppc (sed busted?)
* Thu Jul 28 2005 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-3
- add file:// to help URL.
* Thu Jun 23 2005 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-2
- fixes for ghostscript-8.15 (#159912)
- Change paper default A4->Letter
* Wed Apr 20 2005 Rex Dieter <rexdieter[AT]users.sf.net> 4.7-1
- 4.7
* Fri Apr 7 2005 Michael Schwendt <mschwendt[AT]users.sf.net>
- rebuilt
* Wed Jan 26 2005 Rex Dieter <rexdieter[AT]users.sf.net> 0:4.6-9
- back to Req: ghostscript >= 7.07-15.3 for x86_64 (#146223)
* Fri Aug 06 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.8
- Patch to load libgs.so.7 by default (instead of libgs.so)
- Req: libgs.so.7, dropping Req: ghostscript, allowing for users
with older/custom ghostscript builds (will have to rework when/if
ghostscript >= 8.0 comes)
- .desktop: GenericName: PS/PDF Viewer
* Thu Aug 05 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.7
- remove Req: libgs.so
- Req: ghostscript >= 7.07-15.3
(
http://www.redhat.com/archives/fedora-devel-list/2004-August/msg00068.html)
* Tue Aug 03 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.6
- Requires: ghostscript >= 7.07-18
* Thu Apr 29 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.5
- Group: Applications/Publishing
- remove Vendor tag
* Sat Apr 24 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.4
- gsview.desktop: StartupWMClass=gsview
* Sat Apr 24 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.3
- don't include old epstool (to be packaged separately)
- gsview.desktop:
MimeType=image/x-eps;application/postscript;application/pdf;
Categories=Application;GTK;Graphics;Viewer;Publishing;
* Thu Apr 01 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.2
- desktop-file default
- patch default .desktop file for Categories
* Tue Jan 20 2004 Rex Dieter <rexdieter at sf.net> 0:4.6-0.fdr.1
- 4.6
- desktop_file'ize
* Fri Oct 31 2003 Rex Dieter <rexdieter at sf.net> 0:4.5-0.fdr.1
- 4.5
- Fedora Core support
* Thu Jul 03 2003 Rex Dieter <rexdieter at sf.net> 0:4.4-0.fdr.0
- fedora'ize
- htmlview patch
Index: .cvsignore
===================================================================
RCS file: /cvs/nonfree/rpms/gsview/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 11 Nov 2009 19:37:43 -0000 1.1
+++ .cvsignore 11 Nov 2009 19:40:43 -0000 1.2
@@ -0,0 +1 @@
+gsview-4.9.tar.gz
Index: sources
===================================================================
RCS file: /cvs/nonfree/rpms/gsview/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 11 Nov 2009 19:37:43 -0000 1.1
+++ sources 11 Nov 2009 19:40:43 -0000 1.2
@@ -0,0 +1 @@
+96ca9460c8bd86ef20d881554331d72f gsview-4.9.tar.gz