1 |
pinkbyte 13/12/27 17:08:26 |
2 |
|
3 |
Modified: metadata.xml ChangeLog |
4 |
Added: boost-1.55.0-r1.ebuild |
5 |
Removed: boost-1.55.0.ebuild |
6 |
Log: |
7 |
Revision bump: implement conditional building of Boost.Context library via 'context' USE-flag. Drop old revision |
8 |
|
9 |
(Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key 0x1F357D42) |
10 |
|
11 |
Revision Changes Path |
12 |
1.24 dev-libs/boost/metadata.xml |
13 |
|
14 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/metadata.xml?rev=1.24&view=markup |
15 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/metadata.xml?rev=1.24&content-type=text/plain |
16 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/metadata.xml?r1=1.23&r2=1.24 |
17 |
|
18 |
Index: metadata.xml |
19 |
=================================================================== |
20 |
RCS file: /var/cvsroot/gentoo-x86/dev-libs/boost/metadata.xml,v |
21 |
retrieving revision 1.23 |
22 |
retrieving revision 1.24 |
23 |
diff -u -r1.23 -r1.24 |
24 |
--- metadata.xml 15 Dec 2012 14:45:27 -0000 1.23 |
25 |
+++ metadata.xml 27 Dec 2013 17:08:26 -0000 1.24 |
26 |
@@ -3,6 +3,10 @@ |
27 |
<pkgmetadata> |
28 |
<herd>cpp</herd> |
29 |
<use> |
30 |
+ <flag name='context'> |
31 |
+ Build and install the Boost.Context library and all other |
32 |
+ Boostlibraries that depends on it |
33 |
+ </flag> |
34 |
<flag name='tools'> |
35 |
Build and install the boost tools (bcp, quickbook, inspect, |
36 |
wave) |
37 |
|
38 |
|
39 |
|
40 |
1.311 dev-libs/boost/ChangeLog |
41 |
|
42 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/ChangeLog?rev=1.311&view=markup |
43 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/ChangeLog?rev=1.311&content-type=text/plain |
44 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/ChangeLog?r1=1.310&r2=1.311 |
45 |
|
46 |
Index: ChangeLog |
47 |
=================================================================== |
48 |
RCS file: /var/cvsroot/gentoo-x86/dev-libs/boost/ChangeLog,v |
49 |
retrieving revision 1.310 |
50 |
retrieving revision 1.311 |
51 |
diff -u -r1.310 -r1.311 |
52 |
--- ChangeLog 27 Dec 2013 16:59:47 -0000 1.310 |
53 |
+++ ChangeLog 27 Dec 2013 17:08:26 -0000 1.311 |
54 |
@@ -1,6 +1,13 @@ |
55 |
# ChangeLog for dev-libs/boost |
56 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
57 |
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/boost/ChangeLog,v 1.310 2013/12/27 16:59:47 pinkbyte Exp $ |
58 |
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/boost/ChangeLog,v 1.311 2013/12/27 17:08:26 pinkbyte Exp $ |
59 |
+ |
60 |
+*boost-1.55.0-r1 (27 Dec 2013) |
61 |
+ |
62 |
+ 27 Dec 2013; Sergey Popov <pinkbyte@g.o> -boost-1.55.0.ebuild, |
63 |
+ +boost-1.55.0-r1.ebuild, metadata.xml: |
64 |
+ Revision bump: implement conditional building of Boost.Context library via |
65 |
+ 'context' USE-flag. Drop old revision |
66 |
|
67 |
*boost-1.54.0-r1 (27 Dec 2013) |
68 |
*boost-1.53.0-r1 (27 Dec 2013) |
69 |
|
70 |
|
71 |
|
72 |
1.1 dev-libs/boost/boost-1.55.0-r1.ebuild |
73 |
|
74 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/boost-1.55.0-r1.ebuild?rev=1.1&view=markup |
75 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/boost/boost-1.55.0-r1.ebuild?rev=1.1&content-type=text/plain |
76 |
|
77 |
Index: boost-1.55.0-r1.ebuild |
78 |
=================================================================== |
79 |
# Copyright 1999-2013 Gentoo Foundation |
80 |
# Distributed under the terms of the GNU General Public License v2 |
81 |
# $Header: /var/cvsroot/gentoo-x86/dev-libs/boost/boost-1.55.0-r1.ebuild,v 1.1 2013/12/27 17:08:26 pinkbyte Exp $ |
82 |
|
83 |
EAPI="5" |
84 |
PYTHON_COMPAT=( python{2_6,2_7,3_2,3_3} ) |
85 |
|
86 |
inherit eutils flag-o-matic multilib multiprocessing python-r1 toolchain-funcs versionator |
87 |
|
88 |
MY_P="${PN}_$(replace_all_version_separators _)" |
89 |
MAJOR_V="$(get_version_component_range 1-2)" |
90 |
|
91 |
DESCRIPTION="Boost Libraries for C++" |
92 |
HOMEPAGE="http://www.boost.org/" |
93 |
SRC_URI="mirror://sourceforge/boost/${MY_P}.tar.bz2" |
94 |
|
95 |
LICENSE="Boost-1.0" |
96 |
SLOT="0/${PV}" # ${PV} instead ${MAJOR_V} due to bug 486122 |
97 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~amd64-linux ~x86-fbsd ~x86-linux" |
98 |
|
99 |
IUSE="context debug doc icu +nls mpi python static-libs +threads tools" |
100 |
|
101 |
RDEPEND="icu? ( >=dev-libs/icu-3.6:= ) |
102 |
!icu? ( virtual/libiconv ) |
103 |
mpi? ( || ( sys-cluster/openmpi[cxx] sys-cluster/mpich2[cxx,threads] ) ) |
104 |
python? ( ${PYTHON_DEPS} ) |
105 |
app-arch/bzip2 |
106 |
sys-libs/zlib |
107 |
!app-admin/eselect-boost" |
108 |
DEPEND="${RDEPEND} |
109 |
=dev-util/boost-build-${MAJOR_V}*" |
110 |
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" |
111 |
|
112 |
S="${WORKDIR}/${MY_P}" |
113 |
|
114 |
# the tests will never fail because these are not intended as sanity |
115 |
# tests at all. They are more a way for upstream to check their own code |
116 |
# on new compilers. Since they would either be completely unreliable |
117 |
# (failing for no good reason) or completely useless (never failing) |
118 |
# there is no point in having them in the ebuild to begin with. |
119 |
RESTRICT="test" |
120 |
|
121 |
create_user-config.jam() { |
122 |
local compiler compiler_version compiler_executable |
123 |
|
124 |
if [[ ${CHOST} == *-darwin* ]]; then |
125 |
compiler="darwin" |
126 |
compiler_version="$(gcc-fullversion)" |
127 |
compiler_executable="$(tc-getCXX)" |
128 |
else |
129 |
compiler="gcc" |
130 |
compiler_version="$(gcc-version)" |
131 |
compiler_executable="$(tc-getCXX)" |
132 |
fi |
133 |
local mpi_configuration python_configuration |
134 |
|
135 |
if use mpi; then |
136 |
mpi_configuration="using mpi ;" |
137 |
fi |
138 |
|
139 |
if use python; then |
140 |
python_configuration="using python : : ${PYTHON} ;" |
141 |
fi |
142 |
|
143 |
cat > user-config.jam << __EOF__ |
144 |
using ${compiler} : ${compiler_version} : ${compiler_executable} : <cflags>"${CFLAGS}" <cxxflags>"${CXXFLAGS}" <linkflags>"${LDFLAGS}" ; |
145 |
${mpi_configuration} |
146 |
${python_configuration} |
147 |
__EOF__ |
148 |
} |
149 |
|
150 |
src_prepare() { |
151 |
epatch \ |
152 |
"${FILESDIR}/${PN}-1.51.0-respect_python-buildid.patch" \ |
153 |
"${FILESDIR}/${PN}-1.51.0-support_dots_in_python-buildid.patch" \ |
154 |
"${FILESDIR}/${PN}-1.48.0-no_strict_aliasing_python2.patch" \ |
155 |
"${FILESDIR}/${PN}-1.48.0-disable_libboost_python3.patch" \ |
156 |
"${FILESDIR}/${PN}-1.48.0-python_linking.patch" \ |
157 |
"${FILESDIR}/${PN}-1.48.0-disable_icu_rpath.patch" \ |
158 |
"${FILESDIR}/${PN}-1.55.0-context-x32.patch" |
159 |
} |
160 |
|
161 |
ejam() { |
162 |
echo b2 "$@" |
163 |
b2 "$@" |
164 |
} |
165 |
|
166 |
src_configure() { |
167 |
OPTIONS="$(usex debug gentoodebug gentoorelease) -j$(makeopts_jobs) -q -d+2 --user-config=${S}/user-config.jam" |
168 |
|
169 |
if [[ ${CHOST} == *-darwin* ]]; then |
170 |
# We need to add the prefix, and in two cases this exceeds, so prepare |
171 |
# for the largest possible space allocation. |
172 |
append-ldflags -Wl,-headerpad_max_install_names |
173 |
elif [[ ${CHOST} == *-winnt* ]]; then |
174 |
compiler=parity |
175 |
if [[ $($(tc-getCXX) -v) == *trunk* ]]; then |
176 |
compilerVersion=trunk |
177 |
else |
178 |
compilerVersion=$($(tc-getCXX) -v | sed '1q' \ |
179 |
| sed -e 's,\([a-z]*\) \([0-9]\.[0-9]\.[0-9][^ \t]*\) .*,\2,') |
180 |
fi |
181 |
compilerExecutable=$(tc-getCXX) |
182 |
fi |
183 |
|
184 |
# bug 298489 |
185 |
if use ppc || use ppc64; then |
186 |
[[ $(gcc-version) > 4.3 ]] && append-flags -mno-altivec |
187 |
fi |
188 |
|
189 |
# Do _not_ use C++11 yet, make sure to force GNU C++ 98 standard. |
190 |
append-cxxflags -std=gnu++98 |
191 |
|
192 |
use icu && OPTIONS+=" -sICU_PATH=${EPREFIX}/usr" |
193 |
use icu || OPTIONS+=" --disable-icu boost.locale.icu=off" |
194 |
use mpi || OPTIONS+=" --without-mpi" |
195 |
use python || OPTIONS+=" --without-python" |
196 |
use nls || OPTIONS+=" --without-locale" |
197 |
use context || OPTIONS+=" --without-context --without-coroutine" |
198 |
|
199 |
OPTIONS+=" pch=off" |
200 |
OPTIONS+=" --boost-build=${EPREFIX}/usr/share/boost-build --prefix=\"${ED}usr\"" |
201 |
OPTIONS+=" --layout=system" |
202 |
OPTIONS+=" threading=$(usex threads multi single) link=$(usex static-libs shared,static shared)" |
203 |
|
204 |
[[ ${CHOST} == *-winnt* ]] && OPTIONS+=" -sNO_BZIP2=1" |
205 |
} |
206 |
|
207 |
src_compile() { |
208 |
export BOOST_ROOT="${S}" |
209 |
PYTHON_DIRS="" |
210 |
MPI_PYTHON_MODULE="" |
211 |
|
212 |
building() { |
213 |
create_user-config.jam |
214 |
|
215 |
ejam ${OPTIONS} \ |
216 |
$(use python && echo --python-buildid=${EPYTHON#python}) \ |
217 |
|| die "Building of Boost libraries failed" |
218 |
|
219 |
if use python; then |
220 |
if [[ -z "${PYTHON_DIRS}" ]]; then |
221 |
PYTHON_DIRS="$(find bin.v2/libs -name python | sort)" |
222 |
else |
223 |
if [[ "${PYTHON_DIRS}" != "$(find bin.v2/libs -name python | sort)" ]]; then |
224 |
die "Inconsistent structure of build directories" |
225 |
fi |
226 |
fi |
227 |
|
228 |
local dir |
229 |
for dir in ${PYTHON_DIRS}; do |
230 |
mv ${dir} ${dir}-${EPYTHON} \ |
231 |
|| die "Renaming of '${dir}' to '${dir}-${EPYTHON}' failed" |
232 |
done |
233 |
|
234 |
if use mpi; then |
235 |
if [[ -z "${MPI_PYTHON_MODULE}" ]]; then |
236 |
MPI_PYTHON_MODULE="$(find bin.v2/libs/mpi/build/*/gentoo* -name mpi.so)" |
237 |
if [[ "$(echo "${MPI_PYTHON_MODULE}" | wc -l)" -ne 1 ]]; then |
238 |
die "Multiple mpi.so files found" |
239 |
fi |
240 |
else |
241 |
if [[ "${MPI_PYTHON_MODULE}" != "$(find bin.v2/libs/mpi/build/*/gentoo* -name mpi.so)" ]]; then |
242 |
die "Inconsistent structure of build directories" |
243 |
fi |
244 |
fi |
245 |
|
246 |
mv stage/lib/mpi.so stage/lib/mpi.so-${EPYTHON} \ |
247 |
|| die "Renaming of 'stage/lib/mpi.so' to 'stage/lib/mpi.so-${EPYTHON}' failed" |
248 |
fi |
249 |
fi |
250 |
} |
251 |
if use python; then |
252 |
python_foreach_impl building |
253 |
else |
254 |
building |
255 |
fi |
256 |
|
257 |
if use tools; then |
258 |
pushd tools > /dev/null || die |
259 |
|
260 |
ejam ${OPTIONS} \ |
261 |
|| die "Building of Boost tools failed" |
262 |
popd > /dev/null || die |
263 |
fi |
264 |
} |
265 |
|
266 |
src_install () { |
267 |
installation() { |
268 |
create_user-config.jam |
269 |
|
270 |
if use python; then |
271 |
local dir |
272 |
for dir in ${PYTHON_DIRS}; do |
273 |
cp -pr ${dir}-${EPYTHON} ${dir} \ |
274 |
|| die "Copying of '${dir}-${EPYTHON}' to '${dir}' failed" |
275 |
done |
276 |
|
277 |
if use mpi; then |
278 |
cp -p stage/lib/mpi.so-${EPYTHON} "${MPI_PYTHON_MODULE}" \ |
279 |
|| die "Copying of 'stage/lib/mpi.so-${EPYTHON}' to '${MPI_PYTHON_MODULE}' failed" |
280 |
cp -p stage/lib/mpi.so-${EPYTHON} stage/lib/mpi.so \ |
281 |
|| die "Copying of 'stage/lib/mpi.so-${EPYTHON}' to 'stage/lib/mpi.so' failed" |
282 |
fi |
283 |
fi |
284 |
|
285 |
ejam ${OPTIONS} \ |
286 |
--includedir="${ED}usr/include" \ |
287 |
--libdir="${ED}usr/$(get_libdir)" \ |
288 |
$(use python && echo --python-buildid=${EPYTHON#python}) \ |
289 |
install || die "Installation of Boost libraries failed" |
290 |
|
291 |
if use python; then |
292 |
rm -r ${PYTHON_DIRS} || die |
293 |
|
294 |
# Move mpi.so Python module to Python site-packages directory. |
295 |
# https://svn.boost.org/trac/boost/ticket/2838 |
296 |
if use mpi; then |
297 |
local moddir=$(python_get_sitedir)/boost |
298 |
# moddir already includes eprefix |
299 |
mkdir -p "${D}${moddir}" || die |
300 |
mv "${ED}usr/$(get_libdir)/mpi.so" "${D}${moddir}" || die |
301 |
cat << EOF > "${D}${moddir}/__init__.py" || die |
302 |
import sys |
303 |
if sys.platform.startswith('linux'): |
304 |
import DLFCN |
305 |
flags = sys.getdlopenflags() |
306 |
sys.setdlopenflags(DLFCN.RTLD_NOW | DLFCN.RTLD_GLOBAL) |
307 |
from . import mpi |
308 |
sys.setdlopenflags(flags) |
309 |
del DLFCN, flags |
310 |
else: |
311 |
from . import mpi |
312 |
del sys |
313 |
EOF |
314 |
fi |
315 |
|
316 |
python_optimize |
317 |
fi |
318 |
} |
319 |
if use python; then |
320 |
python_foreach_impl installation |
321 |
else |
322 |
installation |
323 |
fi |
324 |
|
325 |
if ! use python; then |
326 |
rm -r "${ED}"/usr/include/boost/python* || die |
327 |
fi |
328 |
|
329 |
if ! use nls; then |
330 |
rm -r "${ED}"/usr/include/boost/locale || die |
331 |
fi |
332 |
|
333 |
if ! use context; then |
334 |
rm -r "${ED}"/usr/include/boost/context || die |
335 |
rm -r "${ED}"/usr/include/boost/coroutine || die |
336 |
fi |
337 |
|
338 |
if use doc; then |
339 |
find libs/*/* -iname "test" -or -iname "src" | xargs rm -rf |
340 |
dohtml \ |
341 |
-A pdf,txt,cpp,hpp \ |
342 |
*.{htm,html,png,css} \ |
343 |
-r doc |
344 |
dohtml -A pdf,txt -r tools |
345 |
insinto /usr/share/doc/${PF}/html |
346 |
doins -r libs |
347 |
doins -r more |
348 |
|
349 |
# To avoid broken links |
350 |
insinto /usr/share/doc/${PF}/html |
351 |
doins LICENSE_1_0.txt |
352 |
|
353 |
dosym /usr/include/boost /usr/share/doc/${PF}/html/boost |
354 |
fi |
355 |
|
356 |
pushd "${ED}usr/$(get_libdir)" > /dev/null || die |
357 |
|
358 |
local ext=$(get_libname) |
359 |
if use threads; then |
360 |
local f |
361 |
for f in *${ext}; do |
362 |
dosym ${f} /usr/$(get_libdir)/${f/${ext}/-mt${ext}} |
363 |
done |
364 |
fi |
365 |
|
366 |
popd > /dev/null || die |
367 |
|
368 |
if use tools; then |
369 |
dobin dist/bin/* |
370 |
|
371 |
insinto /usr/share |
372 |
doins -r dist/share/boostbook |
373 |
fi |
374 |
|
375 |
# boost's build system truely sucks for not having a destdir. Because for |
376 |
# this reason we are forced to build with a prefix that includes the |
377 |
# DESTROOT, dynamic libraries on Darwin end messed up, referencing the |
378 |
# DESTROOT instread of the actual EPREFIX. There is no way out of here |
379 |
# but to do it the dirty way of manually setting the right install_names. |
380 |
if [[ ${CHOST} == *-darwin* ]]; then |
381 |
einfo "Working around completely broken build-system(tm)" |
382 |
local d |
383 |
for d in "${ED}"usr/lib/*.dylib; do |
384 |
if [[ -f ${d} ]]; then |
385 |
# fix the "soname" |
386 |
ebegin " correcting install_name of ${d#${ED}}" |
387 |
install_name_tool -id "/${d#${D}}" "${d}" |
388 |
eend $? |
389 |
# fix references to other libs |
390 |
refs=$(otool -XL "${d}" | \ |
391 |
sed -e '1d' -e 's/^\t//' | \ |
392 |
grep "^libboost_" | \ |
393 |
cut -f1 -d' ') |
394 |
local r |
395 |
for r in ${refs}; do |
396 |
ebegin " correcting reference to ${r}" |
397 |
install_name_tool -change \ |
398 |
"${r}" \ |
399 |
"${EPREFIX}/usr/lib/${r}" \ |
400 |
"${d}" |
401 |
eend $? |
402 |
done |
403 |
fi |
404 |
done |
405 |
fi |
406 |
} |
407 |
|
408 |
pkg_preinst() { |
409 |
# Yai for having symlinks that are nigh-impossible to remove without |
410 |
# resorting to dirty hacks like these. Removes lingering symlinks |
411 |
# from the slotted versions. |
412 |
local symlink |
413 |
for symlink in "${EROOT}usr/include/boost" "${EROOT}usr/share/boostbook"; do |
414 |
[[ -L ${symlink} ]] && rm -f "${symlink}" |
415 |
done |
416 |
} |