[openjpeg] 1.5.0
Rex Dieter
rdieter at fedoraproject.org
Fri Feb 10 01:14:50 UTC 2012
commit 1fdf2fcd729d2f73186feeb6ea95d345595ea8b3
Author: Rex Dieter <rdieter at fedoraproject.org>
Date: Thu Feb 9 19:14:42 2012 -0600
1.5.0
.gitignore | 5 +-
openjpeg-1.4-OpenJPEGConfig.patch | 12 ---
openjpeg-1.4-autoconf.patch | 78 -------------------
openjpeg-1.4-cmake_pkgconfig.patch | 36 ---------
openjpeg-1.4-cmake_soversion_3.patch | 22 ------
openjpeg-1.4-cmake_symlink_fix.patch | 12 ---
openjpeg-1.4-no_undefined.patch | 25 ------
openjpeg-1.4-poppler_regression.patch | 100 -------------------------
openjpeg-1.5.0-cmake_Config.patch | 20 +++++
openjpeg-1.5.0-cmake_header_symlink.patch | 14 ++++
openjpeg-1.5.0-cmake_libdir.patch | 21 +++++
openjpeg.spec | 116 +++++++++++------------------
sources | 3 +-
13 files changed, 102 insertions(+), 362 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 1eba092..8979db5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,4 @@
-openjpeg_v1_3.tar.gz
-j2kp4files_v1_5.zip
+/openjpeg_v1_3.tar.gz
+/j2kp4files_v1_5.zip
/openjpeg_v1_4_sources_r697.tgz
+/openjpeg-1.5.0.tar.gz
diff --git a/openjpeg-1.5.0-cmake_Config.patch b/openjpeg-1.5.0-cmake_Config.patch
new file mode 100644
index 0000000..ba24eeb
--- /dev/null
+++ b/openjpeg-1.5.0-cmake_Config.patch
@@ -0,0 +1,20 @@
+diff -up openjpeg-1.5.0/CMake/OpenJPEGConfig.cmake.in.cmake_Config openjpeg-1.5.0/CMake/OpenJPEGConfig.cmake.in
+--- openjpeg-1.5.0/CMake/OpenJPEGConfig.cmake.in.cmake_Config 2012-02-07 04:49:55.000000000 -0600
++++ openjpeg-1.5.0/CMake/OpenJPEGConfig.cmake.in 2012-02-09 15:14:50.673012792 -0600
+@@ -11,13 +11,13 @@ SET(OPENJPEG_MINOR_VERSION "@OPENJPEG_VE
+ SET(OPENJPEG_BUILD_VERSION "@OPENJPEG_VERSION_BUILD@")
+
+ # The libraries.
+-SET(OPENJPEG_LIBRARIES "@OPENJPEG_LIBRARIES@")
++SET(OPENJPEG_LIBRARIES "@OPENJPEG_LIBRARY_NAME@")
+
+ # The CMake macros dir.
+-SET(OPENJPEG_CMAKE_DIR "@OPENJPEG_CMAKE_DIR_CONFIG@")
++SET(OPENJPEG_CMAKE_DIR "@OPENJPEG_INSTALL_PACKAGE_DIR@")
+
+ # The configuration options.
+-SET(OPENJPEG_BUILD_SHARED_LIBS "@OPENJPEG_BUILD_SHARED_LIBS@")
++SET(OPENJPEG_BUILD_SHARED_LIBS "@BUILD_SHARED_LIBS@")
+
+ # The "use" file.
+ SET(OPENJPEG_USE_FILE "@OPENJPEG_USE_FILE_CONFIG@")
diff --git a/openjpeg-1.5.0-cmake_header_symlink.patch b/openjpeg-1.5.0-cmake_header_symlink.patch
new file mode 100644
index 0000000..1bfdf90
--- /dev/null
+++ b/openjpeg-1.5.0-cmake_header_symlink.patch
@@ -0,0 +1,14 @@
+diff -up openjpeg-1.5.0/libopenjpeg/CMakeLists.txt.header_symlink openjpeg-1.5.0/libopenjpeg/CMakeLists.txt
+--- openjpeg-1.5.0/libopenjpeg/CMakeLists.txt.header_symlink 2012-02-07 04:49:55.000000000 -0600
++++ openjpeg-1.5.0/libopenjpeg/CMakeLists.txt 2012-02-09 15:02:09.760525453 -0600
+@@ -57,6 +57,10 @@ INSTALL(TARGETS ${OPENJPEG_LIBRARY_NAME}
+ INSTALL(FILES openjpeg.h
+ DESTINATION ${OPENJPEG_INSTALL_INCLUDE_DIR}/${OPENJPEG_INSTALL_SUBDIR} COMPONENT Headers
+ )
++INSTALL( CODE "EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E create_symlink
++ \"${OPENJPEG_INSTALL_SUBDIR}/openjpeg.h\"
++ \"\$ENV{DESTDIR}${OPENJPEG_INSTALL_INCLUDE_DIR}/openjpeg.h\")"
++)
+
+ # install man page of the library
+ INSTALL(
diff --git a/openjpeg-1.5.0-cmake_libdir.patch b/openjpeg-1.5.0-cmake_libdir.patch
new file mode 100644
index 0000000..a8eb427
--- /dev/null
+++ b/openjpeg-1.5.0-cmake_libdir.patch
@@ -0,0 +1,21 @@
+diff -up openjpeg-1.5.0/CMakeLists.txt.pkgconfig openjpeg-1.5.0/CMakeLists.txt
+--- openjpeg-1.5.0/CMakeLists.txt.pkgconfig 2012-02-07 04:49:55.000000000 -0600
++++ openjpeg-1.5.0/CMakeLists.txt 2012-02-09 14:11:50.695269015 -0600
+@@ -107,7 +107,7 @@ IF(NOT OPENJPEG_INSTALL_DOC_DIR)
+ ENDIF(NOT OPENJPEG_INSTALL_DOC_DIR)
+
+ IF(NOT OPENJPEG_INSTALL_PACKAGE_DIR)
+- SET(OPENJPEG_INSTALL_PACKAGE_DIR "${OPENJPEG_INSTALL_SHARE_DIR}/${OPENJPEG_INSTALL_SUBDIR}")
++ SET(OPENJPEG_INSTALL_PACKAGE_DIR "${OPENJPEG_INSTALL_LIB_DIR}/${OPENJPEG_INSTALL_SUBDIR}")
+ ENDIF(NOT OPENJPEG_INSTALL_PACKAGE_DIR)
+
+ #-----------------------------------------------------------------------------
+@@ -146,7 +146,7 @@ IF(UNIX)
+ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libopenjpeg1.pc.cmake
+ ${CMAKE_CURRENT_BINARY_DIR}/libopenjpeg1.pc @ONLY)
+ INSTALL( FILES ${CMAKE_CURRENT_BINARY_DIR}/libopenjpeg1.pc DESTINATION
+- ${OPENJPEG_INSTALL_SHARE_DIR}/pkgconfig )
++ ${OPENJPEG_INSTALL_LIB_DIR}/pkgconfig )
+ INSTALL( CODE "EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E create_symlink
+ \"libopenjpeg1.pc\"
+ \"\$ENV{DESTDIR}${OPENJPEG_INSTALL_LIB_DIR}/pkgconfig/libopenjpeg.pc\")")
diff --git a/openjpeg.spec b/openjpeg.spec
index db5404e..8babc77 100644
--- a/openjpeg.spec
+++ b/openjpeg.spec
@@ -4,15 +4,12 @@
# upstreamable patches -- Rex
%define cmake_build 1
-## enable conformance tests, bloats srpm
-# enable for rawhide only, should disable in production releases
-%if 0%{?fedora} > 16
-%define runcheck 1
-%endif
+# enable conformance tests
+#define runcheck 1
Name: openjpeg
-Version: 1.4
-Release: 11%{?dist}
+Version: 1.5.0
+Release: 1%{?dist}
Summary: JPEG 2000 command line tools
Group: Applications/Multimedia
@@ -20,9 +17,10 @@ License: BSD
URL: http://code.google.com/p/openjpeg/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-Source0: http://openjpeg.googlecode.com/files/openjpeg_v1_4_sources_r697.tgz
+Source0: http://openjpeg.googlecode.com/files/openjpeg-%{version}.tar.gz
%if 0%{?runcheck}
-Source1: http://www.crc.ricoh.com/~gormish/jpeg2000conformance/j2kp4files_v1_5.zip
+# svn checkout http://openjpeg.googlecode.com/svn/data
+Source1: data.tar.xz
%endif
%if 0%{?cmake_build}
@@ -30,32 +28,20 @@ BuildRequires: cmake
%else
BuildRequires: automake libtool
%endif
+BuildRequires: doxygen
BuildRequires: libtiff-devel
+BuildRequires: pkgconfig(lcms2)
+BuildRequires: pkgconfig(libpng)
+BuildRequires: pkgconfig(zlib)
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
## upstreamable patches
-# libopenjpeg has undefined references, http://bugzilla.redhat.com/467661
-# http://groups.google.com/group/openjpeg/browse_thread/thread/fba9ad2a35b12e6a
-Patch50: openjpeg-1.4-no_undefined.patch
-# Use soversion 3 (instead of 1.4)
-# http://groups.google.com/group/openjpeg/browse_thread/thread/b9a1d1bfb6f8d09a
-Patch51: openjpeg-1.4-cmake_soversion_3.patch
-# fix autoconf buildsys (+DESTDIR support mostly)
-# http://groups.google.com/group/openjpeg/browse_thread/thread/6326363ebb969a99
-Patch52: openjpeg-1.4-autoconf.patch
-# fix cmake to install pkgconfig file(s)
-# http://groups.google.com/group/openjpeg/browse_thread/thread/545a90cf2b0e4af2
-Patch53: openjpeg-1.4-cmake_pkgconfig.patch
-# fix cmake create_symlink usage
-Patch54: openjpeg-1.4-cmake_symlink_fix.patch
-# fix OpenJPEGConfig.cmake, https://bugzilla.redhat.com/show_bug.cgi?id=669425
-Patch55: openjpeg-1.4-OpenJPEGConfig.patch
+Patch50: openjpeg-1.5.0-cmake_libdir.patch
+Patch51: openjpeg-1.5.0-cmake_header_symlink.patch
+Patch52: openjpeg-1.5.0-cmake_Config.patch
## upstream patches:
-# http://code.google.com/p/openjpeg/issues/detail?id=104
-# http://code.google.com/p/openjpeg/source/detail?r=1333
-Patch100: openjpeg-1.4-poppler_regression.patch
%description
OpenJPEG is an open-source JPEG 2000 codec written in C. It has been
@@ -73,40 +59,35 @@ OpenJPEG.
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: %{name} = %{version}-%{release}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use OpenJPEG.
%prep
-%setup -q -n openjpeg_v1_4_sources_r697 %{?runcheck:-a 1}
-
-# Make sure we use system libraries
-rm -rf libs
+%setup -q %{?runcheck:-a 1}
-%patch50 -p1 -b .no_undefined
%if 0%{?cmake_build}
-%patch51 -p1 -b .cmake_soversion_3
-%patch53 -p1 -b .cmake_pkgconfig
-%patch54 -p1 -b .cmake_symlink_fix
-%patch55 -p1 -b .cmake_OpenJPEGConfig
+%patch50 -p1 -b .cmake_libdir
+%patch51 -p1 -b .cmake_header_symlink
+%patch52 -p1 -b .cmake_Config
%else
-%patch52 -p1 -b .autoconf
autoreconf -i -f
%endif
-%patch100 -p1 -b .poppler_regression
%build
+%{?runcheck:export OPJ_DATA_ROOT=$(pwd)/data}
+
%if 0%{?cmake_build}
mkdir -p %{_target_platform}
pushd %{_target_platform}
%{cmake} \
- -DBUILD_EXAMPLES:BOOL=ON \
+ -DBUILD_DOC:BOOL=ON \
-DBUILD_SHARED_LIBS:BOOL=ON \
%{?runcheck:-DBUILD_TESTING:BOOL=ON} \
- -DJPEG2000_CONFORMANCE_DATA_ROOT:PATH=../J2KP4files/ \
-DOPENJPEG_INSTALL_BIN_DIR:PATH=%{_bindir} \
-DOPENJPEG_INSTALL_DATA_DIR:PATH=%{_datadir} \
-DOPENJPEG_INSTALL_INCLUDE_DIR:PATH=%{_includedir} \
@@ -115,14 +96,15 @@ pushd %{_target_platform}
popd
make %{?_smp_mflags} -C %{_target_platform}
+make doc -C %{_target_platform}
%else
%configure \
--enable-shared \
--disable-static
-# smp build busted
-make
+make %{?_smp_mflags}
+make doc
%endif
@@ -135,63 +117,51 @@ make install/fast DESTDIR=%{buildroot} -C %{_target_platform}
make install DESTDIR=%{buildroot}
%endif
-ln -s openjpeg-1.4 %{buildroot}%{_includedir}/openjpeg
-
## unpackaged files
# we use %%doc in -libs below instead
-rm -rfv %buildroot%{_docdir}/openjpeg-1.4/
+rm -rfv %{buildroot}%{_docdir}/openjpeg-1.5/
+rm -fv %{buildroot}%{_libdir}/lib*.la
%check
-## known failures (on rex's f14/x86_64 box anyway)
-# lots, all raw image tests fail atm (command-line options need tweaking)
+## known failures (on rex's f16/x86_64 box anyway)
%if 0%{?runcheck}
make test -C %{_target_platform} ||:
%endif
-%clean
-rm -rf %{buildroot}
-
-
-%post libs -p /sbin/ldconfig
-
-%postun libs -p /sbin/ldconfig
-
-%pre devel
-# workaround for rpm bug, can be removed in F-18
-[ $1 -gt 1 ] && [ ! -L %{_includedir}/openjpeg ] && rm -rf %{_includedir}/openjpeg || :
-
%files
-%defattr(-,root,root,-)
%{_bindir}/image_to_j2k
%{_bindir}/j2k_dump
%{_bindir}/j2k_to_image
-%{_mandir}/man1/image_to_j2k.1*
-%{_mandir}/man1/j2k_dump.1*
-%{_mandir}/man1/j2k_to_image.1*
+%{_mandir}/man1/*image_to_j2k.1*
+%{_mandir}/man1/*j2k_dump.1*
+%{_mandir}/man1/*j2k_to_image.1*
+
+%post libs -p /sbin/ldconfig
+%postun libs -p /sbin/ldconfig
%files libs
-%defattr(-,root,root,-)
%doc CHANGES LICENSE
-%{_libdir}/libopenjpeg.so.3*
-%{_mandir}/man3/libopenjpeg.3*
+%{_libdir}/libopenjpeg.so.1*
+%{_mandir}/man3/*libopenjpeg.3*
%files devel
-%defattr(-,root,root,-)
-%{_includedir}/openjpeg-1.4/
+%doc %{?cmake_build:%{_target_platform}/}doc/html/
+%{_includedir}/openjpeg-1.5/
+%{_includedir}/openjpeg.h
%{_libdir}/libopenjpeg.so
%{_libdir}/pkgconfig/libopenjpeg.pc
%{_libdir}/pkgconfig/libopenjpeg1.pc
%if 0%{?cmake_build}
-%{_libdir}/openjpeg-1.4/
+%{_libdir}/openjpeg-1.5/
%endif
-# legacy/compat header locations
-%{_includedir}/openjpeg.h
-%{_includedir}/openjpeg/
%changelog
+* Thu Feb 09 2012 Rex Dieter <rdieter at fedoraproject.org> 1.5.0-1
+- 1.5.0
+
* Wed Feb 01 2012 Jaromir Capik <jcapik at redhat.com> 1.4-11
- fix for #726262 - /usr/include/openjpeg changed to a symlink
- rpm bug workaround
diff --git a/sources b/sources
index 173e9c9..a3a4ef4 100644
--- a/sources
+++ b/sources
@@ -1,2 +1 @@
-27780ed3254e6eb763ebd718a8ccc340 j2kp4files_v1_5.zip
-7870bb84e810dec63fcf3b712ebb93db openjpeg_v1_4_sources_r697.tgz
+e5d66193ddfa59a87da1eb08ea86293b openjpeg-1.5.0.tar.gz
More information about the scm-commits
mailing list