]>
Commit | Line | Data |
---|---|---|
d97fa3b7 ŁK |
1 | # |
2 | # Conditional build: | |
320e1ccc JB |
3 | %bcond_with context # enable Boost Context [crosscompilation problems] |
4 | %bcond_with serialization # enable Boost Serialization [requires wine hacks] | |
d97fa3b7 | 5 | # |
28441938 | 6 | %define realname boost |
3ea966e4 JB |
7 | Summary: The Boost C++ Libraries - MinGW32 cross version |
8 | Summary(pl.UTF-8): Biblioteki C++ "Boost" - wersja skrośna dla MinGW32 | |
28441938 | 9 | Name: crossmingw32-%{realname} |
ac7c1080 | 10 | Version: 1.53.0 |
670a15d7 | 11 | %define fver %(echo %{version} | tr . _) |
ff36f437 | 12 | Release: 1 |
28441938 | 13 | License: Boost Software License and others |
33145f37 | 14 | Group: Development/Libraries |
3ea966e4 | 15 | Source0: http://downloads.sourceforge.net/boost/%{realname}_%{fver}.tar.bz2 |
ac7c1080 | 16 | # Source0-md5: a00d22605d5dbcfb4c9936a9b35bc4c2 |
28441938 | 17 | URL: http://www.boost.org/ |
a72e6f01 | 18 | BuildRequires: crossmingw32-bzip2 |
28441938 | 19 | BuildRequires: crossmingw32-gcc-c++ |
20 | BuildRequires: crossmingw32-runtime | |
21 | BuildRequires: crossmingw32-w32api | |
a72e6f01 | 22 | BuildRequires: crossmingw32-zlib |
d97fa3b7 | 23 | %{?with_serialization:BuildRequires: wine-programs} |
a72e6f01 ŁK |
24 | Requires: crossmingw32-bzip2 |
25 | Requires: crossmingw32-runtime | |
26 | Requires: crossmingw32-zlib | |
28441938 | 27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
28 | ||
29 | %define no_install_post_strip 1 | |
30 | ||
31 | %define target i386-mingw32 | |
32 | %define target_platform i386-pc-mingw32 | |
c66a9041 JB |
33 | |
34 | %define _sysprefix /usr | |
35 | %define _prefix %{_sysprefix}/%{target} | |
36 | %define _libdir %{_prefix}/lib | |
37 | %define _dlldir /usr/share/wine/windows/system | |
28441938 | 38 | |
39 | %define __cc %{target}-gcc | |
40 | %define __cxx %{target}-g++ | |
41 | ||
c66a9041 JB |
42 | %ifnarch %{ix86} |
43 | # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc | |
28441938 | 44 | %define optflags -O2 |
45 | %endif | |
320e1ccc JB |
46 | # -z options are invalid for mingw linker, most of -f options are Linux-specific |
47 | %define filterout_ld -Wl,-z,.* | |
48 | %define filterout_c -f[-a-z0-9=]* | |
49 | %define filterout_cxx -f[-a-z0-9=]* | |
50 | ||
51 | %define abi_tag 1_53 | |
28441938 | 52 | |
53 | %description | |
54 | The Boost web site provides free peer-reviewed portable C++ source | |
55 | libraries. The emphasis is on libraries which work well with the C++ | |
56 | Standard Library. One goal is to establish "existing practice" and | |
57 | provide reference implementations so that the Boost libraries are | |
58 | suitable for eventual standardization. Some of the libraries have | |
59 | already been proposed for inclusion in the C++ Standards Committee's | |
60 | upcoming C++ Standard Library Technical Report. | |
61 | ||
241a7e06 | 62 | %description -l pl.UTF-8 |
28441938 | 63 | Strona http://www.boost.org/ dostarcza darmowe biblioteki C++ wraz z |
241a7e06 JR |
64 | kodem źródłowym. Nacisk położono na biblioteki, które dobrze |
65 | współpracują ze standardową biblioteką C++. Celem jest ustanowienie | |
66 | "istniejącej praktyki" i dostarczenie implementacji, tak że biblioteki | |
67 | "Boost" nadają się do ewentualnej standaryzacji. Niektóre z bibliotek | |
68 | już zostały zgłoszone do komitetu standaryzacyjnego C++ w nadchodzącym | |
05fa162e | 69 | Raporcie Technicznym Biblioteki Standardowej C++. |
28441938 | 70 | |
321d21fc | 71 | %package static |
3ea966e4 JB |
72 | Summary: Static Boost libraries (cross MinGW32 version) |
73 | Summary(pl.UTF-8): Statyczne biblioteki Boost (wersja skrośna MinGW32) | |
321d21fc JB |
74 | Group: Development/Libraries |
75 | Requires: %{name} = %{version}-%{release} | |
76 | ||
77 | %description static | |
3ea966e4 | 78 | Static Boost libraries (cross MinGW32 version). |
321d21fc JB |
79 | |
80 | %description static -l pl.UTF-8 | |
3ea966e4 | 81 | Statyczne biblioteki Boost (wersja skrośna MinGW32). |
321d21fc | 82 | |
28441938 | 83 | %package dll |
c66a9041 JB |
84 | Summary: Boost - DLL libraries for Windows |
85 | Summary(pl.UTF-8): Boost - biblioteki DLL dla Windows | |
28441938 | 86 | Group: Applications/Emulators |
670a15d7 JB |
87 | Requires: crossmingw32-bzip2-dll |
88 | Requires: crossmingw32-zlib-dll | |
89 | Requires: wine | |
28441938 | 90 | |
91 | %description dll | |
c66a9041 | 92 | Boost - DLL libraries for Windows. |
28441938 | 93 | |
241a7e06 | 94 | %description dll -l pl.UTF-8 |
c66a9041 | 95 | Boost - biblioteki DLL dla Windows. |
28441938 | 96 | |
97 | %prep | |
670a15d7 | 98 | %setup -q -n %{realname}_%{fver} |
28441938 | 99 | |
f8be5c0b ŁK |
100 | echo 'using gcc : : %{target}-g++ : <cxxflags>"%{rpmcxxflags}"' \ |
101 | '<archiver>%{target}-ar ;' >tools/build/v2/user-config.jam | |
28441938 | 102 | |
103 | %build | |
d97fa3b7 ŁK |
104 | %if %{with serialization} |
105 | export WINEPREFIX=`pwd`/wineprefix | |
a8f548ca ŁK |
106 | install -d wineprefix/drive_c/windows/system32 |
107 | install %{_prefix}/bin/mingwm10.dll wineprefix/drive_c/windows/system32/ | |
d97fa3b7 ŁK |
108 | %endif |
109 | ||
ac7c1080 ŁK |
110 | ./bootstrap.sh --prefix=%{_prefix} |
111 | ./b2 \ | |
3ea966e4 | 112 | -d2 \ |
320e1ccc | 113 | %{_smp_mflags} \ |
0826927f | 114 | -sBZIP2_BINARY=bzip2 \ |
320e1ccc JB |
115 | --layout=versioned \ |
116 | %{!?with_context:--without-context} \ | |
0826927f | 117 | --without-python \ |
d97fa3b7 | 118 | %{!?with_serialization:--without-serialization} \ |
0826927f | 119 | --without-test \ |
0826927f JB |
120 | debug-symbols=on \ |
121 | inlining=on \ | |
122 | link=static,shared \ | |
ff36f437 | 123 | target-os=windows \ |
320e1ccc | 124 | threadapi=win32 \ |
0826927f | 125 | threading=multi \ |
320e1ccc JB |
126 | toolset=gcc \ |
127 | variant=release | |
28441938 | 128 | |
28441938 | 129 | %if 0%{!?debug:1} |
3ea966e4 JB |
130 | %{target}-strip stage/lib/*.dll |
131 | %{target}-strip -g -R.comment -R.note stage/lib/*.a | |
28441938 | 132 | %endif |
133 | ||
134 | %install | |
135 | rm -rf $RPM_BUILD_ROOT | |
c66a9041 | 136 | install -d $RPM_BUILD_ROOT{%{_includedir},%{_libdir},%{_dlldir}} |
28441938 | 137 | |
c66a9041 | 138 | cp -r boost $RPM_BUILD_ROOT%{_includedir} |
3ea966e4 JB |
139 | cp -a stage/lib/*.a $RPM_BUILD_ROOT%{_libdir} |
140 | install stage/lib/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
28441938 | 141 | |
142 | %clean | |
143 | rm -rf $RPM_BUILD_ROOT | |
144 | ||
145 | %files | |
146 | %defattr(644,root,root,755) | |
320e1ccc JB |
147 | %{_libdir}/libboost_atomic-mgw*-mt-%{abi_tag}.dll.a |
148 | %{_libdir}/libboost_chrono-mgw*-mt-%{abi_tag}.dll.a | |
149 | %{?with_context:%{_libdir}/libboost_context-mgw*-mt-%{abi_tag}.dll.a} | |
150 | %{_libdir}/libboost_date_time-mgw*-mt-%{abi_tag}.dll.a | |
151 | %{_libdir}/libboost_filesystem-mgw*-mt-%{abi_tag}.dll.a | |
152 | %{_libdir}/libboost_graph-mgw*-mt-%{abi_tag}.dll.a | |
153 | %{_libdir}/libboost_iostreams-mgw*-mt-%{abi_tag}.dll.a | |
154 | %{_libdir}/libboost_locale-mgw*-mt-%{abi_tag}.dll.a | |
155 | %{_libdir}/libboost_math_c99-mgw*-mt-%{abi_tag}.dll.a | |
156 | %{_libdir}/libboost_math_c99f-mgw*-mt-%{abi_tag}.dll.a | |
157 | %{_libdir}/libboost_math_c99l-mgw*-mt-%{abi_tag}.dll.a | |
158 | %{_libdir}/libboost_math_tr1-mgw*-mt-%{abi_tag}.dll.a | |
159 | %{_libdir}/libboost_math_tr1f-mgw*-mt-%{abi_tag}.dll.a | |
160 | %{_libdir}/libboost_math_tr1l-mgw*-mt-%{abi_tag}.dll.a | |
161 | %{_libdir}/libboost_program_options-mgw*-mt-%{abi_tag}.dll.a | |
162 | %{_libdir}/libboost_random-mgw*-mt-%{abi_tag}.dll.a | |
163 | %{_libdir}/libboost_regex-mgw*-mt-%{abi_tag}.dll.a | |
164 | %{?with_serialization:%{_libdir}/libboost_serialization-mgw*-mt-%{abi_tag}.dll.a} | |
165 | %{_libdir}/libboost_signals-mgw*-mt-%{abi_tag}.dll.a | |
166 | %{_libdir}/libboost_system-mgw*-mt-%{abi_tag}.dll.a | |
167 | %{_libdir}/libboost_thread_win32-mgw*-mt-%{abi_tag}.dll.a | |
168 | %{_libdir}/libboost_timer-mgw*-mt-%{abi_tag}.dll.a | |
169 | %{_libdir}/libboost_wave-mgw*-mt-%{abi_tag}.dll.a | |
170 | # static-only | |
171 | %{_libdir}/libboost_exception-mgw*-mt-%{abi_tag}.a | |
c66a9041 | 172 | %{_includedir}/boost |
321d21fc JB |
173 | |
174 | %files static | |
175 | %defattr(644,root,root,755) | |
320e1ccc JB |
176 | %{_libdir}/libboost_atomic-mgw*-mt-%{abi_tag}.a |
177 | %{_libdir}/libboost_chrono-mgw*-mt-%{abi_tag}.a | |
178 | %{?with_context:%{_libdir}/libboost_context-mgw*-mt-%{abi_tag}.a} | |
179 | %{_libdir}/libboost_date_time-mgw*-mt-%{abi_tag}.a | |
180 | %{_libdir}/libboost_filesystem-mgw*-mt-%{abi_tag}.a | |
181 | %{_libdir}/libboost_graph-mgw*-mt-%{abi_tag}.a | |
182 | %{_libdir}/libboost_iostreams-mgw*-mt-%{abi_tag}.a | |
183 | %{_libdir}/libboost_locale-mgw*-mt-%{abi_tag}.a | |
184 | %{_libdir}/libboost_math_c99-mgw*-mt-%{abi_tag}.a | |
185 | %{_libdir}/libboost_math_c99f-mgw*-mt-%{abi_tag}.a | |
186 | %{_libdir}/libboost_math_c99l-mgw*-mt-%{abi_tag}.a | |
187 | %{_libdir}/libboost_math_tr1-mgw*-mt-%{abi_tag}.a | |
188 | %{_libdir}/libboost_math_tr1f-mgw*-mt-%{abi_tag}.a | |
189 | %{_libdir}/libboost_math_tr1l-mgw*-mt-%{abi_tag}.a | |
190 | %{_libdir}/libboost_program_options-mgw*-mt-%{abi_tag}.a | |
191 | %{_libdir}/libboost_random-mgw*-mt-%{abi_tag}.a | |
192 | %{_libdir}/libboost_regex-mgw*-mt-%{abi_tag}.a | |
193 | %{?with_serialization:%{_libdir}/libboost_serialization-mgw*-mt-%{abi_tag}.a} | |
194 | %{_libdir}/libboost_signals-mgw*-mt-%{abi_tag}.a | |
195 | %{_libdir}/libboost_system-mgw*-mt-%{abi_tag}.a | |
196 | %{_libdir}/libboost_thread_win32-mgw*-mt-%{abi_tag}.a | |
197 | %{_libdir}/libboost_timer-mgw*-mt-%{abi_tag}.a | |
198 | %{_libdir}/libboost_wave-mgw*-mt-%{abi_tag}.a | |
28441938 | 199 | |
200 | %files dll | |
201 | %defattr(644,root,root,755) | |
320e1ccc JB |
202 | %{_dlldir}/libboost_atomic-mgw*-mt-%{abi_tag}.dll |
203 | %{_dlldir}/libboost_chrono-mgw*-mt-%{abi_tag}.dll | |
204 | %{?with_context:%{_libdir}/libboost_context-mgw*-mt-%{abi_tag}.dll} | |
205 | %{_dlldir}/libboost_date_time-mgw*-mt-%{abi_tag}.dll | |
206 | %{_dlldir}/libboost_filesystem-mgw*-mt-%{abi_tag}.dll | |
207 | %{_dlldir}/libboost_graph-mgw*-mt-%{abi_tag}.dll | |
208 | %{_dlldir}/libboost_iostreams-mgw*-mt-%{abi_tag}.dll | |
209 | %{_dlldir}/libboost_locale-mgw*-mt-%{abi_tag}.dll | |
210 | %{_dlldir}/libboost_math_c99-mgw*-mt-%{abi_tag}.dll | |
211 | %{_dlldir}/libboost_math_c99f-mgw*-mt-%{abi_tag}.dll | |
212 | %{_dlldir}/libboost_math_c99l-mgw*-mt-%{abi_tag}.dll | |
213 | %{_dlldir}/libboost_math_tr1-mgw*-mt-%{abi_tag}.dll | |
214 | %{_dlldir}/libboost_math_tr1f-mgw*-mt-%{abi_tag}.dll | |
215 | %{_dlldir}/libboost_math_tr1l-mgw*-mt-%{abi_tag}.dll | |
216 | %{_dlldir}/libboost_program_options-mgw*-mt-%{abi_tag}.dll | |
217 | %{_dlldir}/libboost_random-mgw*-mt-%{abi_tag}.dll | |
218 | %{_dlldir}/libboost_regex-mgw*-mt-%{abi_tag}.dll | |
219 | %{?with_serialization:%{_dlldir}/libboost_serialization-mgw*-mt-%{abi_tag}.dll} | |
220 | %{_dlldir}/libboost_signals-mgw*-mt-%{abi_tag}.dll | |
221 | %{_dlldir}/libboost_system-mgw*-mt-%{abi_tag}.dll | |
222 | %{_dlldir}/libboost_thread_win32-mgw*-mt-%{abi_tag}.dll | |
223 | %{_dlldir}/libboost_timer-mgw*-mt-%{abi_tag}.dll | |
224 | %{_dlldir}/libboost_wave-mgw*-mt-%{abi_tag}.dll |