Accepting request 287358 from 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. (forwarded request 287338 from rguenther)

OBS-URL: https://build.opensuse.org/request/show/287358
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/boost?expand=0&rev=95
This commit is contained in:
Dominique Leuenberger 2015-02-27 10:08:08 +00:00 committed by Git OBS Bridge
commit 386fe47bf4
3 changed files with 34 additions and 4 deletions

12
boost-gcc5.patch Normal file
View File

@ -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
<toolset>gcc-4.9,<segmented-stacks>on:<linkflags>"-static-libgcc"
<toolset>clang-3.4,<segmented-stacks>on:<cxxflags>-fsplit-stack
<toolset>clang-3.4,<segmented-stacks>on:<linkflags>"-static-libgcc"
+ <toolset>gcc:<cxxflags>-std=c++11
<link>shared:<define>BOOST_COROUTINES_DYN_LINK=1
<define>BOOST_COROUTINES_SOURCE
: usage-requirements

View File

@ -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

View File

@ -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 : : : <compileflags>\$(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