source: projects/specs/trunk/s/sane/sane-vl.spec @ 9345

Revision 9345, 13.1 KB checked in by Takemikaduchi, 9 years ago (diff)

rebuild with ligphoto2-2.5.7

Line 
1# To make src.rpm
2# rpm -bs --define 'src:1'
3# To make nosrc.rpm
4# rpm -bs --define 'nosrc:1'
5
6%define build_html 0
7
8Summary:        SANE -- Easy local and networked scanner access
9Summary(ja):    スキャナ操作ツール
10Name:           sane
11Version:        1.0.24
12Release:        2%{?_dist_release}
13URL:            http://www.sane-project.org/
14Source:         ftp://ftp.sane-project.org/pub/sane/%{name}-backends-%{version}.tar.gz
15Source10:       sane-hierarchy.png
16Patch0:         sane-1.0.24-vine.patch
17%{?nosrc:NoSource: 0}
18License:        GPL (programs), relaxed LGPL (libraries), and public domain (docs)
19Group:          Applications/Multimedia
20#Icon:          sane-logo.png
21Provides:       libsane.so.1 sane-backends
22
23Requires:       libjpeg, libusb
24BuildRequires:  sed
25BuildRequires:  libjpeg-devel
26BuildRequires:  libusb-devel
27BuildRequires:  libgphoto2-devel
28#BuildPrereq:    latex2html
29#BuildPrereq: emacs/or/xemacs pLaTeX2e/or/tetex-latex pTeX/or/tetex
30Buildroot:      %{_tmppath}/%{name}-%{version}-root
31
32%{?nosrc:%define src 1}
33%{?src:%define _src 1}
34%{?!src:%define _src 0}
35
36Vendor: Project Vine
37Distribution: Vine Linux
38
39%description
40SANE (Scanner Access Now Easy) is a sane and simple interface
41to both local and networked scanners and other image acquisition devices
42like digital still and video cameras.  SANE currently includes modules for
43accessing a range of scanners, including models from Agfa SnapScan, Apple,
44Artec, Canon, CoolScan, Epson, HP, Microtek, Mustek, Nikon, Siemens,
45Tamarack, UMAX, Connectix, QuickCams and other SANE devices via network.
46This package also include a client program 'scanimage','sane-find-scanner',
47'xerox' and etc.
48
49For the latest information on SANE, the SANE standard definition, and
50mailing list access, see http://www.mostang.com/sane/
51%if %{_src}
52You need xemacs or emacs to build this package.
53And you need latex2html to build this package if you like html documents.
54%endif
55
56%description -l ja
57SANE (Scanner Access Now Easy) はローカル/ネットワーク・スキャナや
58デジタルカメラ、デジタルビデオカメラなど画像取り込み装置の簡単なイン
59ターフェースです。SANE は Agfa SnapScan, Apple, Artec, Canon, CoolScan,
60Epson, HP, Microtek, Mustek, Nikon, Siemens, Tamarack, UMAX, Connectix,
61QuickCams その他、いろいろなスキャナを使うことができます。
62コマンドラインで動くscanimage, sane-find-scanner, xeroxなどもこのパッケージに
63含まれています。
64%if %{_src}
65このソースパッケージからビルドするにはxemacsまたはemacsが必要です。
66またHTMLドキュメントを含めるにはlatex2htmlが必要です。
67%endif
68
69%package devel
70Summary:  SANE (Scanner Access Now Easy) development toolkit
71Summary(ja):  SANE (Scanner Access Now Easy) 開発ツールキット
72Group:    Development/Libraries
73Requires: %{name} = %{version}
74Requires: pkgconfig
75Requires: libjpeg-devel
76Requires: libgphoto2-devel
77Requires: libexif-devel
78Requires: libusb-devel
79
80%description devel
81Static libraries and header files for writing SANE modules.
82
83%description devel -l ja
84SANE のモジュールを書くための、ヘッダファイルと静的ライブラリ
85です。
86
87%prep
88%setup -q -n %{name}-backends-%{version}
89%patch0 -p1 -b .vine
90
91%build
92%configure --with-gnu-ld --enable-static
93# don't set smp flags!
94make
95
96# dll.conf: comment out all lines
97# epson.conf: add example for usb scanner
98( cd backend
99cat dll.conf | %__sed "s/^\([^#]\)/#\1/" > dll.conf~
100%__mv -f dll.conf~ dll.conf
101echo "#usb /dev/usb/scanner0" >> epson.conf
102)
103
104%if %{build_html}
105( cd doc
106  %__make html
107  %__mv sane html
108  cd html
109  %__cp -f %{SOURCE10} img1.png
110  %__cat node10.html | \
111    %__sed 's/WIDTH="5.." HEIGHT="2"/WIDTH="500" HEIGHT="246"/' \
112    > node10.html~
113  %__mv -f node10.html~ node10.html
114  %__rm -f WARNINGS
115)
116[ -d doc/html ] || %__mkdir doc/html
117%endif
118
119%install
120%__rm -rf $RPM_BUILD_ROOT
121%{__make} install DESTDIR=${RPM_BUILD_ROOT}
122%__mv $RPM_BUILD_ROOT%{_sbindir}/saned $RPM_BUILD_ROOT%{_sbindir}/in.saned
123%__install -m755 tools/xerox $RPM_BUILD_ROOT%{_bindir}
124%__install -m755 tools/umax_pp $RPM_BUILD_ROOT%{_bindir}
125%__cp tools/README README.tools
126%__mkdir_p $RPM_BUILD_ROOT%{_datadir}/%{name}
127%if %{build_html}
128%__cp doc/*.html doc/*.png doc/*.jpg $RPM_BUILD_ROOT%{_datadir}/%{name}
129##%__mv doc/*.html doc/*.png doc/*.jpg doc/html
130%endif
131
132pushd $RPM_BUILD_ROOT%{_bindir}
133%__ln_s sane-find-scanner find-scanner
134popd
135
136# Create ld.so.conf.d entry
137mkdir -p %{buildroot}%{_sysconfdir}/ld.so.conf.d
138cat >> %{buildroot}%{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf << EOF
139%{_libdir}/%{name}
140EOF
141
142# clear uninstall files
143%__rm -rf $RPM_BUILD_ROOT%{_prefix}/doc
144%__rm -rf $RPM_BUILD_ROOT%{_libdir}/lib*.la
145%__rm -rf $RPM_BUILD_ROOT%{_libdir}/sane/lib*.la
146
147
148%post
149/sbin/ldconfig
150
151[ -d /dev/usb ] || %__mkdir /dev/usb
152[ -c /dev/usb/scanner0 ] || mknod /dev/usb/scanner0 c 180 48 -m 777
153
154# network settings
155SERVICES=%{_sysconfdir}/services
156if [ -x "%__grep" -a -f "$SERVICES" ] ; then
157%__grep -q "^sane" $SERVICES || \
158echo "sane          6566/tcp       # network sccaner deamon" >> $SERVICES
159fi
160INETDCONF=%{_sysconfdir}/inetd.conf
161if [ -x "%__grep" -a -f "$INETDCONF" ] ; then
162%__grep -q "^#*sane" $INETDCONF || \
163echo "#sane    stream  tcp     nowait  root    %{_sbindir}/in.saned   %{_sbindir}/in.saned" >>   $INETDCONF
164fi
165#kill -HUP `/sbin/pidof inetd`
166
167%postun -p /sbin/ldconfig
168
169
170%clean
171%__rm -rf $RPM_BUILD_ROOT
172
173%files
174%defattr(-,root,root)
175%doc README* AUTHORS ChangeLog* COPYING LICENSE PROBLEMS PROJECTS NEWS
176%doc doc/figs doc/icons doc/canon doc/mustek doc/mustek_usb doc/umax
177%if %{build_html}
178%doc doc/html
179%endif
180%doc doc/*.{txt,tex,sty}
181%doc tools
182%dir %{_sysconfdir}/sane.d
183%config %{_sysconfdir}/sane.d/*
184%config(noreplace) %{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf
185%{_sbindir}/*
186%{_bindir}/find-scanner
187%{_bindir}/gamma4scanimage
188%{_bindir}/sane-find-scanner
189%{_bindir}/scanimage
190%{_bindir}/umax_pp
191%{_bindir}/xerox
192%{_libdir}/lib*.so.*
193%{_libdir}/lib*.so
194%{_libdir}/sane/lib*.so.*
195%{_libdir}/sane/lib*.so
196%dir %{_libdir}/sane
197%{_datadir}/sane
198%{_mandir}/man1/*.1*
199%{_mandir}/man5/*.5*
200%{_mandir}/man7/*.7*
201%{_mandir}/man8/*.8*
202%{_datadir}/locale
203
204%files devel
205%defattr(-,root,root)
206%{_bindir}/sane-config
207%{_includedir}/sane
208%{_libdir}/pkgconfig/sane-backends.pc
209%{_libdir}/lib*.a
210%{_libdir}/sane/lib*.a
211
212%changelog
213* Mon Feb 09 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.0.24-2
214- rebuild with libgphoto2-2.5.7
215
216* Sun Feb 01 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.0.24-1
217- update to 1.0.24
218- update Patch0 (sane-1.0.24-vine.patch)
219- remove Patch1 (sane-backends-1.0.21-i18n.patch)
220- fix %%post and %%postun (fix BTS:2514)
221
222* Fri Jan 11 2013 IWAI, Masaharu <iwai@alib.jp> 1.0.21-2
223- build with libghoto2 2.5.0-1
224- stop generating HTML manual: missing man2html(1) in current VineSeed
225- add Vendor and Distribution tags
226
227* Sun Jul 25 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.0.21-1
228- new upstream release
229- change Patch (from sane-1.0.15-vine.patch to sane-1.0.21-vine.patch)
230- move sane-config to devel package
231- add Requires: libjpeg-devel, libgphoto2-devel, libexif-devel, libusb-devel (devel package)
232- add Patch1(sane-backends-1.0.21-i18n.patch)
233
234* Sun Oct 12 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.18-3
235- added BuildRequires: libgphoto2-devel instead of ghoto2-devel
236
237* Sat Oct 11 2008 Shu KONNO <owa@bg.wakwak.com> 1.0.18-2
238- spec in utf-8
239
240* Mon May 12 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.18-1
241- applied new versioning policy
242- removed lib*.la files from devel package
243
244* Mon Dec 24 2007 Shu KONNO <owa@bg.wakwak.com> 1.0.18-0vl1
245- new upstream release
246
247* Sun Jan 09 2005 Satoshi MACHINO <machino@vinelinux.org> 1.0.15-0vl1
248- new upstream version(sane-1.0.15)
249- fixed spec file
250        -- cleaned up patches
251        -- added Requires:       libjpeg, libusb
252        -- added BuildRequires:  glibc, libjpeg-devel, libusb-devel
253
254* Fri Oct 25 2002 Tomoya TAKA <taka@vinelinux.org> 1.0.8-0vl1
255- new upstream release
256- update sane-1.0.8-vine.patch
257- add --enable-static option to %%configure
258
259* Mon May 13 2002 Masaki Shinomiya <shino@pos.to>
260- 1.0.7-0vl2: sparc.patch, ppc.patch both from Mandrake(4mdk)
261- informed by Iohara [VinePlus:01130]
262
263* Thu Apr 4 2002 Masaki Shinomiya <shino@pos.to>
264- 1.0.7-0vl1 for Vine Linux-2.x
265- 1.0.7-0.1
266- set %_sysconfdir to /etc for RedHat6.x/Vine2.x
267
268* Wed Mar 6 2002 Masaki SHINOMIYA <shino@pos.to>
269- 1.0.7-0
270- new source
271- avoid listing %{_libdir}/sane from sane-devel
272- add LEVEL2 in doc
273
274* Fri Feb 1 2002 Masaki SHINOMIYA <shino@pos.to>
275- 1.0.6-0.3
276- allow to build without latex2html
277- prereq ldconfig, buildprereq sed, provide sane-backends
278
279* Sun Dec 23 2001 Masaki SHINOMIYA <shino@pos.to>
280- 1.0.6-0.2
281- dll.conf, epson.conf, network settings
282
283* Tue Dec 18 2001 Masaki SHINOMIYA <shino@pos.to>
284- 1.0.6-0.1
285- new source
286
287* Mon Dec 17 2001 Masaki SHINOMIYA <shino@pos.to>
288- 1.0.5-1.3
289- allow to use emacs or xemacs in building
290- nosrc
291
292#* Wed Oct 3 2001 Masaki SHINOMIYA <shino@pos.to>
293#- 1.0.5-1.2
294#- surpress swapping R<-->G colors on EPSON GT-8700/Perfection1640
295#- ( information from [vine-users:037559] tyu <tyu@mbd.nifty.com> )
296#- omit doc/*.tex etc.
297
298* Tue Sep 18 2001 Masaki SHINOMIYA <shino@pos.to>
299- 1.0.5-1.1
300- use emacs instead of xemacs in building
301
302* Sat Jul 7 2001 Masaki SHINOMIYA <shino@pos.to>
303- 1.0.5-1
304
305* Thu Jun 7 2001 Masaki SHINOMIYA <shino@pos.to>
306- 1.0.4 + epson backend ver.20010519
307- sane-clients is removed from this package
308- scanimage, find-scanner and xerox are left in this package
309
310* Thu May 17 2001 Masaki SHINOMIYA <shino@pos.to>
311- 1.0.4 + epson backend ver.20010331
312- 'scanimage' is included in the binary'sane-1.0.4-1.i386.rpm'package.
313- refined script for gimp plug-in setup
314- html documents shal be installed in the directory '/usr/share/sane'
315- automatically make device the file /dev/usb/scanner0
316
317* Wed Nov 15 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
318- 1.0.3-0vl8
319- included missing "sane-config" script for sane
320
321* Tue Oct 17 2000 Jun Nishii <jun@vinelinux.org>
322- 1.0.3-0vl7
323- merge xscanimage patch
324
325* Mon Oct 16 2000 Jun Nishii <jun@vinelinux.org>
326- 1.0.3-0vl6
327- build with gimp-1.1.27
328
329* Sun Oct  1 2000 Jun Nishii <jun@vinelinux.org>
330- 1.0.3-0vl5
331- fixed group
332
333* Sat Sep 30 2000 Jun Nishii <jun@vinelinux.org>
334- 1.0.3-0vl4
335- added %defattr in clients
336
337* Tue Sep 26 2000 Jun Nishii <jun@vinelinux.org>
338- 1.0.3-0vl3
339- build with gimp-1.1.26
340
341* Mon Sep 25 2000 Jun Nishii <jun@vinelinux.org>
342- 1.0.3-0vl2
343- build with gimp-1.1.25
344
345* Thu Sep 21 2000 Jun Nishii <jun@vinelinux.org>
346- 1.0.3-0vl1
347
348* Thu Jun  8 2000 Jun Nishii <jun@vinelinux.org>
349- 1.0.2-0vl1
350
351* Mon Jan 17 2000 Jun Nishii <jun@vinelinux.org>
352- build for Vine Linux 2.0
353- added find-scanner, xerox
354
355* Fri Apr 23 1999 Hugo van der Kooij <hvdkooij@caiw.nl>
356- Fixed packaging a bit.
357
358* Wed Apr 21 1999 Hugo van der Kooij <hvdkooij@caiw.nl>
359- Updated package to 1.01
360
361* Fri Apr 09 1999 Hugo van der Kooij <hvdkooij@caiw.nl>
362- Split off the clients
363- Fixed a Alpha system anomaly by removing the specific backend.
364
365* Mon Nov 23 1998 Jonathan Miller <jlm@mvhi.com>
366 [1.00-1]
367- upgraded to 1.00 (and made description less space-consuming)
368- included the post 1.00 fixed "configure" script available 22 Nov 1998.
369
370* Sat Aug 08 1998 Arne Coucheron <arneco@online.no>
371  [0.74-3]
372- added /etc/sane.d to %dir in file list
373
374* Sat Aug 01 1998 Arne Coucheron <arneco@online.no>
375  [0.74-2]
376- devel Group: reverted back to Development/Libraries
377- some changes to the %defattr and %attr usage in file list
378
379* Tue Jul 28 1998 Binaire <binaire@binaire.ml.org>
380  [0.74-1]
381
382* Fri May 22 1998 Arne Coucheron <arneco@online.no>
383  [0.73-3]
384- added use of %%{name} and %%{version} macros
385- added a %postun for running ldconfig after uninstall
386- using BuildRoot properly now
387- using %defattr and %attr macros in filelist, allows non-root build
388  this means that RPM 2.5 is required to build this spec file now!
389- devel Group: changed to X11/Libraries
390- added using RPM_OPT_FLAGS during make
391- added striping of programs and libraries
392- added Requires: gtk+ >= 0.99.13 to main package
393- added Requires: %%{name} = %%{version} to devel package
394- added a %clean section for removing the buildroot dir
395- simplified the filelist and added %config for sane-style.rc
396- moved lib*.so to %files devel and dropped the *.la files
397- added -q parameter to %setup
398- removed some older changelog entries
399- removed the "fix ldconfig brokenness..." stuff
400- removed the Packager: line; use /etc/rpmrc if you want your name in
401- if GIMP is installed, make symlink from xscanimage to plug-ins dir
402- install the find-scanner program from the tools dir
403
404* Mon May 18 1998 Hugo van der Kooij <hvdkooij@caiw.nl>
405- Version 0.73 was created: May 13 1998
406- gimp (original was build against 0.99.29)
407- gtk+ (original was build against 1.0.1)
408- dlh (original was build against 0.7d)
409- X11 development tree including xpm libraries.
410
411* Wed Apr 22 1998 Hugo van der Kooij <hvdkooij@caiw.nl>
412- Binaries are now BuildRoot proof.
413
414* Wed Apr 22 1998 Hugo van der Kooij <hvdkooij@caiw.nl>
415- Binaries are not BuildRoot proof. release 3 is done without BuildRoot!
416
417* Tue Apr 21 1998 Hugo van der Kooij <hvdkooij@caiw.nl>
418- Temp. fix for some documentations problems with BuildRoot.
419
420* Sat Apr 11 1998 Hugo van der Kooij <hvdkooij@caiw.nl>
421- Formal 0.72 now made as RPM! (Build against GTK+ 0.99.10 and GIMP 0.99.24)
422- Original package was released: Tue Apr 7 1998
Note: See TracBrowser for help on using the repository browser.