]>
Commit | Line | Data |
---|---|---|
e95d9179 | 1 | # TODO: jbigkit, zstd, libdeflate support |
fc43d37a JB |
2 | Summary: Library for handling TIFF files - cross MinGW32 version |
3 | Summary(pl.UTF-8): Biblioteka do manipulacji plikami w formacie TIFF - wersja skrośna MinGW32 | |
9a892315 JB |
4 | %define realname libtiff |
5 | Name: crossmingw32-%{realname} | |
03e5e171 | 6 | Version: 4.3.0 |
258cbce6 | 7 | Release: 1 |
aaf747bd | 8 | License: BSD-like |
9c36ab3b | 9 | Group: Development/Libraries |
51c63957 | 10 | Source0: http://download.osgeo.org/libtiff/tiff-%{version}.tar.gz |
03e5e171 | 11 | # Source0-md5: 0a2e4744d1426a8fc8211c0cdbc3a1b3 |
51c63957 | 12 | Patch0: %{realname}-glut.patch |
e95d9179 | 13 | URL: http://www.simplesystems.org/libtiff/ |
51c63957 | 14 | BuildRequires: autoconf >= 2.64 |
ede1b237 | 15 | BuildRequires: automake >= 1:1.11 |
99ba0ced | 16 | BuildRequires: crossmingw32-gcc-c++ |
aaf747bd | 17 | BuildRequires: crossmingw32-libjpeg |
03001d2c | 18 | BuildRequires: crossmingw32-libwebp |
aaf747bd | 19 | BuildRequires: crossmingw32-zlib |
51c63957 | 20 | BuildRequires: libtool >= 2:2.2 |
9c36ab3b | 21 | Requires: crossmingw32-libjpeg |
03001d2c | 22 | Requires: crossmingw32-libwebp |
51c63957 | 23 | Requires: crossmingw32-xz |
9c36ab3b | 24 | Requires: crossmingw32-zlib |
aaf747bd | 25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
26 | ||
aaf747bd | 27 | %define no_install_post_strip 1 |
aa283bd0 | 28 | %define _enable_debug_packages 0 |
aaf747bd | 29 | |
30 | %define target i386-mingw32 | |
31 | %define target_platform i386-pc-mingw32 | |
aaf747bd | 32 | |
33 | %define _sysprefix /usr | |
34 | %define _prefix %{_sysprefix}/%{target} | |
9a892315 | 35 | %define _libdir %{_prefix}/lib |
51c63957 | 36 | %define _pkgconfigdir %{_prefix}/lib/pkgconfig |
899284cc | 37 | %define _dlldir /usr/share/wine/windows/system |
aaf747bd | 38 | %define __cc %{target}-gcc |
39 | %define __cxx %{target}-g++ | |
70c709b6 | 40 | %define __pkgconfig_provides %{nil} |
98db55d9 | 41 | %define __pkgconfig_requires %{nil} |
aaf747bd | 42 | |
ede1b237 JB |
43 | %ifnarch %{ix86} |
44 | # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc | |
45 | %define optflags -O2 | |
46 | %endif | |
49e1f909 | 47 | # -z options are invalid for mingw linker, most of -f options are Linux-specific |
ede1b237 | 48 | %define filterout_ld -Wl,-z,.* |
49e1f909 JB |
49 | %define filterout_c -f[-a-z0-9=]* |
50 | %define filterout_cxx -f[-a-z0-9=]* | |
ede1b237 | 51 | |
aaf747bd | 52 | %description |
9c36ab3b | 53 | This package is a library of functions that manipulate TIFF images |
fc43d37a | 54 | (cross MinGW32 version). |
aaf747bd | 55 | |
56 | %description -l pl.UTF-8 | |
57 | Ten pakiet zawiera bibliotekę pozwalającą manipulować plikami w | |
fc43d37a | 58 | formacie TIFF (w wersji skrośnej MinGW32). |
9c36ab3b JB |
59 | |
60 | %package static | |
fc43d37a JB |
61 | Summary: Static libtiff library (cross MinGW32 version) |
62 | Summary(pl.UTF-8): Statyczna biblioteka libtiff (wersja skrośna MinGW32) | |
9c36ab3b JB |
63 | Group: Development/Libraries |
64 | Requires: %{name} = %{version}-%{release} | |
65 | ||
66 | %description static | |
fc43d37a | 67 | Static libtiff library (cross MinGW32 version). |
9c36ab3b JB |
68 | |
69 | %description static -l pl.UTF-8 | |
fc43d37a | 70 | Statyczna biblioteka libtiff (wersja skrośna MinGW32). |
aaf747bd | 71 | |
9c36ab3b JB |
72 | %package dll |
73 | Summary: DLL libtiff library for Windows | |
74 | Summary(pl.UTF-8): Biblioteka DLL libtiff dla Windows | |
75 | Group: Applications/Emulators | |
76 | Requires: wine | |
77 | Requires: crossmingw32-libjpeg-dll | |
03001d2c | 78 | Requires: crossmingw32-libwebp-dll |
51c63957 | 79 | Requires: crossmingw32-xz-dll |
9c36ab3b JB |
80 | Requires: crossmingw32-zlib-dll |
81 | ||
82 | %description dll | |
83 | DLL libtiff library for Windows. | |
84 | ||
85 | %description dll -l pl.UTF-8 | |
86 | Biblioteka DLL libtiff dla Windows. | |
aaf747bd | 87 | |
88 | %package cxx | |
fc43d37a JB |
89 | Summary: libtiff C++ streams library (cross MinGW32 version) |
90 | Summary(pl.UTF-8): Biblioteka strumieni C++ dla libtiff (wersja skrośna MinGW32) | |
9c36ab3b | 91 | Group: Development/Libraries |
aaf747bd | 92 | Requires: %{name} = %{version}-%{release} |
93 | ||
94 | %description cxx | |
fc43d37a | 95 | libtiff C++ streams library (cross MinGW32 version). |
aaf747bd | 96 | |
97 | %description cxx -l pl.UTF-8 | |
fc43d37a | 98 | Biblioteka strumieni C++ dla libtiff (wersja skrośna MinGW32). |
9c36ab3b JB |
99 | |
100 | %package cxx-static | |
fc43d37a JB |
101 | Summary: Static libtiff C++ streams library (cross MinGW32 version) |
102 | Summary(pl.UTF-8): Statyczna biblioteka strumieni C++ dla libtiff (wersja skrośna MinGW32) | |
9c36ab3b JB |
103 | Group: Development/Libraries |
104 | Requires: %{name}-cxx = %{version}-%{release} | |
105 | ||
106 | %description cxx-static | |
fc43d37a | 107 | Static libtiff C++ streams library (cross MinGW32 version). |
9c36ab3b JB |
108 | |
109 | %description cxx-static -l pl.UTF-8 | |
110 | Statyczna biblioteka strumieni C++ dla libtiff (wersja skrośna | |
fc43d37a | 111 | MinGW32). |
9c36ab3b JB |
112 | |
113 | %package cxx-dll | |
114 | Summary: DLL libtiff C++ streams library for Windows | |
115 | Summary(pl.UTF-8): Biblioteka DLL strumieni C++ libtiff dla Windows | |
116 | Group: Applications/Emulators | |
117 | Requires: %{name}-dll = %{version}-%{release} | |
118 | ||
119 | %description cxx-dll | |
120 | DLL libtiff C++ streams library for Windows. | |
121 | ||
122 | %description cxx-dll -l pl.UTF-8 | |
123 | Biblioteka DLL strumieni C++ libtiff dla Windows. | |
aaf747bd | 124 | |
125 | %prep | |
126 | %setup -q -n tiff-%{version} | |
aaf747bd | 127 | %patch0 -p1 |
aaf747bd | 128 | |
129 | %build | |
aaf747bd | 130 | %{__libtoolize} |
131 | %{__aclocal} -I m4 | |
132 | %{__autoconf} | |
133 | %{__autoheader} | |
134 | %{__automake} | |
135 | %configure \ | |
9c36ab3b | 136 | lt_cv_deplibs_check_method=pass_all \ |
aaf747bd | 137 | --target=%{target} \ |
4a078997 | 138 | --host=%{target} \ |
139 | --enable-static | |
aaf747bd | 140 | %{__make} |
141 | ||
142 | %install | |
143 | rm -rf $RPM_BUILD_ROOT | |
aaf747bd | 144 | |
145 | %{__make} install \ | |
146 | DESTDIR=$RPM_BUILD_ROOT | |
147 | ||
9c36ab3b JB |
148 | install -d $RPM_BUILD_ROOT%{_dlldir} |
149 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
150 | ||
151 | %if 0%{!?debug:1} | |
152 | %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
153 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
154 | %endif | |
155 | ||
51c63957 JB |
156 | %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/{doc,man} |
157 | %{__rm} $RPM_BUILD_ROOT%{_bindir}/*.exe | |
aaf747bd | 158 | |
159 | %clean | |
160 | rm -rf $RPM_BUILD_ROOT | |
161 | ||
162 | %files | |
163 | %defattr(644,root,root,755) | |
03001d2c | 164 | %doc COPYRIGHT ChangeLog README.md TODO |
9c36ab3b | 165 | %{_libdir}/libtiff.dll.a |
aaf747bd | 166 | %{_libdir}/libtiff.la |
aaf747bd | 167 | %{_includedir}/tiff*.h |
51c63957 | 168 | %{_pkgconfigdir}/libtiff-4.pc |
aaf747bd | 169 | |
9c36ab3b JB |
170 | %files static |
171 | %defattr(644,root,root,755) | |
172 | %{_libdir}/libtiff.a | |
173 | ||
174 | %files dll | |
175 | %defattr(644,root,root,755) | |
176 | %{_dlldir}/libtiff-*.dll | |
177 | ||
aaf747bd | 178 | %files cxx |
179 | %defattr(644,root,root,755) | |
9c36ab3b | 180 | %{_libdir}/libtiffxx.dll.a |
aaf747bd | 181 | %{_libdir}/libtiffxx.la |
aaf747bd | 182 | %{_includedir}/tiffio.hxx |
9c36ab3b JB |
183 | |
184 | %files cxx-static | |
185 | %defattr(644,root,root,755) | |
186 | %{_libdir}/libtiffxx.a | |
187 | ||
188 | %files cxx-dll | |
189 | %defattr(644,root,root,755) | |
190 | %{_dlldir}/libtiffxx-*.dll |