source: projects/specs/trunk/o/openjpeg2/openjpeg2-vl.spec @ 12519

Revision 12519, 11.1 KB checked in by tomop, 3 years ago (diff)

updated 7 packages

ghostscript-9.53.3-1

lua-5.4.2-1

libjpeg-turbo-2.0.6-1

libtiff-4.2.0-1

openjpeg2-2.4.0-1

proftpd-1.3.7a-1

wireshark-3.4.2-1

Line 
1%global upname openjpeg
2#global snap svn20140403
3
4# Conformance tests disabled by default since it requires 1 GB of test data
5#global runcheck 1
6
7#global optional_components 1
8
9%global minor_version 2.4
10
11Name:           openjpeg2
12Summary:        C-Library for JPEG 2000
13Summary(ja):    JPEG 2000 用の C ライブラリ
14Version:        2.4.0
15Release:        1%{?_dist_release}
16Group:          system
17Vendor:         Project Vine
18Distribution:   Vine Linux
19
20# windirent.h is MIT, the rest is BSD
21License:        BSD and MIT
22URL:            http://www.openjpeg.org/
23%if 0%{?snap:1}
24# Snapshots taken from stable release branch:
25#   svn co http://openjpeg.googlecode.com/svn/branches/openjpeg-2.0 openjpeg-2.0.0
26#   find openjpeg-2.0.0 -name ".svn" -exec rm -rf {} \;
27#   tar -cf openjpeg-2.0.0-$snap.tar.gz openjpeg-2.0.0
28Source0:        %{upname}-%{version}-%{snap}.tar.gz
29%else
30Source0:        https://github.com/uclouvain/openjpeg/archive/v%{version}/openjpeg-%{version}.tar.gz
31%endif
32%if 0%{?runcheck}
33# svn checkout http://openjpeg.googlecode.com/svn/data
34Source1: data.tar.xz
35%endif
36
37# Remove bundled libraries
38Patch0:         openjpeg2_remove-thirdparty.patch
39# opj_* to opj2_*
40Patch1:         openjpeg2_opj2.patch
41
42BuildRequires:  cmake
43BuildRequires:  zlib-devel
44BuildRequires:  libpng-devel
45BuildRequires:  libtiff-devel
46BuildRequires:  lcms2-devel
47BuildRequires:  doxygen
48
49%if 0%{?optional_components}
50BuildRequires:  java-devel
51BuildRequires:  xerces-j2
52%endif
53
54%description
55The OpenJPEG library is an open-source JPEG 2000 library developed in order to
56promote the use of JPEG 2000.
57
58This package contains
59* JPEG 2000 codec compliant with the Part 1 of the standard (Class-1 Profile-1
60  compliance).
61* JP2 (JPEG 2000 standard Part 2 - Handling of JP2 boxes and extended multiple
62  component transforms for multispectral and hyperspectral imagery)
63
64
65%package devel
66Summary:        Development files for OpenJPEG 2
67Summary(ja):    OpenJPEG 2 の開発用ファイル
68Group:          programming
69Requires:       %{name}%{?_isa} = %{version}-%{release}
70# OpenJPEGTargets.cmake refers to the tools
71Requires:       %{name}-tools%{?_isa} = %{version}-%{release}
72
73%description devel
74The %{name}-devel package contains libraries and header files for developing
75applications that use OpenJPEG 2.
76
77
78%package devel-docs
79Summary:        Developer documentation for OpenJPEG 2
80Summary(ja):    OpenJPEG 2 の開発用ドキュメント
81Group:          documentation
82BuildArch:      noarch
83
84%description devel-docs
85The %{name}-devel-docs package contains documentation files for developing
86applications that use OpenJPEG 2.
87
88
89%package tools
90Summary:        OpenJPEG 2 command line tools
91Summary(ja):    OpenJPEG 2 のコマンドラインツール集
92Group:          graphics
93Requires:       %{name}%{?_isa} = %{version}-%{release}
94
95%description tools
96Command line tools for JPEG 2000 file manipulation, using OpenJPEG2:
97 * opj2_compress
98 * opj2_decompress
99 * opj2_dump
100
101%if 0%{?optional_components}
102##### MJ2 #####
103 
104%package mj2
105Summary:        OpenJPEG2 MJ2 module
106Requires:       %{name}%{?_isa} = %{version}-%{release}
107
108%description mj2
109The OpenJPEG library is an open-source JPEG 2000 library developed in order to
110promote the use of JPEG 2000.
111
112This package contains the MJ2 module (JPEG 2000 standard Part 3)
113
114
115%package mj2-devel
116Summary:        Development files for OpenJPEG2 MJ2 module
117Requires:       %{name}-devel%{?_isa} = %{version}-%{release}
118Requires:       %{name}-mj2%{?_isa} = %{version}-%{release}
119
120%description mj2-devel
121Development files for OpenJPEG2 MJ2 module
122
123
124%package mj2-tools
125Summary:        OpenJPEG2 MJ2 module command line tools
126Requires:       %{name}-mj2%{?_isa} = %{version}-%{release}
127
128%description mj2-tools
129OpenJPEG2 MJ2 module command line tools
130
131##### JPWL #####
132
133%package jpwl
134Summary:        OpenJPEG2 JPWL module
135Requires:       %{name}%{?_isa} = %{version}-%{release}
136
137%description jpwl
138The OpenJPEG library is an open-source JPEG 2000 library developed in order to
139promote the use of JPEG 2000.
140
141This package contains the JPWL (JPEG 2000 standard Part 11 - Jpeg 2000 Wireless)
142
143
144%package jpwl-devel
145Summary:        Development files for OpenJPEG2 JPWL module
146Requires:       %{name}-devel%{?_isa} = %{version}-%{release}
147Requires:       %{name}-jpwl%{?_isa} = %{version}-%{release}
148
149%description jpwl-devel
150Development files for OpenJPEG2 JPWL module
151
152
153%package jpwl-tools
154Summary:        OpenJPEG2 JPWL module command line tools
155Requires:       %{name}-jpwl%{?_isa} = %{version}-%{release}
156
157%description jpwl-tools
158OpenJPEG2 JPWL module command line tools
159
160##### JPIP #####
161
162%package jpip
163Summary:        OpenJPEG2 JPIP module
164Requires:       %{name}%{?_isa} = %{version}-%{release}
165
166%description jpip
167The OpenJPEG library is an open-source JPEG 2000 library developed in order to
168promote the use of JPEG 2000.
169
170This package contains the JPWL (JPEG 2000 standard Part 9 - Jpeg 2000 Interactive Protocol)
171
172
173%package jpip-devel
174Summary:        Development files for OpenJPEG2 JPIP module
175Requires:       %{name}-devel%{?_isa} = %{version}-%{release}
176Requires:       %{name}-jpwl%{?_isa} = %{version}-%{release}
177
178%description jpip-devel
179Development files for OpenJPEG2 JPIP module
180
181
182%package jpip-tools
183Summary:        OpenJPEG2 JPIP module command line tools
184Requires:       %{name}-jpip%{?_isa} = %{version}-%{release}
185Requires:       jpackage-utils
186Requires:       java
187
188%description jpip-tools
189OpenJPEG2 JPIP module command line tools
190
191##### JP3D #####
192
193%package jp3d
194Summary:        OpenJPEG2 JP3D module
195Requires:       %{name}%{?_isa} = %{version}-%{release}
196
197%description jp3d
198The OpenJPEG library is an open-source JPEG 2000 library developed in order to
199promote the use of JPEG 2000.
200
201This package contains the JP3D (JPEG 2000 standard Part 10 - Jpeg 2000 3D)
202
203
204%package jp3d-devel
205Summary:        Development files for OpenJPEG2 JP3D module
206Requires:       %{name}-devel%{?_isa} = %{version}-%{release}
207Requires:       %{name}-jp3d%{?_isa} = %{version}-%{release}
208
209%description jp3d-devel
210Development files for OpenJPEG2 JP3D module
211
212
213%package jp3d-tools
214Summary:        OpenJPEG2 JP3D module command line tools
215Requires:       %{name}-jp3d%{?_isa} = %{version}-%{release}
216
217%description jp3d-tools
218OpenJPEG2 JP3D module command line tools
219%endif
220
221
222%debug_package
223
224
225%prep
226%setup -q -n %{upname}-%{version} %{?runcheck:-a 1}
227
228%patch0 -p1
229%patch1 -p1
230
231# Remove all third party libraries just to be sure
232rm -rf thirdparty
233
234
235%build
236mkdir %{_target_platform}
237pushd %{_target_platform}
238# TODO: Consider
239# -DBUILD_JPIP_SERVER=ON -DBUILD_JAVA=ON
240%cmake \
241    -DCMAKE_BUILD_TYPE=RelWithDebInfo \
242    -DOPENJPEG_INSTALL_LIB_DIR=%{_lib} \
243    %{?optional_components:-DBUILD_MJ2=ON -DBUILD_JPWL=ON -DBUILD_JPIP=ON -DBUILD_JP3D=ON} \
244    -DBUILD_DOC=ON \
245    -DBUILD_STATIC_LIBS=OFF \
246    -DBUILD_SHARED_LIBS=ON \
247    %{?runcheck:-DBUILD_TESTING:BOOL=ON -DOPJ_DATA_ROOT=$PWD/../data} \
248    ..
249popd
250
251make VERBOSE=1 -C %{_target_platform} %{?_smp_mflags}
252
253
254%install
255%make_install -C %{_target_platform}
256
257# Rename to avoid conflicts with openjpeg-1.x
258mv %{buildroot}%{_mandir}/man1/opj_compress.1 %{buildroot}%{_mandir}/man1/opj2_compress.1
259mv %{buildroot}%{_mandir}/man1/opj_decompress.1 %{buildroot}%{_mandir}/man1/opj2_decompress.1
260mv %{buildroot}%{_mandir}/man1/opj_dump.1 %{buildroot}%{_mandir}/man1/opj2_dump.1
261
262# Docs are installed through %%doc
263rm -rf %{buildroot}%{_datadir}/doc/
264
265%if 0%{?optional_components}
266# Move the jar to the correct place
267mkdir -p %{buildroot}%{_javadir}
268mv %{buildroot}%{_datadir}/opj_jpip_viewer.jar %{buildroot}%{_javadir}/opj2_jpip_viewer.jar
269cat > %{buildroot}%{_bindir}/opj2_jpip_viewer <<EOF
270java -jar %{_javadir}/opj2_jpip_viewer.jar "$@"
271EOF
272chmod +x %{buildroot}%{_bindir}/opj2_jpip_viewer
273%endif
274
275
276%post -p /sbin/ldconfig
277%postun -p /sbin/ldconfig
278
279
280%check
281%if 0%{?runcheck}
282make test -C %{_target_platform}
283%endif
284
285
286%files
287%{!?_licensedir:%global license %doc}
288%license LICENSE
289%doc AUTHORS* CHANGELOG* NEWS* README* THANKS*
290%{_libdir}/libopenjp2.so.*
291%{_mandir}/man3/libopenjp2.3*
292
293%files devel
294%dir %{_includedir}/openjpeg-%{minor_version}/
295%{_includedir}/openjpeg-%{minor_version}/openjpeg.h
296%{_includedir}/openjpeg-%{minor_version}/opj_config.h
297%{_includedir}/openjpeg-%{minor_version}/opj_stdint.h
298%{_libdir}/libopenjp2.so
299%{_libdir}/openjpeg-%{minor_version}/
300%{_libdir}/pkgconfig/libopenjp2.pc
301
302%files devel-docs
303%doc %{_target_platform}/doc/html
304
305%files tools
306%{_bindir}/opj2_compress
307%{_bindir}/opj2_decompress
308%{_bindir}/opj2_dump
309%{_mandir}/man1/opj2_compress.1*
310%{_mandir}/man1/opj2_decompress.1*
311%{_mandir}/man1/opj2_dump.1*
312
313%if 0%{?optional_components}
314%files mj2
315%{_libdir}/libopenmj2.so.*
316
317%files mj2-devel
318%{_libdir}/libopenmj2.so
319
320%files mj2-tools
321%{_bindir}/opj2_mj2*
322
323%files jpwl
324%{_libdir}/libopenjpwl.so.*
325
326%files jpwl-devel
327%{_libdir}/libopenjpwl.so
328%{_libdir}/pkgconfig/libopenjpwl.pc
329
330%files jpwl-tools
331%{_bindir}/opj2_jpwl*
332
333%files jpip
334%{_libdir}/libopenjpip.so.*
335
336%files jpip-devel
337%{_libdir}/libopenjpip.so
338%{_libdir}/pkgconfig/libopenjpip.pc
339
340%files jpip-tools
341%{_bindir}/opj2_jpip*
342%{_bindir}/opj2_dec_server
343%{_javadir}/opj2_jpip_viewer.jar
344
345%files jp3d
346%{_libdir}/libopenjp3d.so.*
347
348%files jp3d-devel
349%{_includedir}/openjpeg-2.0/openjp3d.h
350%{_libdir}/libopenjp3d.so
351%{_libdir}/pkgconfig/libopenjp3d.pc
352
353%files jp3d-tools
354%{_bindir}/opj2_jp3d*
355%endif
356
357
358%changelog
359* Tue Dec 29 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.4.0-1
360- new upstream release.
361
362* Mon Oct 14 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.3.1-2
363- fixed files for cmake.
364
365* Mon Aug 12 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.3.1-1
366- new upstream release.
367
368* Fri Dec 15 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.3.0-1
369- new upstream release.
370- dropped %%patch1 and 2: fixed in upstream.
371
372* Mon Mar 20 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.1.2-1
373- new upstream release.
374
375* Tue Jan 13 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 2.1.0-5
376- added japanese summary and Group tag
377
378* Wed Dec 24 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.1.0-4
379- initial build for Vine Linux.
380
381* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.0-3
382- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
383
384* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.0-2
385- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
386
387* Tue May 27 2014 Sandro Mani <manisandro@gmail.com> - 2.1.0-1
388* Wed Apr 16 2014 Sandro Mani <manisandro@gmail.com> - 2.0.0-5
389- Switch to official 2.0 release and backport pkg-config patch
390
391* Thu Apr 10 2014 Sandro Mani <manisandro@gmail.com> - 2.0.0-4.svn20140403
392- Replace define with global
393- Fix #define optional_components 1S typo
394- Fix %%(pwd) -> $PWD for test data
395- Added some BR for optional components
396- Include opj2_jpip_viewer.jar in %%files
397
398* Wed Apr 09 2014 Sandro Mani <manisandro@gmail.com> - 2.0.0-3.svn20140403
399- Fix source url
400- Fix mixed tabs and spaces
401- Fix description too long
402
403* Wed Apr 09 2014 Sandro Mani <manisandro@gmail.com> - 2.0.0-2.svn20140403
404- Remove thirdparty libraries folder in prep
405- Own %%{_libdir}/openjpeg-2.0/
406- Fix Requires
407- Add missing ldconfig
408- Add possibility to run conformance tests if desired
409 
410* Thu Apr 03 2014 Sandro Mani <manisandro@gmail.com> - 2.0.0-1.svn20140403
411- Initial package
Note: See TracBrowser for help on using the repository browser.