gimp-print-vl.spec 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296
  1. # To bootstrap:
  2. # build this first without IJS support
  3. # build ghostscript
  4. # build this with IJS support re-enabled
  5. %define build_with_ijs_support 1
  6. %define build_with_cups_support 0
  7. %define build_with_plugin_support 1
  8. %define build_with_utils_support 1
  9. Summary: A collection of high-quality printer drivers.
  10. Summary(ja): ハイクオリティプリンタドライバ集
  11. Name: gimp-print
  12. Version: 4.2.7
  13. Release: 1%{?_dist_release}
  14. License: GPL
  15. Group: System Environment/Libraries
  16. URL: http://gimp-print.sourceforge.net/
  17. Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
  18. Patch0: gimp-print-4.2.1-no-kitload.patch
  19. Patch1: gimp-print-C8x.patch
  20. Patch2: gimp-print-4.2.5-print.patch
  21. Patch4: gimp-print-4.2.6-gimp2.patch
  22. Patch5: gimp-print-plugindir.patch
  23. Patch6: gimp-print-4.2.6-mkinstalldirs.patch
  24. Patch7: gimp-print-textdomain.patch
  25. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  26. %if %{build_with_ijs_support}
  27. BuildRequires: ghostscript-devel
  28. %endif
  29. BuildRequires: gimp-devel >= 2.0
  30. %description
  31. These drivers provide printing quality for UNIX/Linux in many cases equal
  32. to or better than proprietary vendor-supplied drivers, and can be used for
  33. many of the most demanding printing tasks.
  34. %package devel
  35. Summary: Files for developing applications that use gimp-print.
  36. Requires: %{name} = %{version}
  37. Group: Development/Libraries
  38. %description devel
  39. The header files, static library, libtool library and man pages for
  40. developing applications that use gimp-print.
  41. %if %{build_with_utils_support}
  42. %package utils
  43. Summary: Utility programs from gimp-print
  44. Summary(ja): gimp-print 用ユーティリティプログラム
  45. Requires: %{name} = %{version}
  46. Group: Applications/Publishing
  47. %description utils
  48. This package contains the escputil program.
  49. %endif
  50. %if %{build_with_plugin_support}
  51. %package plugin
  52. Summary: GIMP plug-in for gimp-print
  53. Summary(ja): GIMP用 gimp-print プラグイン
  54. Requires: %{name} = %{version}
  55. Requires: gimp >= 2.0
  56. Group: System Environment/Libraries
  57. %description plugin
  58. This package contains the gimp-print GIMP plug-in.
  59. %endif
  60. %if %{build_with_cups_support}
  61. %package -n gimp-print-cups
  62. Summary: CUPS drivers for Canon, Epson, HP and compatible printers
  63. Requires: cups >= 1.1.17
  64. BuildRequires: cups-devel
  65. Group: Applications/Publishing
  66. %description -n gimp-print-cups
  67. gimp-print-cups provides native CUPS support for a wide range of Canon,
  68. Epson, HP and compatible printers.
  69. %endif
  70. %prep
  71. %setup -q
  72. %patch0 -p1 -b .no-kitload
  73. %patch1 -p1 -b .C8x
  74. %patch2 -p1 -b .print
  75. %patch4 -p1 -b .gimp2
  76. %patch5 -p1 -b .plugindir
  77. %patch6 -p1 -b .mkinstalldirs
  78. %patch7 -p1 -b .textdomain
  79. %build
  80. libtoolize --force --copy
  81. aclocal
  82. autoconf
  83. %if %{build_with_ijs_support}
  84. %if %{build_with_cups_support}
  85. %configure --with-ijs --with-foomatic --with-cups --with-gimp --without-ghost
  86. %else
  87. %configure --with-ijs --with-foomatic --without-cups --with-gimp --without-ghost
  88. %endif
  89. %else
  90. %configure --without-ijs --with-foomatic --without-cups --with-gimp --without-ghost
  91. %endif
  92. make CFLAGS="$RPM_OPT_FLAGS"
  93. %install
  94. rm -rf %{buildroot}
  95. %makeinstall cups_prefix=%{buildroot}%{_prefix} \
  96. cups_exec_prefix=%{buildroot}%{_exec_prefix} \
  97. cups_bindir=%{buildroot}%{_bindir} \
  98. cups_conf_datadir=%{buildroot}%{_datadir}/cups \
  99. cups_conf_serverbin=%{buildroot}%{_libdir}/cups \
  100. cups_conf_serverroot=%{buildroot}%{_sysconfdir}/cups
  101. %if %{build_with_plugin_support}
  102. for ver in %{_libdir}/gimp/*
  103. do
  104. mkdir -p %{buildroot}$ver/plug-ins
  105. install -m0755 src/gimp/.libs/print %{buildroot}$ver/plug-ins/print
  106. done
  107. %endif
  108. # Don't install this, since we don't list it in the manifest.
  109. rm -f %{buildroot}%{_infodir}/dir
  110. %find_lang %{name}
  111. %clean
  112. rm -rf %{buildroot}
  113. %files -f %{name}.lang
  114. %defattr(-,root,root)
  115. %doc README COPYING
  116. %{_libdir}/*.so.*
  117. %{_infodir}/gimpprint*
  118. %{_datadir}/gimp-print
  119. %if %{build_with_ijs_support}
  120. %{_bindir}/ijsgimpprint
  121. %{_mandir}/man1/ijsgimpprint.1*
  122. %endif
  123. %{_mandir}/man7/*
  124. %if %{build_with_plugin_support}
  125. %files plugin
  126. %defattr(-,root,root)
  127. %{_libdir}/gimp/*/plug-ins/print
  128. %endif
  129. %if %{build_with_utils_support}
  130. %files utils
  131. %defattr(-,root,root)
  132. %{_bindir}/escputil
  133. %{_mandir}/man1/escputil.1*
  134. %endif
  135. %files devel
  136. %defattr(-,root,root)
  137. %dir %{_includedir}/%{name}
  138. %{_includedir}/%{name}/*.h
  139. %{_libdir}/*.a
  140. %{_libdir}/*.so
  141. %{_libdir}/*.la
  142. %{_bindir}/gimpprint-config
  143. %{_mandir}/man1/gimpprint-config.1*
  144. %{_mandir}/man3/*
  145. %{_datadir}/aclocal/gimpprint.m4
  146. %if %{build_with_cups_support}
  147. %files cups
  148. %defattr(-,root,root)
  149. %{_mandir}/man8/cups-calibrate.8*
  150. %{_libdir}/cups/backend/*
  151. %{_libdir}/cups/filter/*
  152. %{_bindir}/cups-calibrate
  153. %{_datadir}/cups/calibrate.ppm
  154. %dir %{_datadir}/cups/model/*
  155. %{_datadir}/cups/model/*/*
  156. %config %{_sysconfdir}/cups/*
  157. %endif
  158. %post
  159. /sbin/ldconfig
  160. /sbin/install-info /usr/share/info/gimpprint.info.gz /usr/share/info/dir
  161. %postun
  162. /sbin/ldconfig
  163. if [ $1 = 0 ]; then
  164. /sbin/install-info --delete /usr/share/info/gimpprint.info.gz /usr/share/info/dir
  165. fi
  166. %if %{build_with_cups_support}
  167. %post -n gimp-print-cups
  168. /sbin/install-info /usr/share/info/gimpprint.info.gz /usr/share/info/dir
  169. /sbin/ldconfig
  170. if [ $1 -eq 1 ]; then
  171. # First install.
  172. /sbin/service cups reload >/dev/null 2>&1 || :
  173. fi
  174. exit 0
  175. %preun -n gimp-print-cups
  176. if [ $1 = 0 ]; then
  177. /sbin/install-info --delete /usr/share/info/gimpprint.info.gz /usr/share/info/dir
  178. fi
  179. %postun -n gimp-print-cups
  180. /sbin/ldconfig
  181. if [ "$1" -ge "1" ]; then
  182. /sbin/service cups reload >/dev/null 2>&1 || :
  183. fi
  184. exit 0
  185. %endif
  186. %changelog
  187. * Wed Oct 29 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 4.2.7-1
  188. - rebuild with ghostscript-8.63
  189. - new versioning policy, spec in utf-8
  190. * Sun Apr 16 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.2.7-0vl2
  191. - rebuilt with readline 5.1
  192. * Fri Jul 30 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 4.2.7-0vl1
  193. - new upstream release
  194. - import Patches from fedora's gimp-print-4.2.7-1
  195. - add Japanese Summaries
  196. * Thu Apr 17 2003 Satoshi MACHINO <machino@vinelinux.org> 4.2.5-0vl4
  197. - rebuild gimp-1.2.3-0vl4 and ghostscript-7.06-0vl1
  198. * Thu Mar 13 2003 Satoshi MACHINO <machino@vinelinux.org> 4.2.5-0vl3
  199. - Ships the gimp print plug-in
  200. -- enable plugin/utils support
  201. * Sun Mar 2 2003 Satoshi MACHINO <machino@vinelinux.org> 4.2.5-0vl2
  202. - Enable IJS support
  203. - fixed spec file
  204. -- disable {cups, plugin, utils}_support
  205. * Sat Mar 1 2003 Satoshi MACHINO <machino@vinelinux.org> 4.2.5-0vl1
  206. - New upstream version
  207. - added patch1
  208. - dropped patch2
  209. * Sat Mar 1 2003 Satoshi MACHINO <machino@vinelinux.org> 4.2.4-5vl1
  210. - build for VineLinux
  211. -- without IJS support
  212. * Fri Jan 24 2003 Tim Waugh <twaugh@redhat.com> 4.2.4-5
  213. - Use 'reload' not 'condrestart' for cups.
  214. - Reload cups on first install as well as upgrade (part of bug #82500).
  215. * Wed Jan 22 2003 Tim Powers <timp@redhat.com> 4.2.4-4
  216. - rebuilt
  217. * Tue Jan 7 2003 Nalin Dahyabhai <nalin@redhat.com> 4.2.4-3
  218. - Rebuild
  219. * Tue Dec 19 2002 Tim Waugh <twaugh@redhat.com> 4.2.4-2
  220. - Add plugin subpackage.
  221. * Tue Nov 26 2002 Tim Waugh <twaugh@redhat.com> 4.2.4-1
  222. - 4.2.4.
  223. - Ship more man pages.
  224. * Sun Nov 17 2002 Tim Waugh <twaugh@redhat.com> 4.2.3-2
  225. - Fix print plug-in.
  226. * Thu Nov 7 2002 Tim Waugh <twaugh@redhat.com> 4.2.3-1
  227. - 4.2.3.
  228. - No longer need the ijsparam patch.
  229. - Ship the man page for ijsgimpprint.
  230. * Wed Nov 6 2002 Tim Waugh <twaugh@redhat.com> 4.2.1-6
  231. - Don't install files not shipped.
  232. - Build gimp plug-in.
  233. - Add a mechanism for bootstrapping.
  234. * Thu Jul 18 2002 Tim Waugh <twaugh@redhat.com> 4.2.1-5
  235. - Make the cups package own some directories.
  236. * Tue Jul 16 2002 Tim Waugh <twaugh@redhat.com> 4.2.1-4
  237. - Fix PS:Duplex problems.
  238. * Fri Jun 21 2002 Tim Powers <timp@redhat.com> 4.2.1-3
  239. - automated rebuild
  240. * Sun May 26 2002 Tim Powers <timp@redhat.com> 4.2.1-2
  241. - automated rebuild
  242. * Mon May 20 2002 Tim Waugh <twaugh@redhat.com> 4.2.1-1
  243. - Enable IJS support.
  244. * Mon May 20 2002 Tim Waugh <twaugh@redhat.com> 4.2.1-0.1
  245. - Initial package.