From d0ce9979f967d49f7516900ef1a2fd19459d6af7878d2f90ce444edb4c7e7c09 Mon Sep 17 00:00:00 2001 From: Richard Biener Date: Mon, 23 Feb 2015 15:30:07 +0000 Subject: [PATCH] Accepting request 287338 from home:rguenther:branches:devel:libraries:c_c++ - Use $RPM_OPT_FLAGS for building, force use of the GCC toolset. Be more verbose and fail building with the first error. - Add boost-gcc5.patch to use -std=c++11 when building the coroutines module which fixes build with GCC 5. OBS-URL: https://build.opensuse.org/request/show/287338 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/boost?expand=0&rev=140 --- boost-gcc5.patch | 12 ++++++++++++ boost.changes | 8 ++++++++ boost.spec | 18 ++++++++++++++---- 3 files changed, 34 insertions(+), 4 deletions(-) create mode 100644 boost-gcc5.patch diff --git a/boost-gcc5.patch b/boost-gcc5.patch new file mode 100644 index 0000000..ced6878 --- /dev/null +++ b/boost-gcc5.patch @@ -0,0 +1,12 @@ +Index: libs/coroutine/build/Jamfile.v2 +=================================================================== +--- libs/coroutine/build/Jamfile.v2.orig 2014-07-09 19:45:23.000000000 +0200 ++++ libs/coroutine/build/Jamfile.v2 2015-02-23 14:30:47.673766402 +0100 +@@ -24,6 +24,7 @@ project boost/coroutine + gcc-4.9,on:"-static-libgcc" + clang-3.4,on:-fsplit-stack + clang-3.4,on:"-static-libgcc" ++ gcc:-std=c++11 + shared:BOOST_COROUTINES_DYN_LINK=1 + BOOST_COROUTINES_SOURCE + : usage-requirements diff --git a/boost.changes b/boost.changes index ad474e1..dc4ca56 100644 --- a/boost.changes +++ b/boost.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Mon Feb 23 13:22:31 UTC 2015 - rguenther@suse.com + +- Use $RPM_OPT_FLAGS for building, force use of the GCC toolset. + Be more verbose and fail building with the first error. +- Add boost-gcc5.patch to use -std=c++11 when building the coroutines + module which fixes build with GCC 5. + ------------------------------------------------------------------- Fri Dec 5 07:44:38 UTC 2014 - dimstar@opensuse.org diff --git a/boost.spec b/boost.spec index 4b5eb1b..6fe4e4c 100644 --- a/boost.spec +++ b/boost.spec @@ -1,7 +1,7 @@ # # spec file for package boost # -# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -88,6 +88,7 @@ Patch4: boost-pool_check_overflow.patch Patch5: boost-strict_aliasing.patch Patch6: boost-use_std_xml_catalog.patch Patch7: bjam-alignment.patch +Patch8: boost-gcc5.patch BuildRequires: chrpath BuildRequires: dos2unix BuildRequires: fdupes @@ -408,6 +409,7 @@ find -type f ! \( -name \*.sh -o -name \*.py -o -name \*.pl \) -exec chmod -x {} %patch5 %patch6 -p1 %patch7 -p1 +%patch8 #stupid build machinery copies .orig files find . -name \*.orig -exec rm {} + @@ -469,11 +471,19 @@ EOF # see also: https://svn.boost.org/trac/boost/ticket/9304 ./bootstrap.sh $LIBRARIES_FLAGS \ --prefix=%{_prefix} --exec-prefix=%{_bindir} \ - --libdir=%{_libdir} --includedir=%{_includedir} + --libdir=%{_libdir} --includedir=%{_includedir} \ + --with-toolset=gcc # add specific wishes in user-config.jam -%if %build_docs cat << EOF >user-config.jam +import os ; +local RPM_OPT_FLAGS = [ os.environ RPM_OPT_FLAGS ] ; + +using gcc : : : \$(RPM_OPT_FLAGS) ; +EOF + +%if %build_docs +cat << EOF >>user-config.jam using xsltproc ; using boostbook @@ -492,7 +502,7 @@ EOF %endif # perform the compilation -./b2 --prefix=%{_prefix} --libdir=%{_libdir} --user-config=./user-config.jam +./b2 -d+2 -q --prefix=%{_prefix} --libdir=%{_libdir} --user-config=./user-config.jam %if %build_docs cd doc