Annotation of /branches/R11-stable/extras/boost/boost-1.55.0-r1.smage2
Parent Directory | Revision Log
Revision 21133 -
(hide annotations)
(download)
Wed Mar 12 12:13:26 2014 UTC (10 years, 2 months ago) by niro
Original Path: trunk/extras/boost/boost-1.55.0-r1.smage2
File size: 11752 byte(s)
Wed Mar 12 12:13:26 2014 UTC (10 years, 2 months ago) by niro
Original Path: trunk/extras/boost/boost-1.55.0-r1.smage2
File size: 11752 byte(s)
auto added: ver bump to 1.55.0-r1
1 | niro | 21133 | # $Id$ |
2 | |||
3 | PNAME="boost" | ||
4 | PVER="1.55.0" | ||
5 | PBUILD="r1" | ||
6 | |||
7 | SPLIT_PACKAGES="boost-system | ||
8 | boost-regex | ||
9 | boost-atomic | ||
10 | boost-chrono | ||
11 | boost-context | ||
12 | boost-date-time | ||
13 | boost-filesystem | ||
14 | boost-graph | ||
15 | boost-iostreams | ||
16 | boost-locale | ||
17 | boost-log | ||
18 | boost-math | ||
19 | boost-program-options | ||
20 | boost-python | ||
21 | boost-random | ||
22 | boost-serialization | ||
23 | boost-signals | ||
24 | boost-test | ||
25 | boost-thread | ||
26 | boost-timer | ||
27 | boost-wave | ||
28 | boost-jam | ||
29 | boost-build | ||
30 | boost | ||
31 | boost-doc | ||
32 | boost-examples" | ||
33 | |||
34 | PCAT="dev-libs" | ||
35 | HOMEPAGE="http://www.boost.org/" | ||
36 | |||
37 | COMMON_DEPEND=">= sys-libs/libstdc++-4.8" | ||
38 | BZIP_DEPEND=">= app-arch/bzip2-1.0.6" | ||
39 | ZLIB_DEPEND=">= sys-libs/zlib-1.2" | ||
40 | PYTHON_DEPEND=">= dev-lang/python-2.7" | ||
41 | ICU_DEPEND=">= dev-libs/icu-50" | ||
42 | |||
43 | SDEPEND="${COMMON_DEPEND} | ||
44 | ${BZIP_DEPEND} | ||
45 | ${ZLIB_DEPEND} | ||
46 | ${PYTHON_DEPEND} | ||
47 | ${ICU_DEPEND}" | ||
48 | |||
49 | SRCFILE="${PNAME}_$(echo ${PVER} | sed "s:\.:_:g").tar.bz2" | ||
50 | SRCDIR="${BUILDDIR}/${PNAME}_$(echo ${PVER} | sed "s:\.:_:g")" | ||
51 | |||
52 | sminclude python mbuild mtools | ||
53 | msetfeature "!check" | ||
54 | |||
55 | SRC_URI=( | ||
56 | sourceforge://${PNAME}/${SRCFILE} | ||
57 | mirror://${PNAME}/${SRCFILE} | ||
58 | mirror://${PNAME}/${PNAME}-1.54.0-fix-macro-for-int128-detection.patch | ||
59 | mirror://${PNAME}/${PNAME}-1.54.0-glibc218.patch | ||
60 | ) | ||
61 | |||
62 | UP2SEPERATOR="_" | ||
63 | UP2DATE="updatecmd_sourceforge ${PNAME} | sed 's:_:.:g'" | ||
64 | |||
65 | # install_boost_lib ${name} | ||
66 | install_boost_lib() | ||
67 | { | ||
68 | local name="$1" | ||
69 | local libname | ||
70 | [[ -z ${name} ]] && die "no name given" | ||
71 | # replace all - with _ | ||
72 | libname="${name//-/_}" | ||
73 | |||
74 | minstalldir /usr/$(mlibdir) || die | ||
75 | |||
76 | # install normal libs if tehy exist | ||
77 | if [ -f stage/lib/lib${libname}.so.${PVER} ] | ||
78 | then | ||
79 | minstallexec stage/lib/lib${libname}.so.${PVER} /usr/$(mlibdir) || die | ||
80 | mlink lib${libname}.so.${PVER} /usr/$(mlibdir)/lib${libname}.so || die | ||
81 | else | ||
82 | echo -e "${COLYELLOW}No normal lib for '${libname}' found!${COLDEFAULT}" | ||
83 | fi | ||
84 | |||
85 | # install multithread libs if they exist | ||
86 | if [ -f stage/lib/lib${libname}-mt.so.${PVER} ] | ||
87 | then | ||
88 | minstallexec stage/lib/lib${libname}-mt.so.${PVER} /usr/$(mlibdir) || die | ||
89 | mlink lib${libname}-mt.so.${PVER} /usr/$(mlibdir)/lib${libname}-mt.so || die | ||
90 | else | ||
91 | echo -e "${COLYELLOW}No multithreading lib for '${libname}' found!${COLDEFAULT}" | ||
92 | fi | ||
93 | |||
94 | minstalldocs LICENSE_1_0.txt || die | ||
95 | } | ||
96 | |||
97 | split_info_boost-atomic() | ||
98 | { | ||
99 | DESCRIPTION="Run-Time component of boost atomic library." | ||
100 | DEPEND="${COMMON_DEPEND}" | ||
101 | } | ||
102 | |||
103 | split_info_boost-chrono() | ||
104 | { | ||
105 | DESCRIPTION="Run-Time component of boost chrono library." | ||
106 | DEPEND="${COMMON_DEPEND} | ||
107 | == dev-libs/boost-system-${PVER}" | ||
108 | } | ||
109 | |||
110 | split_info_boost-context() | ||
111 | { | ||
112 | DESCRIPTION="Run-Time component of boost context library." | ||
113 | DEPEND="${COMMON_DEPEND}" | ||
114 | } | ||
115 | |||
116 | split_info_boost-date-time() | ||
117 | { | ||
118 | DESCRIPTION="Run-Time component of boost date-time library." | ||
119 | DEPEND="${COMMON_DEPEND}" | ||
120 | } | ||
121 | |||
122 | split_info_boost-filesystem() | ||
123 | { | ||
124 | DESCRIPTION="Run-Time component of boost filesystem library." | ||
125 | DEPEND="${COMMON_DEPEND} | ||
126 | == dev-libs/boost-system-${PVER}" | ||
127 | } | ||
128 | |||
129 | split_info_boost-graph() | ||
130 | { | ||
131 | DESCRIPTION="Run-Time component of boost graph library." | ||
132 | DEPEND="${COMMON_DEPEND} | ||
133 | ${ICU_DEPEND} | ||
134 | == dev-libs/boost-regex-${PVER}" | ||
135 | } | ||
136 | |||
137 | split_info_boost-iostreams() | ||
138 | { | ||
139 | DESCRIPTION="Run-Time component of boost iostreams library." | ||
140 | DEPEND="${COMMON_DEPEND} | ||
141 | ${BZIP_DEPEND} | ||
142 | ${ZLIB_DEPEND}" | ||
143 | } | ||
144 | |||
145 | split_info_boost-locale() | ||
146 | { | ||
147 | DESCRIPTION="Run-Time component of boost locale library." | ||
148 | DEPEND="${COMMON_DEPEND} | ||
149 | ${ICU_DEPEND}" | ||
150 | } | ||
151 | |||
152 | split_info_boost-log() | ||
153 | { | ||
154 | DESCRIPTION="Run-Time component of boost log library." | ||
155 | DEPEND="${COMMON_DEPEND}" | ||
156 | } | ||
157 | |||
158 | split_info_boost-math() | ||
159 | { | ||
160 | DESCRIPTION="Math functions for boost TR1/C99 library." | ||
161 | DEPEND="${COMMON_DEPEND}" | ||
162 | } | ||
163 | |||
164 | split_info_boost-program-options() | ||
165 | { | ||
166 | DESCRIPTION="Run-Time component of boost program_options library." | ||
167 | DEPEND="${COMMON_DEPEND}" | ||
168 | } | ||
169 | |||
170 | split_info_boost-python() | ||
171 | { | ||
172 | DESCRIPTION="Run-Time component of boost python library." | ||
173 | DEPEND="${COMMON_DEPEND} | ||
174 | ${PYTHON_DEPEND}" | ||
175 | } | ||
176 | |||
177 | split_info_boost-random() | ||
178 | { | ||
179 | DESCRIPTION="Run-Time component of boost random library." | ||
180 | DEPEND="${COMMON_DEPEND}" | ||
181 | } | ||
182 | |||
183 | split_info_boost-regex() | ||
184 | { | ||
185 | DESCRIPTION="Run-Time component of boost regex library." | ||
186 | DEPEND="${COMMON_DEPEND} | ||
187 | ${ICU_DEPEND}" | ||
188 | } | ||
189 | |||
190 | split_info_boost-serialization() | ||
191 | { | ||
192 | DESCRIPTION="Run-Time component of boost serialization library." | ||
193 | DEPEND="${COMMON_DEPEND}" | ||
194 | } | ||
195 | |||
196 | split_info_boost-signals() | ||
197 | { | ||
198 | DESCRIPTION="Run-Time component of boost signals and slots library." | ||
199 | DEPEND="${COMMON_DEPEND}" | ||
200 | } | ||
201 | |||
202 | split_info_boost-system() | ||
203 | { | ||
204 | DESCRIPTION="Run-Time component of boost system support library." | ||
205 | DEPEND="${COMMON_DEPEND}" | ||
206 | } | ||
207 | |||
208 | split_info_boost-test() | ||
209 | { | ||
210 | DESCRIPTION="Run-Time component of boost test library." | ||
211 | DEPEND="${COMMON_DEPEND}" | ||
212 | } | ||
213 | |||
214 | split_info_boost-thread() | ||
215 | { | ||
216 | DESCRIPTION="Run-Time component of boost thead library." | ||
217 | DEPEND="${COMMON_DEPEND}" | ||
218 | } | ||
219 | |||
220 | split_info_boost-timer() | ||
221 | { | ||
222 | DESCRIPTION="Run-Time component of boost timer library." | ||
223 | DEPEND="${COMMON_DEPEND} | ||
224 | == dev-libs/boost-system-${PVER} | ||
225 | == dev-libs/boost-chrono-${PVER}" | ||
226 | } | ||
227 | |||
228 | split_info_boost-wave() | ||
229 | { | ||
230 | DESCRIPTION="Run-Time component of boost C99/C++ pre-processing library." | ||
231 | DEPEND="${COMMON_DEPEND} | ||
232 | == dev-libs/boost-system-${PVER} | ||
233 | == dev-libs/boost-date-time-${PVER} | ||
234 | == dev-libs/boost-filesystem-${PVER} | ||
235 | == dev-libs/boost-thread-${PVER}" | ||
236 | } | ||
237 | |||
238 | split_info_boost-doc() | ||
239 | { | ||
240 | DESCRIPTION="HTML documentation for the Boost C++ libraries." | ||
241 | DEPEND="" | ||
242 | } | ||
243 | |||
244 | split_info_boost-examples() | ||
245 | { | ||
246 | DESCRIPTION="Source examples for the Boost C++ libraries" | ||
247 | DEPEND=">= dev-libs/boost-${PVER}" | ||
248 | } | ||
249 | |||
250 | split_info_boost-jam() | ||
251 | { | ||
252 | PCAT="dev-util" | ||
253 | DESCRIPTION="Boost.Jam is an alternative to make based on Jam." | ||
254 | DEPEND="${COMMON_DEPEND}" | ||
255 | } | ||
256 | |||
257 | split_info_boost-build() | ||
258 | { | ||
259 | PCAT="dev-util" | ||
260 | DESCRIPTION="Cross platform build system for C++ projects." | ||
261 | DEPEND="== dev-util/boost-jam-${PVER}" | ||
262 | } | ||
263 | |||
264 | split_info_boost() | ||
265 | { | ||
266 | DESCRIPTION="Boost provides free peer-reviewed portable C++ source libraries." | ||
267 | DEPEND="== dev-libs/boost-system-${PVER} | ||
268 | == dev-libs/boost-regex-${PVER} | ||
269 | == dev-libs/boost-atomic-${PVER} | ||
270 | == dev-libs/boost-chrono-${PVER} | ||
271 | == dev-libs/boost-context-${PVER} | ||
272 | == dev-libs/boost-date-time-${PVER} | ||
273 | == dev-libs/boost-filesystem-${PVER} | ||
274 | == dev-libs/boost-graph-${PVER} | ||
275 | == dev-libs/boost-iostreams-${PVER} | ||
276 | == dev-libs/boost-locale-${PVER} | ||
277 | == dev-libs/boost-log-${PVER} | ||
278 | == dev-libs/boost-math-${PVER} | ||
279 | == dev-libs/boost-program-options-${PVER} | ||
280 | == dev-libs/boost-python-${PVER} | ||
281 | == dev-libs/boost-random-${PVER} | ||
282 | == dev-libs/boost-test-${PVER} | ||
283 | == dev-libs/boost-signals-${PVER} | ||
284 | == dev-libs/boost-test-${PVER} | ||
285 | == dev-libs/boost-thread-${PVER} | ||
286 | == dev-libs/boost-timer-${PVER} | ||
287 | == dev-libs/boost-wave-${PVER} | ||
288 | == dev-util/boost-jam-${PVER} | ||
289 | == dev-util/boost-build-${PVER}" | ||
290 | } | ||
291 | |||
292 | src_prepare() | ||
293 | { | ||
294 | munpack ${SRCFILE} || die | ||
295 | cd ${SRCDIR} | ||
296 | |||
297 | mpatch ${PNAME}-1.54.0-fix-macro-for-int128-detection.patch || die | ||
298 | mpatch ${PNAME}-1.54.0-glibc218.patch || die | ||
299 | } | ||
300 | |||
301 | src_compile() | ||
302 | { | ||
303 | # bjam builded with gcc-4.2 segfaults without '-fno-strict-aliasing' | ||
304 | # see: http://svn.boost.org/trac/boost/ticket/977 | ||
305 | export CFLAGS="${CFLAGS} -fno-strict-aliasing" | ||
306 | export CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing" | ||
307 | |||
308 | # first build bjam (must use cc not gcc to use our modified cflags) | ||
309 | cd ${SRCDIR}/tools/build/v2/engine | ||
310 | ./build.sh cc || die | ||
311 | |||
312 | # find bjam exec | ||
313 | local bjam=$(find ${SRCDIR}/tools/build/v2/engine -name bjam -a -type f) | ||
314 | |||
315 | # build bcp | ||
316 | cd ${SRCDIR}/tools/bcp | ||
317 | ${bjam} || die | ||
318 | |||
319 | # build boost libraries | ||
320 | # --layout=tagged will add the "-mt" suffix for multithreaded libraries | ||
321 | # and installs includes in /usr/include/boost. | ||
322 | # --layout=system no longer adds the -mt suffix for multi-threaded libs. | ||
323 | cd ${SRCDIR} | ||
324 | ${bjam} \ | ||
325 | variant=release \ | ||
326 | debug-symbols=off \ | ||
327 | runtime-link=shared \ | ||
328 | link=shared \ | ||
329 | threading=multi \ | ||
330 | python=$(get_python_version) \ | ||
331 | toolset=gcc \ | ||
332 | --prefix=${BINDIR}/usr \ | ||
333 | --layout=system \ | ||
334 | || die | ||
335 | |||
336 | # build pyste | ||
337 | cd ${SRCDIR}/libs/python/pyste/install | ||
338 | python_docompile || die | ||
339 | } | ||
340 | |||
341 | src_install_boost-atomic() | ||
342 | { | ||
343 | cd ${SRCDIR} | ||
344 | install_boost_lib "${PNAME}" || die | ||
345 | } | ||
346 | |||
347 | src_install_boost-chrono() | ||
348 | { | ||
349 | cd ${SRCDIR} | ||
350 | install_boost_lib "${PNAME}" || die | ||
351 | } | ||
352 | |||
353 | src_install_boost-context() | ||
354 | { | ||
355 | cd ${SRCDIR} | ||
356 | install_boost_lib "${PNAME}" || die | ||
357 | } | ||
358 | |||
359 | src_install_boost-date-time() | ||
360 | { | ||
361 | cd ${SRCDIR} | ||
362 | install_boost_lib "${PNAME}" || die | ||
363 | } | ||
364 | |||
365 | src_install_boost-filesystem() | ||
366 | { | ||
367 | cd ${SRCDIR} | ||
368 | install_boost_lib "${PNAME}" || die | ||
369 | } | ||
370 | |||
371 | src_install_boost-graph() | ||
372 | { | ||
373 | cd ${SRCDIR} | ||
374 | install_boost_lib "${PNAME}" || die | ||
375 | } | ||
376 | |||
377 | src_install_boost-iostreams() | ||
378 | { | ||
379 | cd ${SRCDIR} | ||
380 | install_boost_lib "${PNAME}" || die | ||
381 | } | ||
382 | |||
383 | src_install_boost-locale() | ||
384 | { | ||
385 | cd ${SRCDIR} | ||
386 | install_boost_lib "${PNAME}" || die | ||
387 | } | ||
388 | |||
389 | src_install_boost-log() | ||
390 | { | ||
391 | cd ${SRCDIR} | ||
392 | install_boost_lib "${PNAME}" || die | ||
393 | install_boost_lib "${PNAME}_setup" || die | ||
394 | } | ||
395 | |||
396 | src_install_boost-math() | ||
397 | { | ||
398 | cd ${SRCDIR} | ||
399 | install_boost_lib "${PNAME}_c99" || die | ||
400 | install_boost_lib "${PNAME}_c99f" || die | ||
401 | install_boost_lib "${PNAME}_c99l" || die | ||
402 | install_boost_lib "${PNAME}_tr1" || die | ||
403 | install_boost_lib "${PNAME}_tr1f" || die | ||
404 | install_boost_lib "${PNAME}_tr1l" || die | ||
405 | } | ||
406 | |||
407 | src_install_boost-program-options() | ||
408 | { | ||
409 | cd ${SRCDIR} | ||
410 | install_boost_lib "${PNAME}" || die | ||
411 | } | ||
412 | |||
413 | src_install_boost-python() | ||
414 | { | ||
415 | cd ${SRCDIR} | ||
416 | install_boost_lib "${PNAME}" || die | ||
417 | } | ||
418 | |||
419 | src_install_boost-random() | ||
420 | { | ||
421 | cd ${SRCDIR} | ||
422 | install_boost_lib "${PNAME}" || die | ||
423 | } | ||
424 | |||
425 | src_install_boost-regex() | ||
426 | { | ||
427 | cd ${SRCDIR} | ||
428 | install_boost_lib "${PNAME}" || die | ||
429 | } | ||
430 | |||
431 | src_install_boost-serialization() | ||
432 | { | ||
433 | cd ${SRCDIR} | ||
434 | install_boost_lib "${PNAME}" || die | ||
435 | install_boost_lib "boost_wserialization" || die | ||
436 | } | ||
437 | |||
438 | src_install_boost-signals() | ||
439 | { | ||
440 | cd ${SRCDIR} | ||
441 | install_boost_lib "${PNAME}" || die | ||
442 | } | ||
443 | |||
444 | src_install_boost-system() | ||
445 | { | ||
446 | cd ${SRCDIR} | ||
447 | install_boost_lib "${PNAME}" || die | ||
448 | } | ||
449 | |||
450 | src_install_boost-test() | ||
451 | { | ||
452 | cd ${SRCDIR} | ||
453 | install_boost_lib "boost_prg_exec_monitor" || die | ||
454 | install_boost_lib "boost_unit_test_framework" || die | ||
455 | } | ||
456 | |||
457 | src_install_boost-thread() | ||
458 | { | ||
459 | cd ${SRCDIR} | ||
460 | install_boost_lib "${PNAME}" || die | ||
461 | } | ||
462 | |||
463 | src_install_boost-timer() | ||
464 | { | ||
465 | cd ${SRCDIR} | ||
466 | install_boost_lib "${PNAME}" || die | ||
467 | } | ||
468 | |||
469 | src_install_boost-wave() | ||
470 | { | ||
471 | cd ${SRCDIR} | ||
472 | install_boost_lib "${PNAME}" || die | ||
473 | } | ||
474 | |||
475 | src_install_boost-jam() | ||
476 | { | ||
477 | cd ${SRCDIR} | ||
478 | |||
479 | # find bjam exec | ||
480 | local bjam=$(find ${SRCDIR}/tools/build/v2/engine -name bjam -a -type f) | ||
481 | minstallexec ${bjam} || die | ||
482 | |||
483 | minstalldocs LICENSE_1_0.txt || die | ||
484 | } | ||
485 | |||
486 | src_install_boost-build() | ||
487 | { | ||
488 | cd ${SRCDIR} | ||
489 | minstalldir /usr/share || die | ||
490 | mcopy -a tools/build /usr/share/boost-build || die | ||
491 | |||
492 | # cleanup things provided by other packages | ||
493 | mdelete -r /usr/share/boost-build/v2/doc || die | ||
494 | mdelete -r /usr/share/boost-build/v2/example || die | ||
495 | |||
496 | # cleanup uneccessary stuff | ||
497 | mdelete -r /usr/share/boost-build/v2/debian || die | ||
498 | mdelete -r /usr/share/boost-build/v2/notes || die | ||
499 | mdelete /usr/share/boost-build/v2/\*.txt || die | ||
500 | |||
501 | minstalldocs LICENSE_1_0.txt || die | ||
502 | minstalldocs tools/build/v2/*.txt || die | ||
503 | minstalldocs tools/build/v2/notes/*.txt || die | ||
504 | } | ||
505 | |||
506 | src_install_boost-doc() | ||
507 | { | ||
508 | cd ${SRCDIR} | ||
509 | minstalldir /usr/share/doc || die | ||
510 | mcopy -a doc/html /usr/share/doc/${PNAME}-${PVER} || die | ||
511 | } | ||
512 | |||
513 | src_install_boost-examples() | ||
514 | { | ||
515 | cd ${SRCDIR} | ||
516 | minstalldir /usr/share/doc || die | ||
517 | mcopy -a tools/build/v2/example /usr/share/doc/${PNAME}-${PVER} || die | ||
518 | minstalldocs LICENSE_1_0.txt || die | ||
519 | } | ||
520 | |||
521 | src_install_boost() | ||
522 | { | ||
523 | cd ${SRCDIR} | ||
524 | |||
525 | # find bjam exec | ||
526 | local bjam=$(find ${SRCDIR}/tools/build/v2/engine -name bjam -a -type f) | ||
527 | |||
528 | # install boost | ||
529 | ${bjam} \ | ||
530 | variant=release \ | ||
531 | debug-symbols=off \ | ||
532 | runtime-link=shared \ | ||
533 | link=shared \ | ||
534 | threading=multi \ | ||
535 | python=$(get_python_version) \ | ||
536 | toolset=gcc \ | ||
537 | --prefix=${BINDIR}/usr \ | ||
538 | --libdir=${BINDIR}/usr/$(mlibdir) \ | ||
539 | --layout=system \ | ||
540 | install \ | ||
541 | || die | ||
542 | |||
543 | # install bcp executables | ||
544 | minstallexec dist/bin/bcp || die | ||
545 | |||
546 | # install pyste | ||
547 | cd libs/python/pyste/install | ||
548 | python_doinstall || die | ||
549 | |||
550 | # install docs | ||
551 | cd ${SRCDIR} | ||
552 | minstalldocs LICENSE_1_0.txt README || die | ||
553 | |||
554 | # cleanup things provided by other packages | ||
555 | mdelete /usr/$(mlibdir)/libboost\*.so\* || die | ||
556 | mdelete /usr/$(mlibdir)/libboost\*.a || die | ||
557 | } |