1 %define __strip %{_mingw32_strip}
2 %define __objdump %{_mingw32_objdump}
3 %define _use_internal_dependency_generator 0
4 %define __find_requires %{_mingw32_findrequires}
5 %define __find_provides %{_mingw32_findprovides}
10 Summary: MinGW Windows Jasper library
13 Group: Development/Libraries
15 URL: http://www.ece.uvic.ca/~mdadams/jasper/
16 Source0: http://www.ece.uvic.ca/~mdadams/jasper/software/jasper-%{version}.zip
18 # Patches from Fedora native package.
19 # OpenGL is disabled in this build, so we don't need this patch:
20 #Patch1: jasper-1.701.0-GL.patch
21 # Note patch2 appears in native package, but is not applied:
22 #Patch2: jasper-1.701.0-GL-ac.patch
23 Patch3: patch-libjasper-stepsizes-overflow.diff
25 # MinGW-specific patches.
26 # This patch adds '-no-undefined' flag to libtool line:
27 Patch1000: jasper-1.900.1-mingw32.patch
28 # This patch is a bit of a hack, but it's just there to fix a demo program:
29 Patch1001: jasper-1.900.1-sleep.patch
31 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
34 BuildRequires: mingw32-filesystem >= 23
35 BuildRequires: mingw32-gcc
36 BuildRequires: mingw32-binutils
37 BuildRequires: mingw32-libjpeg
38 BuildRequires: mingw32-dlfcn
42 MinGW Windows Jasper library.
46 %setup -q -n jasper-%{version}
47 %patch3 -p1 -b .CVE-2007-2721
49 %patch1000 -p1 -b .mingw32
50 %patch1001 -p1 -b .sleep
54 %{_mingw32_configure} \
55 --disable-opengl --enable-libjpeg --disable-static --enable-shared
60 rm -rf $RPM_BUILD_ROOT
62 make DESTDIR=$RPM_BUILD_ROOT install mandir=%{_mingw32_mandir}
64 # Remove the manual pages - don't duplicate documentation which
65 # is in the native Fedora package.
66 rm $RPM_BUILD_ROOT%{_mingw32_mandir}/man1/*
70 rm -rf $RPM_BUILD_ROOT
74 %defattr(-,root,root,-)
75 %doc COPYRIGHT LICENSE NEWS README
76 %{_mingw32_bindir}/i686-pc-mingw32-imgcmp.exe
77 %{_mingw32_bindir}/i686-pc-mingw32-imginfo.exe
78 %{_mingw32_bindir}/i686-pc-mingw32-jasper.exe
79 %{_mingw32_bindir}/i686-pc-mingw32-tmrdemo.exe
80 %{_mingw32_bindir}/libjasper-1.dll
81 %{_mingw32_libdir}/libjasper.dll.a
82 %{_mingw32_libdir}/libjasper.la
83 %{_mingw32_includedir}/jasper/
87 * Mon Mar 9 2009 Richard W.M. Jones <rjones@redhat.com> - 1.900.1-8
89 - Remove the enable-shared patch, and just use --enable-shared on
91 - Disable the GL patch since OpenGL is disabled.
92 - Document what the patches are for in the spec file.
93 - Only patch Makefile.in so we don't have to rerun autotools, and
94 remove autotools dependency.
96 * Fri Feb 20 2009 Richard W.M. Jones <rjones@redhat.com> - 1.900.1-7
97 - Rebuild for mingw32-gcc 4.4
99 * Fri Jan 23 2009 Richard W.M. Jones <rjones@redhat.com> - 1.900.1-6
101 - Disable static libraries.
102 - Include documentation.
103 - Use the same patches as Fedora native package.
104 - Just run autoconf instead of autoreconf so we don't upgrade libtool.
106 - Don't need the manual pages.
108 * Wed Sep 24 2008 Richard W.M. Jones <rjones@redhat.com> - 1.900.1-5
109 - Rename mingw -> mingw32.
111 * Mon Sep 22 2008 Daniel P. Berrange <berrange@redhat.com> - 1.900.1-4
112 - Add overflow patch from rawhide
114 * Thu Sep 11 2008 Daniel P. Berrange <berrange@redhat.com> - 1.900.1-3
115 - Run autoreconf after changing configure.ac script and add BRs for autotools
117 * Wed Sep 10 2008 Richard W.M. Jones <rjones@redhat.com> - 1.900.1-2
119 - Remove static libraries.
121 * Tue Sep 9 2008 Daniel P. Berrange <berrange@redhat.com> - 1.900.1-1
122 - Initial RPM release