xsane-vl.spec 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. %define gimpdirs %(/bin/ls -d %{_libdir}/gimp/*/plug-ins 2> /dev/null)
  2. Name: xsane
  3. Summary: XSane is a graphical frontend for scanners. It uses the library SANE.
  4. Summary: SANE スキャナインタフェースの Xウィンドウ用フロントエンドです
  5. Version: 0.997
  6. Release: 1%{?_dist_release}
  7. Source: http://www.xsane.org/download/%{name}-%{version}.tar.gz
  8. %{?nosrc:NoSource: 0}
  9. License: GPL
  10. URL: http://www.xsane.org/
  11. Group: Applications/Multimedia
  12. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  13. Requires: sane >= 1.0.0, gtk2, glib2, atk, pango, zlib
  14. BuildRequires: sane-devel, gtk2-devel, atk-devel, pango-devel
  15. BuildRequires: gimp >= 1.3.23
  16. BuildRequires: libjpeg-devel, libpng-devel, libtiff-devel,zlib-devel
  17. BuildRequires: sed, glibc-common
  18. BuildRequires: gimp-devel
  19. %description
  20. Xsane is a grahical frontend for sane. Install this if you want a grahpical
  21. frontend for sane for use in the X Windowing System.
  22. %description -l ja
  23. XSane は、多くのスキャナ、デジタルカメラ、その他の画像取り込み装置に対応
  24. した SANE スキャナインタフェースの Xウィンドウ用フロントエンドです。
  25. XSane は GTK+ で書かれ、画像取り込みや取込み画像の操作を行うことができま
  26. す。
  27. %prep
  28. %setup -q
  29. # correct some links in html documents
  30. cd doc
  31. DOCFILE=sane-backends-doc.html
  32. cat ${DOCFILE} | sed 's,/usr/local/share,%{_datadir},' > ${DOCFILE}.new
  33. [ -f ${DOCFILE}.new ] && mv -f ${DOCFILE}.new ${DOCFILE}
  34. DOCFILE=sane-xsane-gimp-doc.html
  35. cat ${DOCFILE} | sed 's,/usr/local/bin,%{_bindir},' > ${DOCFILE}.new
  36. [ -f ${DOCFILE}.new ] && mv -f ${DOCFILE}.new ${DOCFILE}
  37. ICONFILE=sane-logo2.jpg
  38. [ -f %{_datadir}/sane/${ICONFILE} ] && cp %{_datadir}/sane/${ICONFILE} ./
  39. %build
  40. %configure
  41. %{__make} %{?_smp_mflags}
  42. %install
  43. %__rm -rf $RPM_BUILD_ROOT
  44. %{__make} install DESTDIR=${RPM_BUILD_ROOT}
  45. cp src/*.xpm $RPM_BUILD_ROOT%{_datadir}/sane/%{name}
  46. if (echo "%{gimpdirs}" | grep -q plug-ins) ;then
  47. for D in %{gimpdirs} ; do
  48. mkdir -p $RPM_BUILD_ROOT${D}
  49. %__ln_s -f %{_bindir}/xsane $RPM_BUILD_ROOT${D}/xsane
  50. done
  51. fi
  52. # prepare applnk
  53. %define applnkdir /etc/X11/applnk/Graphics
  54. %define icondir %{_datadir}/sane/%{name}
  55. mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
  56. cat > $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop <<EOF
  57. [Desktop Entry]
  58. Encoding=UTF-8
  59. Name=XSane
  60. Name[ja]=XSane スキャナ操作
  61. Comment=Scanner program
  62. Comment[ja]=スキャナを操作するツールです
  63. Terminal=false
  64. Type=Application
  65. Icon=%{icondir}/xsane-48x48.xpm
  66. Exec=xsane
  67. MultipleArgs=false
  68. Categories=Application;Graphics;
  69. EOF
  70. %find_lang %{name}
  71. %clean
  72. rm -rf $RPM_BUILD_ROOT
  73. %files -f %{name}.lang
  74. %defattr(-,root,root)
  75. %doc xsane.*
  76. %{_bindir}/*
  77. %{_mandir}/*/*
  78. %{_datadir}/sane/*
  79. %{_libdir}/gimp/*/plug-ins/*
  80. %{_datadir}/pixmaps/xsane.xpm
  81. %config(missingok) %{_datadir}/applications/*
  82. %changelog
  83. * Sun Jul 25 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.997-1
  84. - new upstream release
  85. - add BuildRequires: gimp-devel
  86. - remove configure option (--enable-gimp)
  87. - fix %files
  88. * Sat Jul 26 2008 Shu KONNO <owa@bg.wakwak.com> 0.995-1vl5
  89. - applied new versioning policy
  90. - updated script to create %{name}.desktop
  91. * Mon Dec 24 2007 Shu KONNO <owa@bg.wakwak.com> 0.995-0vl1
  92. - new upstream
  93. - updated xsane.desktop
  94. * Sat Jan 08 2005 Satoshi MACHINO <machino@vinelinux.org> 0.96-0vl1
  95. - new upstream version (xsane-0.96)
  96. - fixed spec file
  97. -- cleaned up
  98. -- added Requires: sane >= 1.0.0, gtk2, glib2, atk, pango, zlib
  99. -- added BuildRequires: sane-devel, gtk2-devel, atk-devel, pango-devel
  100. -- added BuildRequires: gimp >= 1.3.23
  101. -- added BuildRequires: libjpeg-devel, libpng-devel, libtiff-devel,zlib-devel
  102. * Fri Oct 25 2002 Tomoya TAKA <taka@vinelinux.org> 0.89-0vl1
  103. - new upstream release
  104. * Mon May 13 2002 Satoshi MACHINO <machino@vinelinux.org> xsane-0.86-0vl1
  105. - updated xsane-0.86
  106. * Wed Apr 4 2002 Masaki Shinomiya <shino@pos.to>
  107. - 0.84-0vl1 for Vine Linux-2.x
  108. - 0.84-0.1
  109. - symlink for gimp listed in %file section
  110. - some html-documents
  111. - set %_sysconfdir to /etc for RedHat6.x/Vine2.x
  112. - RPM Group move to Applications/Multimedia
  113. * Tue Mar 12 2002 Masaki Shinomiya <shino@pos.to>
  114. - 0.84-0
  115. - bugfix in %post script
  116. * Sun Dec 23 2001 Masaki Shinomiya <shino@pos.to>
  117. - 0.82-0.1
  118. - use mocros as possible, nosrc
  119. * Thu Jul 5 2001 Masaki Shinomiya <shino@pos.to>
  120. - 0.79-0test
  121. - remove the patch of the tooltips
  122. * Thu Jul 5 2001 Masaki Shinomiya <shino@pos.to>
  123. - 0.78-1vl2
  124. - fixed script for gimp plug-in setup
  125. * Sat Jun 23 2001 Masaki Shinomiya <shino@pos.to>
  126. - rename for VinePlus. program registoration for gnome
  127. * Tue Jun 19 2001 Masaki Shinomiya <shino@pos.to>
  128. - patch to provide proper fonts for the tooltips
  129. * Thu Jun 14 2001 Masaki Shinomiya <shino@pos.to>
  130. - 0.78-1
  131. - escape confliction of the document file 'sane-pnm-doc.html' with one from SANE
  132. * Sun Jun 3 2001 Masaki Shinomiya <shino@pos.to>
  133. - 0.77-1
  134. * Mon May 21 2001 Masaki Shinomiya <shino@pos.to>
  135. - 0.76-1
  136. - refined script for gimp plug-in setup
  137. * Wed Nov 15 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
  138. - 0.64-0vl1
  139. - updated to 0.64 (hope it'll be compatible with gimp-1.1.27...)
  140. * Mon Oct 16 2000 Jun Nishii <jun@vinelinux.org>
  141. - 0.61-0vl3
  142. - build with gimp-1.1.27
  143. * Mon Sep 25 2000 Jun Nishii <jun@vinelinux.org>
  144. - 0.61-0vl2
  145. - build with gimp-1.1.25
  146. * Thu Sep 21 2000 Jun Nishii <jun@vinelinux.org>
  147. - 0.61-0vl1
  148. * Sat Jan 22 2000 Jun Nishii <jun@vinelinux.org>
  149. - 0.51-0vl1
  150. * Mon Aug 30 1999 Tim Powers <timp@redhat.com>
  151. - changed group
  152. * Mon Jul 26 1999 Tim Powers <timp@redhat.com>
  153. - update to 0.30
  154. - added %defattr
  155. - built for 6.1
  156. * Thu Apr 22 1999 Preston Brown <pbrown@redhat.com>
  157. - initial RPM for PowerTools 6.0