source: spec/trunk/SPECS/libjpeg.spec@ 858

Last change on this file since 858 was 850, checked in by Silvan Scherrer, 9 years ago

spec: libjpeg: update to version 8d

File size: 3.7 KB
Line 
1#define svn_url e:/trees/libjpeg/trunk
2%define svn_url http://svn.netlabs.org/repos/ports/libjpeg/trunk
3%define svn_rev 1707
4
5Summary: A library for manipulating JPEG image format files
6Name: libjpeg
7Version: 8d
8Release: 1%{?dist}
9License: IJG
10Group: System Environment/Libraries
11URL: http://www.ijg.org/
12
13Vendor: bww bitwise works GmbH
14Source: %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip
15
16# DEF files to create forwarders for the legacy package
17Source10: jpeg.def
18
19BuildRequires: autoconf libtool
20BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
21
22%description
23The libjpeg package contains a library of functions for manipulating
24JPEG images, as well as simple client programs for accessing the
25libjpeg functions. Libjpeg client programs include cjpeg, djpeg,
26jpegtran, rdjpgcom and wrjpgcom. Cjpeg compresses an image file into
27JPEG format. Djpeg decompresses a JPEG file into a regular image
28file. Jpegtran can perform various useful transformations on JPEG
29files. Rdjpgcom displays any text comments included in a JPEG file.
30Wrjpgcom inserts text comments into a JPEG file.
31
32%package devel
33Summary: Development tools for programs which will use the libjpeg library
34Group: Development/Libraries
35Requires: libjpeg = %{version}-%{release}
36
37%description devel
38The libjpeg-devel package includes the header files and documentation
39necessary for developing programs which will manipulate JPEG files using
40the libjpeg library.
41
42If you are going to develop programs which will manipulate JPEG images,
43you should install libjpeg-devel. You'll also need to have the libjpeg
44package installed.
45
46%package static
47Summary: Static JPEG image format file library
48Group: Development/Libraries
49Requires: libjpeg-devel = %{version}-%{release}
50
51%description static
52The libjpeg-static package contains the statically linkable version of libjpeg.
53Linking to static libraries is discouraged for most applications, but it is
54necessary for some boot packages.
55
56%debug_package
57
58%prep
59%if %{?svn_rev:%(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')}%{!?svn_rev):0}
60%setup -q
61%else
62%setup -n "%{name}-%{version}" -Tc
63svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force
64rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip"
65(cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" "%{name}-%{version}")
66%endif
67
68# Prepare forwarder DLLs.
69for m in %{SOURCE10}; do
70 cp ${m} .
71done
72
73# Hack: disable autoheader so that it doesn't overwrite our cfg template.
74export AUTOHEADER="echo autoheader ignored"
75autoreconf -vif
76
77%build
78export LDFLAGS="-Zhigh-mem -Zomf -Zargs-wild -Zargs-resp"
79%configure \
80 --enable-shared --enable-static
81
82make %{?_smp_mflags}
83
84%check
85# this export is needed, as else the dll for the tests are not found
86export BEGINLIBPATH=%{_builddir}/%{buildsubdir}/.libs
87make test
88
89%install
90rm -rf $RPM_BUILD_ROOT
91%makeinstall
92
93#install -m 755 jpeg.dll $RPM_BUILD_ROOT/%{_libdir}
94#install -m 755 .libs/jpeg_s.a $RPM_BUILD_ROOT/%{_libdir}
95
96# We don't ship .la files.
97rm $RPM_BUILD_ROOT%{_libdir}/*.la
98
99# Generate & install forwarder DLLs.
100gcc -Zomf -Zdll jpeg.def -l$RPM_BUILD_ROOT/%{_libdir}/jpeg8.dll -o $RPM_BUILD_ROOT/%{_libdir}/jpeg.dll
101
102%files
103%defattr(-,root,root)
104%doc usage.txt README
105%{_libdir}/jpeg*.dll
106%{_bindir}/*.exe
107%{_mandir}/*/*
108
109%files devel
110%defattr(-,root,root)
111%doc libjpeg.txt coderules.txt structure.txt wizard.txt example.c
112%{_libdir}/jpeg*_dll.a
113%{_includedir}/*.h
114
115%files static
116%defattr(-,root,root)
117%{_libdir}/jpeg.a
118
119%clean
120rm -rf $RPM_BUILD_ROOT
121
122%changelog
123* Wed Sep 21 2016 Silvan Scherrer <silvan.scherrer@aroa.ch> - 8d-1
124- update to version 8d
125- change build part
126- add debug files
127
128* Mon Dec 19 2011 yd
129- initial build.
Note: See TracBrowser for help on using the repository browser.