diff options
Diffstat (limited to 'import-layers/yocto-poky/meta/recipes-support/boost')
13 files changed, 690 insertions, 270 deletions
diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/bjam-native_1.61.0.bb b/import-layers/yocto-poky/meta/recipes-support/boost/bjam-native_1.63.0.bb index 32646d707..46013f343 100644 --- a/import-layers/yocto-poky/meta/recipes-support/boost/bjam-native_1.61.0.bb +++ b/import-layers/yocto-poky/meta/recipes-support/boost/bjam-native_1.63.0.bb @@ -1,4 +1,4 @@ -include boost-${PV}.inc +require boost-${PV}.inc SUMMARY = "Portable Boost.Jam build tool for boost" SECTION = "devel" diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost-1.61.0.inc b/import-layers/yocto-poky/meta/recipes-support/boost/boost-1.63.0.inc index cd9d8a495..b540a8992 100644 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost-1.61.0.inc +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost-1.63.0.inc @@ -7,13 +7,18 @@ HOMEPAGE = "http://www.boost.org/" LICENSE = "BSL-1.0 & MIT & Python-2.0" LIC_FILES_CHKSUM = "file://LICENSE_1_0.txt;md5=e4224ccaecb14d942c71d31bef20d78c" -BOOST_VER = "${@"_".join(d.getVar("PV", True).split("."))}" -BOOST_MAJ = "${@"_".join(d.getVar("PV", True).split(".")[0:2])}" +BOOST_VER = "${@"_".join(d.getVar("PV").split("."))}" +BOOST_MAJ = "${@"_".join(d.getVar("PV").split(".")[0:2])}" BOOST_P = "boost_${BOOST_VER}" -SRC_URI = "${SOURCEFORGE_MIRROR}/boost/${BOOST_P}.tar.bz2" +SRC_URI = "${SOURCEFORGE_MIRROR}/project/boost/boost/${PV}/${BOOST_P}.tar.bz2" -SRC_URI[md5sum] = "6095876341956f65f9d35939ccea1a9f" -SRC_URI[sha256sum] = "a547bd06c2fd9a71ba1d169d9cf0339da7ebf4753849a8f7d6fdb8feee99b640" +SRC_URI[md5sum] = "1c837ecd990bb022d07e7aab32b09847" +SRC_URI[sha256sum] = "beae2529f759f6b3bf3f4969a19c2e9d6f0c503edcb2de4a61d1428519fcb3b0" + +UPSTREAM_CHECK_URI = "http://www.boost.org/users/download/" +UPSTREAM_CHECK_REGEX = "boostorg/release/(?P<pver>.*)/source/" + +PR = "r1" S = "${WORKDIR}/${BOOST_P}" diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost.inc b/import-layers/yocto-poky/meta/recipes-support/boost/boost.inc index 1966d3d80..4ff70e399 100644 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost.inc +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost.inc @@ -42,16 +42,15 @@ PACKAGECONFIG ??= "locale" PACKAGECONFIG[locale] = ",,icu" PACKAGECONFIG[graph_parallel] = ",,,boost-mpi mpich" PACKAGECONFIG[mpi] = ",,mpich" -PACKAGECONFIG[python] = ",,python python3" +PACKAGECONFIG[python] = ",,python3" BOOST_LIBS += "\ - ${@bb.utils.contains('PACKAGECONFIG', 'locale', 'locale', '', d)} \ + ${@bb.utils.filter('PACKAGECONFIG', 'locale python', d)} \ ${@bb.utils.contains('PACKAGECONFIG', 'graph_parallel', 'graph_parallel mpi', \ - bb.utils.contains('PACKAGECONFIG', 'mpi', 'mpi', '', d), d)} \ - ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python python3', '', d)} \ + bb.utils.filter('PACKAGECONFIG', 'mpi', d), d)} \ " -inherit python-dir +inherit python3-dir PYTHON_ROOT = "${STAGING_DIR_HOST}/${prefix}" # Make a package for each library, plus -dev @@ -59,25 +58,17 @@ PACKAGES = "${PN}-dbg ${BOOST_PACKAGES}" python __anonymous () { packages = [] extras = [] - for lib in d.getVar('BOOST_LIBS', True).split( ): - # BJAM does not know '--with-python3' (only --with-python) - if lib != "python3": - extras.append("--with-%s" % lib) + for lib in d.getVar('BOOST_LIBS').split(): + extras.append("--with-%s" % lib) pkg = "boost-%s" % lib.replace("_", "-") packages.append(pkg) - if lib == "python": - # special: python*.so matches python3.so !! - if not d.getVar("FILES_%s" % pkg, True): - d.setVar("FILES_%s" % pkg, "${libdir}/libboost_%s.so.*" % lib) - else: - if not d.getVar("FILES_%s" % pkg, True): - d.setVar("FILES_%s" % pkg, "${libdir}/libboost_%s*.so.*" % lib) + if not d.getVar("FILES_%s" % pkg): + d.setVar("FILES_%s" % pkg, "${libdir}/libboost_%s*.so.*" % lib) d.setVar("BOOST_PACKAGES", " ".join(packages)) d.setVar("BJAM_EXTRA", " ".join(extras)) } # Override the contents of specific packages -FILES_${PN}-graph = "${libdir}/libboost_graph.so.*" FILES_${PN}-graph_parallel = "${libdir}/libboost_graph_parallel.so.*" FILES_${PN}-locale = "${libdir}/libboost_locale.so.*" FILES_${PN}-mpi = "${libdir}/mpi.so ${libdir}/libboost_mpi*.so.*" @@ -88,15 +79,15 @@ FILES_boost-test = "${libdir}/libboost_prg_exec_monitor*.so.* \ # -dev last to pick up the remaining stuff PACKAGES += "${PN}-dev ${PN}-staticdev" -FILES_${PN} = "" FILES_${PN}-dev = "${includedir} ${libdir}/libboost_*.so" FILES_${PN}-staticdev = "${libdir}/libboost_*.a" # "boost" is a metapackage which pulls in all boost librabries PACKAGES += "${PN}" +FILES_${PN} = "" +ALLOW_EMPTY_${PN} = "1" RRECOMMENDS_${PN} += "${BOOST_PACKAGES}" RRECOMMENDS_${PN}_class-native = "" -ALLOW_EMPTY_${PN} = "1" # to avoid GNU_HASH QA errors added LDFLAGS to ARCH; a little bit dirty but at least it works TARGET_CC_ARCH += "${LDFLAGS}" @@ -145,7 +136,7 @@ BJAM_TOOLS = "--ignore-site-config \ # use PARALLEL_MAKE to speed up the build, but limit it by -j 64, greater parallelism causes bjam to segfault or to ignore -j # https://svn.boost.org/trac/boost/ticket/7634 def get_boost_parallel_make(d): - pm = d.getVar('PARALLEL_MAKE', True) + pm = d.getVar('PARALLEL_MAKE') if pm: # look for '-j' and throw other options (e.g. '-l') away # because they might have different meaning in bjam @@ -177,34 +168,42 @@ BJAM_OPTS = '${BOOST_PARALLEL_MAKE} -d+2 -q \ # Native compilation of bzip2 isn't working BJAM_OPTS_append_class-native = ' -sNO_BZIP2=1' +# Adjust the build for x32 +BJAM_OPTS_append_linux-gnux32 = " abi=x32 address-model=64" + do_configure() { cp -f ${S}/boost/config/platform/linux.hpp ${S}/boost/config/platform/linux-gnueabi.hpp # D2194:Fixing the failure of "error: duplicate initialization of gcc with the following parameters" during compilation. rm -f ${WORKDIR}/user-config.jam echo 'using gcc : 4.3.1 : ${CXX} : <cflags>"${CFLAGS}" <cxxflags>"${CXXFLAGS}" <linkflags>"${LDFLAGS}" ;' >> ${WORKDIR}/user-config.jam - echo "using python : ${PYTHON_BASEVERSION} : : ${STAGING_INCDIR}/python${PYTHON_BASEVERSION} ;" >> ${WORKDIR}/user-config.jam - echo "using python : 3.5 : : ${STAGING_INCDIR}/python3.5m ;" >> ${WORKDIR}/user-config.jam + + # If we want Python then we need to tell Boost *exactly* where to find it + if ${@bb.utils.contains('BOOST_LIBS', 'python', 'true', 'false', d)}; then + echo "using python : ${PYTHON_BASEVERSION} : ${STAGING_DIR_HOST}${bindir}/python3 : ${STAGING_DIR_HOST}${includedir}/${PYTHON_DIR}${PYTHON_ABI} : ${STAGING_DIR_HOST}${libdir}/${PYTHON_DIR} ;" >> ${WORKDIR}/user-config.jam + fi if ${@bb.utils.contains('BOOST_LIBS', 'mpi', 'true', 'false', d)}; then echo "using mpi : : <find-shared-library>mpi ;" >> ${WORKDIR}/user-config.jam fi - CC="${BUILD_CC}" CFLAGS="${BUILD_CFLAGS}" ./bootstrap.sh --with-bjam=bjam --with-toolset=gcc --with-python-root=${PYTHON_ROOT} - sed -i '/^using python/d' ${S}/project-config.jam + CC="${BUILD_CC}" CFLAGS="${BUILD_CFLAGS}" ./bootstrap.sh --with-bjam=bjam --with-toolset=gcc + + # Boost can't be trusted to find Python on it's own, so remove any mention + # of it from the boost configuration + sed -i '/using python/d' ${S}/project-config.jam } do_compile() { - set -ex rm -rf ${S}/${TARGET_SYS} bjam ${BJAM_OPTS} --prefix=${prefix} \ --exec-prefix=${exec_prefix} \ --libdir=${libdir} \ - --includedir=${includedir} + --includedir=${includedir} \ + --debug-configuration } do_install() { - set -ex bjam ${BJAM_OPTS} \ --libdir=${D}${libdir} \ --includedir=${D}${includedir} \ diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-Apply-boost-1.62.0-no-forced-flags.patch.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-Apply-boost-1.62.0-no-forced-flags.patch.patch new file mode 100644 index 000000000..169906344 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-Apply-boost-1.62.0-no-forced-flags.patch.patch @@ -0,0 +1,100 @@ +From 8845a786598f1d9e83aa1b7d2966b0d1eb765ba0 Mon Sep 17 00:00:00 2001 +From: Christopher Larson <chris_larson@mentor.com> +Date: Tue, 13 Dec 2016 10:14:31 -0700 +Subject: [PATCH 1/3] Apply boost-1.62.0-no-forced-flags.patch + +Upstream-Status: Inappropriate +Signed-off-by: Christopher Larson <chris_larson@mentor.com> +--- + libs/log/build/Jamfile.v2 | 4 ++-- + libs/log/config/x86-ext/Jamfile.jam | 16 ++++++++-------- + libs/log/src/dump_avx2.cpp | 4 ++++ + libs/log/src/dump_ssse3.cpp | 4 ++++ + 4 files changed, 18 insertions(+), 10 deletions(-) + +diff --git a/libs/log/build/Jamfile.v2 b/libs/log/build/Jamfile.v2 +index 4abbdbc..b3016fc 100644 +--- a/libs/log/build/Jamfile.v2 ++++ b/libs/log/build/Jamfile.v2 +@@ -373,7 +373,7 @@ rule avx2-targets-cond ( properties * ) + } + else if <toolset>clang in $(properties) + { +- result = <cxxflags>"-mavx -mavx2" ; ++ result = <cxxflags> ; + } + else if <toolset>intel in $(properties) + { +@@ -383,7 +383,7 @@ rule avx2-targets-cond ( properties * ) + } + else + { +- result = <cxxflags>"-xCORE-AVX2 -fabi-version=0" ; ++ result = <cxxflags>"-fabi-version=0" ; + } + } + else if <toolset>msvc in $(properties) +diff --git a/libs/log/config/x86-ext/Jamfile.jam b/libs/log/config/x86-ext/Jamfile.jam +index 0e9695a..dcc394d 100644 +--- a/libs/log/config/x86-ext/Jamfile.jam ++++ b/libs/log/config/x86-ext/Jamfile.jam +@@ -15,19 +15,19 @@ project /boost/log/x86-extensions + + obj ssse3 : ssse3.cpp + : +- <toolset>gcc:<cxxflags>"-msse -msse2 -msse3 -mssse3" +- <toolset>clang:<cxxflags>"-msse -msse2 -msse3 -mssse3" +- <toolset>intel-linux:<cxxflags>"-xSSSE3" +- <toolset>intel-darwin:<cxxflags>"-xSSSE3" ++ <toolset>gcc:<cxxflags> ++ <toolset>clang:<cxxflags> ++ <toolset>intel-linux:<cxxflags> ++ <toolset>intel-darwin:<cxxflags> + <toolset>intel-win:<cxxflags>"/QxSSSE3" + ; + + obj avx2 : avx2.cpp + : +- <toolset>gcc:<cxxflags>"-mavx -mavx2 -fabi-version=0" +- <toolset>clang:<cxxflags>"-mavx -mavx2" +- <toolset>intel-linux:<cxxflags>"-xCORE-AVX2 -fabi-version=0" +- <toolset>intel-darwin:<cxxflags>"-xCORE-AVX2 -fabi-version=0" ++ <toolset>gcc:<cxxflags>"-fabi-version=0" ++ <toolset>clang:<cxxflags> ++ <toolset>intel-linux:<cxxflags>"-fabi-version=0" ++ <toolset>intel-darwin:<cxxflags>"-fabi-version=0" + <toolset>intel-win:<cxxflags>"/arch:CORE-AVX2" + <toolset>msvc:<cxxflags>"/arch:AVX" + ; +diff --git a/libs/log/src/dump_avx2.cpp b/libs/log/src/dump_avx2.cpp +index 4ab1250..610fc6d 100644 +--- a/libs/log/src/dump_avx2.cpp ++++ b/libs/log/src/dump_avx2.cpp +@@ -22,6 +22,10 @@ + #include <boost/cstdint.hpp> + #include <boost/log/detail/header.hpp> + ++#if !defined(__AVX2__) ++#error "AVX2 Unsupported!" ++#endif ++ + #if defined(__x86_64) || defined(__x86_64__) || \ + defined(__amd64__) || defined(__amd64) || \ + defined(_M_X64) +diff --git a/libs/log/src/dump_ssse3.cpp b/libs/log/src/dump_ssse3.cpp +index 1325b49..60d4112 100644 +--- a/libs/log/src/dump_ssse3.cpp ++++ b/libs/log/src/dump_ssse3.cpp +@@ -22,6 +22,10 @@ + #include <boost/cstdint.hpp> + #include <boost/log/detail/header.hpp> + ++#if !defined(__SSSE3__) ++#error "SSSE3 Unsupported!" ++#endif ++ + #if defined(__x86_64) || defined(__x86_64__) || \ + defined(__amd64__) || defined(__amd64) || \ + defined(_M_X64) +-- +2.8.0 diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-When-using-soft-float-on-ARM-we-should-not-expect-th.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-When-using-soft-float-on-ARM-we-should-not-expect-th.patch new file mode 100644 index 000000000..bafd5ce00 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0001-When-using-soft-float-on-ARM-we-should-not-expect-th.patch @@ -0,0 +1,29 @@ +From 9ab0914207e6d0e6b75ce12147c54b96478feb64 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Tue, 21 Feb 2017 12:50:35 +0200 +Subject: [PATCH] When using soft-float, on ARM we should not expect the FE_* + symbols + +Upstream-Status: Pending +Signed-off-by: Khem Raj <raj.khem@gmail.com> +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> +--- + boost/test/execution_monitor.hpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/boost/test/execution_monitor.hpp b/boost/test/execution_monitor.hpp +index f53348a..86252d7 100644 +--- a/boost/test/execution_monitor.hpp ++++ b/boost/test/execution_monitor.hpp +@@ -498,7 +498,7 @@ enum masks { + + BOOST_FPE_ALL = MCW_EM, + +-#elif defined(BOOST_NO_FENV_H) || defined(BOOST_CLANG) /* *** */ ++#elif defined(BOOST_NO_FENV_H) || defined(BOOST_CLANG) || defined(__ARM_PCS) /* *** */ + BOOST_FPE_ALL = BOOST_FPE_OFF, + + #else /* *** */ +-- +2.11.0 + diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch new file mode 100644 index 000000000..e9c7e4c55 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch @@ -0,0 +1,97 @@ +From c0e785f8da2caa6617052b1c7b347e0dffb1520d Mon Sep 17 00:00:00 2001 +From: Christopher Larson <chris_larson@mentor.com> +Date: Tue, 13 Dec 2016 10:29:17 -0700 +Subject: [PATCH 2/3] Don't set up -m32/-m64, we do that ourselves + +Upstream-Status: Inappropriate +Signed-off-by: Christopher Larson <chris_larson@mentor.com> +--- + tools/build/src/tools/gcc.jam | 10 ---------- + 1 file changed, 10 deletions(-) + +diff --git a/tools/build/src/tools/gcc.jam b/tools/build/src/tools/gcc.jam +index 0f346a5..942f141 100644 +--- a/tools/build/src/tools/gcc.jam ++++ b/tools/build/src/tools/gcc.jam +@@ -509,7 +509,6 @@ rule compile.c++.pch ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + } + + actions compile.c++.pch +@@ -521,7 +520,6 @@ rule compile.c.pch ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + } + + actions compile.c.pch +@@ -533,7 +531,6 @@ rule compile.c++.preprocess ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + + # Some extensions are compiled as C++ by default. For others, we need to + # pass -x c++. We could always pass -x c++ but distcc does not work with it. +@@ -548,7 +545,6 @@ rule compile.c.preprocess ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + + # If we use the name g++ then default file suffix -> language mapping does + # not work. So have to pass -x option. Maybe, we can work around this by +@@ -564,7 +560,6 @@ rule compile.c++ ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + + # Some extensions are compiled as C++ by default. For others, we need to + # pass -x c++. We could always pass -x c++ but distcc does not work with it. +@@ -594,7 +589,6 @@ rule compile.c ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + + # If we use the name g++ then default file suffix -> language mapping does + # not work. So have to pass -x option. Maybe, we can work around this by +@@ -610,7 +604,6 @@ rule compile.fortran ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + } + + actions compile.c++ bind PCH_FILE +@@ -641,7 +634,6 @@ actions compile.fortran + rule compile.asm ( targets * : sources * : properties * ) + { + setup-fpic $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + LANG on $(<) = "-x assembler-with-cpp" ; + } + +@@ -950,7 +942,6 @@ rule quote-rpath ( targets * ) + rule link ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + SPACE on $(targets) = " " ; + # Serialize execution of the 'link' action, since running N links in + # parallel is just slower. For now, serialize only gcc links, it might be a +@@ -1018,7 +1009,6 @@ actions piecemeal archive + rule link.dll ( targets * : sources * : properties * ) + { + setup-threading $(targets) : $(sources) : $(properties) ; +- setup-address-model $(targets) : $(sources) : $(properties) ; + SPACE on $(targets) = " " ; + JAM_SEMAPHORE on $(targets) = <s>gcc-link-semaphore ; + quote-rpath $(targets) ; +-- +2.8.0 diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-boost-test-execution_monitor.hpp-fix-mips-soft-float.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-boost-test-execution_monitor.hpp-fix-mips-soft-float.patch deleted file mode 100644 index 569c98733..000000000 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0002-boost-test-execution_monitor.hpp-fix-mips-soft-float.patch +++ /dev/null @@ -1,145 +0,0 @@ -From 5c349a1c391c9ce171a1c80f5164fae764f27dba Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <adraszik@tycoint.com> -Date: Wed, 24 Aug 2016 20:58:59 +0100 -Subject: [PATCH 2/4] boost/test/execution_monitor.hpp: fix mips soft float -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -gcc.compile.c++ <builddir>/boost/bin.v2/libs/test/build/gcc-4.3.1/release/threading-multi/execution_monitor.o - - "mipsel-poky-linux-musl-g++" "-mel" "-mabi=32" "-msoft-float" "-march=mips32r2" "-mips16" "-minterlink-compressed" "-mtune=24kec" "-mdsp" "-Wl,-O1" "-Wl,--as-needed" "-fstack-protector-strong" "-Wl,-z,relro,-z,now" "--sysroot=<sysroot>" -ftemplate-depth-128 -O2 -pipe -g -feliminate-unused-debug-types -fdebug-prefix-map=<srcdir>=/usr/src/debug/boost/1.61.0-r0 -fdebug-prefix-map=<sysroot_host>= -fdebug-prefix-map=<sysroot>= -fstack-protector-strong -pie -fpie -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security -fvisibility-inlines-hidden -O3 -finline-functions -Wno-inline -Wall -pedantic -pthread -fPIC -Wno-variadic-macros -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_DYN_LINK=1 -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_TEST_DYN_LINK=1 -DBOOST_TIMER_DYN_LINK=1 -DNDEBUG -I"." -c -o "<builddir>/boost/bin.v2/libs/test/build/gcc-4.3.1/release/threading-multi/execution_monitor.o" "libs/test/src/execution_monitor.cpp" - -In file included from ./boost/test/impl/execution_monitor.ipp:31:0, - from libs/test/src/execution_monitor.cpp:16: -./boost/test/execution_monitor.hpp:491:27: error: 'FE_DIVBYZERO' was not declared in this scope - BOOST_FPE_DIVBYZERO = FE_DIVBYZERO, - ^~~~~~~~~~~~ -./boost/test/execution_monitor.hpp:492:27: error: 'FE_INEXACT' was not declared in this scope - BOOST_FPE_INEXACT = FE_INEXACT, - ^~~~~~~~~~ -./boost/test/execution_monitor.hpp:493:27: error: 'FE_INVALID' was not declared in this scope - BOOST_FPE_INVALID = FE_INVALID, - ^~~~~~~~~~ -./boost/test/execution_monitor.hpp:494:27: error: 'FE_OVERFLOW' was not declared in this scope - BOOST_FPE_OVERFLOW = FE_OVERFLOW, - ^~~~~~~~~~~ -./boost/test/execution_monitor.hpp:495:27: error: 'FE_UNDERFLOW' was not declared in this scope - BOOST_FPE_UNDERFLOW = FE_UNDERFLOW, - ^~~~~~~~~~~~ - -The reason is that some (notably FPU-less) architectures, -including mips*-nf, don't define/implement some of the -floating point constants, even though fenv.h is -available. - -The key point is: - A fully standards conforming fenv.h does not have to - define any FE_* macros, and if it does define them, - then it defines macros only for the FP exceptions it - actually supports. - -So correct usage requires a triple check: -1) Check BOOST_NO_FENV_H to see if the header is supported. -2) Include the header and then check FE_ALL_EXCEPT to see - if any FP exceptions are supported. -3) Before using the individual FE_* macros, you need to - check for their existence too as not all may be - supported. - -https://svn.boost.org/trac/boost/ticket/11756 - -Other projects have similar issues, e.g. pixman, and -apply similar work-arounds: - https://lists.freedesktop.org/archives/pixman/2014-February/003172.html - -Architectures are notably also allowed to define FE_ALL_EXCEPT to 0! -Keeping this in mind, and knowing that the compiler will eliminate -code that can't be executed, we can change BOOST_FPE_ALL to be 0 for -the case of compiling using Clang and/or fenv.h being unavailable -as well, which allows simplification of the #ifdef's in -execution_monitor.ipp a bit. - -Signed-off-by: André Draszik <adraszik@tycoint.com> ---- -Upstream-Status: Submitted https://svn.boost.org/trac/boost/ticket/11756 - boost/test/execution_monitor.hpp | 26 +++++++++++++++++++++++++- - boost/test/impl/execution_monitor.ipp | 10 ++++++++-- - 2 files changed, 33 insertions(+), 3 deletions(-) - -diff --git a/boost/test/execution_monitor.hpp b/boost/test/execution_monitor.hpp -index 0eee497..44fe59d 100644 ---- a/boost/test/execution_monitor.hpp -+++ b/boost/test/execution_monitor.hpp -@@ -486,15 +486,39 @@ enum masks { - BOOST_FPE_ALL = MCW_EM, - #elif defined(BOOST_NO_FENV_H) || defined(BOOST_CLANG) \ - || defined(__ARM_PCS) -- BOOST_FPE_ALL = 1, -+ BOOST_FPE_ALL = 0, - #else -+#if defined(FE_DIVBYZERO) - BOOST_FPE_DIVBYZERO = FE_DIVBYZERO, -+#else -+ BOOST_FPE_DIVBYZERO = 0, -+#endif -+#if defined(FE_INEXACT) - BOOST_FPE_INEXACT = FE_INEXACT, -+#else -+ BOOST_FPE_INEXACT = 0, -+#endif -+#if defined(FE_INVALID) - BOOST_FPE_INVALID = FE_INVALID, -+#else -+ BOOST_FPE_INVALID = 0, -+#endif -+#if defined(FE_OVERFLOW) - BOOST_FPE_OVERFLOW = FE_OVERFLOW, -+#else -+ BOOST_FPE_OVERFLOW = 0, -+#endif -+#if defined(FE_UNDERFLOW) - BOOST_FPE_UNDERFLOW = FE_UNDERFLOW, -+#else -+ BOOST_FPE_UNDERFLOW = 0, -+#endif - -+#if defined(FE_ALL_EXCEPT) - BOOST_FPE_ALL = FE_ALL_EXCEPT, -+#else -+ BOOST_FPE_ALL = 0, -+#endif - #endif - BOOST_FPE_INV = BOOST_FPE_ALL+1 - }; -diff --git a/boost/test/impl/execution_monitor.ipp b/boost/test/impl/execution_monitor.ipp -index f7fc8ea..d1088b9 100644 ---- a/boost/test/impl/execution_monitor.ipp -+++ b/boost/test/impl/execution_monitor.ipp -@@ -1381,7 +1381,10 @@ enable( unsigned mask ) - #endif - - return ~old_cw & BOOST_FPE_ALL; --#elif defined(__GLIBC__) && defined(__USE_GNU) && !defined(BOOST_CLANG) && !defined(BOOST_NO_FENV_H) -+#elif defined(__GLIBC__) && defined(__USE_GNU) -+ if (BOOST_FPE_ALL == 0) -+ /* Not Implemented */ -+ return 0; - feclearexcept(BOOST_FPE_ALL); - int res = feenableexcept( mask ); - return res == -1 ? (unsigned)BOOST_FPE_INV : (unsigned)res; -@@ -1418,7 +1421,10 @@ disable( unsigned mask ) - #endif - - return ~old_cw & BOOST_FPE_ALL; --#elif defined(__GLIBC__) && defined(__USE_GNU) && !defined(BOOST_CLANG) && !defined(BOOST_NO_FENV_H) -+#elif defined(__GLIBC__) && defined(__USE_GNU) -+ if (BOOST_FPE_ALL == 0) -+ /* Not Implemented */ -+ return BOOST_FPE_INV; - feclearexcept(BOOST_FPE_ALL); - int res = fedisableexcept( mask ); - return res == -1 ? (unsigned)BOOST_FPE_INV : (unsigned)res; --- -2.9.3 - diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch new file mode 100644 index 000000000..6bb25f885 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch @@ -0,0 +1,143 @@ +From 7c49525812567f1219706c4ed330b3bd2cc8e94a Mon Sep 17 00:00:00 2001 +From: Christopher Larson <chris_larson@mentor.com> +Date: Tue, 13 Dec 2016 10:29:32 -0700 +Subject: [PATCH 3/3] Don't set up arch/instruction-set flags, we do that + ourselves + +Upstream-Status: Inappropriate +Signed-off-by: Christopher Larson <chris_larson@mentor.com> +--- + tools/build/src/tools/gcc.jam | 121 ------------------------------------------ + 1 file changed, 121 deletions(-) + +diff --git a/tools/build/src/tools/gcc.jam b/tools/build/src/tools/gcc.jam +index 942f141..d062c20 100644 +--- a/tools/build/src/tools/gcc.jam ++++ b/tools/build/src/tools/gcc.jam +@@ -1068,124 +1068,3 @@ local rule cpu-flags ( toolset variable : architecture : instruction-set + : + <architecture>$(architecture)/<instruction-set>$(instruction-set) + : $(values) ; + } +- +- +-# Set architecture/instruction-set options. +-# +-# x86 and compatible +-# The 'native' option appeared in gcc 4.2 so we cannot safely use it as default. +-# Use i686 instead for 32-bit. +-toolset.flags gcc OPTIONS <architecture>x86/<address-model>32/<instruction-set> : -march=i686 ; +-cpu-flags gcc OPTIONS : x86 : native : -march=native ; +-cpu-flags gcc OPTIONS : x86 : i486 : -march=i486 ; +-cpu-flags gcc OPTIONS : x86 : i586 : -march=i586 ; +-cpu-flags gcc OPTIONS : x86 : i686 : -march=i686 ; +-cpu-flags gcc OPTIONS : x86 : pentium : -march=pentium ; +-cpu-flags gcc OPTIONS : x86 : pentium-mmx : -march=pentium-mmx ; +-cpu-flags gcc OPTIONS : x86 : pentiumpro : -march=pentiumpro ; +-cpu-flags gcc OPTIONS : x86 : pentium2 : -march=pentium2 ; +-cpu-flags gcc OPTIONS : x86 : pentium3 : -march=pentium3 ; +-cpu-flags gcc OPTIONS : x86 : pentium3m : -march=pentium3m ; +-cpu-flags gcc OPTIONS : x86 : pentium-m : -march=pentium-m ; +-cpu-flags gcc OPTIONS : x86 : pentium4 : -march=pentium4 ; +-cpu-flags gcc OPTIONS : x86 : pentium4m : -march=pentium4m ; +-cpu-flags gcc OPTIONS : x86 : prescott : -march=prescott ; +-cpu-flags gcc OPTIONS : x86 : nocona : -march=nocona ; +-cpu-flags gcc OPTIONS : x86 : core2 : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : conroe : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : conroe-xe : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : conroe-l : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : allendale : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : wolfdale : -march=core2 -msse4.1 ; +-cpu-flags gcc OPTIONS : x86 : merom : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : merom-xe : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : kentsfield : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : kentsfield-xe : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : yorksfield : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : penryn : -march=core2 ; +-cpu-flags gcc OPTIONS : x86 : corei7 : -march=corei7 ; +-cpu-flags gcc OPTIONS : x86 : nehalem : -march=corei7 ; +-cpu-flags gcc OPTIONS : x86 : corei7-avx : -march=corei7-avx ; +-cpu-flags gcc OPTIONS : x86 : sandy-bridge : -march=corei7-avx ; +-cpu-flags gcc OPTIONS : x86 : core-avx-i : -march=core-avx-i ; +-cpu-flags gcc OPTIONS : x86 : ivy-bridge : -march=core-avx-i ; +-cpu-flags gcc OPTIONS : x86 : haswell : -march=core-avx-i -mavx2 -mfma -mbmi -mbmi2 -mlzcnt ; +-cpu-flags gcc OPTIONS : x86 : k6 : -march=k6 ; +-cpu-flags gcc OPTIONS : x86 : k6-2 : -march=k6-2 ; +-cpu-flags gcc OPTIONS : x86 : k6-3 : -march=k6-3 ; +-cpu-flags gcc OPTIONS : x86 : athlon : -march=athlon ; +-cpu-flags gcc OPTIONS : x86 : athlon-tbird : -march=athlon-tbird ; +-cpu-flags gcc OPTIONS : x86 : athlon-4 : -march=athlon-4 ; +-cpu-flags gcc OPTIONS : x86 : athlon-xp : -march=athlon-xp ; +-cpu-flags gcc OPTIONS : x86 : athlon-mp : -march=athlon-mp ; +-## +-cpu-flags gcc OPTIONS : x86 : k8 : -march=k8 ; +-cpu-flags gcc OPTIONS : x86 : opteron : -march=opteron ; +-cpu-flags gcc OPTIONS : x86 : athlon64 : -march=athlon64 ; +-cpu-flags gcc OPTIONS : x86 : athlon-fx : -march=athlon-fx ; +-cpu-flags gcc OPTIONS : x86 : k8-sse3 : -march=k8-sse3 ; +-cpu-flags gcc OPTIONS : x86 : opteron-sse3 : -march=opteron-sse3 ; +-cpu-flags gcc OPTIONS : x86 : athlon64-sse3 : -march=athlon64-sse3 ; +-cpu-flags gcc OPTIONS : x86 : amdfam10 : -march=amdfam10 ; +-cpu-flags gcc OPTIONS : x86 : barcelona : -march=barcelona ; +-cpu-flags gcc OPTIONS : x86 : bdver1 : -march=bdver1 ; +-cpu-flags gcc OPTIONS : x86 : bdver2 : -march=bdver2 ; +-cpu-flags gcc OPTIONS : x86 : bdver3 : -march=bdver3 ; +-cpu-flags gcc OPTIONS : x86 : btver1 : -march=btver1 ; +-cpu-flags gcc OPTIONS : x86 : btver2 : -march=btver2 ; +-cpu-flags gcc OPTIONS : x86 : winchip-c6 : -march=winchip-c6 ; +-cpu-flags gcc OPTIONS : x86 : winchip2 : -march=winchip2 ; +-cpu-flags gcc OPTIONS : x86 : c3 : -march=c3 ; +-cpu-flags gcc OPTIONS : x86 : c3-2 : -march=c3-2 ; +-## +-cpu-flags gcc OPTIONS : x86 : atom : -march=atom ; +-# Sparc +-cpu-flags gcc OPTIONS : sparc : v7 : -mcpu=v7 : default ; +-cpu-flags gcc OPTIONS : sparc : cypress : -mcpu=cypress ; +-cpu-flags gcc OPTIONS : sparc : v8 : -mcpu=v8 ; +-cpu-flags gcc OPTIONS : sparc : supersparc : -mcpu=supersparc ; +-cpu-flags gcc OPTIONS : sparc : sparclite : -mcpu=sparclite ; +-cpu-flags gcc OPTIONS : sparc : hypersparc : -mcpu=hypersparc ; +-cpu-flags gcc OPTIONS : sparc : sparclite86x : -mcpu=sparclite86x ; +-cpu-flags gcc OPTIONS : sparc : f930 : -mcpu=f930 ; +-cpu-flags gcc OPTIONS : sparc : f934 : -mcpu=f934 ; +-cpu-flags gcc OPTIONS : sparc : sparclet : -mcpu=sparclet ; +-cpu-flags gcc OPTIONS : sparc : tsc701 : -mcpu=tsc701 ; +-cpu-flags gcc OPTIONS : sparc : v9 : -mcpu=v9 ; +-cpu-flags gcc OPTIONS : sparc : ultrasparc : -mcpu=ultrasparc ; +-cpu-flags gcc OPTIONS : sparc : ultrasparc3 : -mcpu=ultrasparc3 ; +-# RS/6000 & PowerPC +-cpu-flags gcc OPTIONS : power : 403 : -mcpu=403 ; +-cpu-flags gcc OPTIONS : power : 505 : -mcpu=505 ; +-cpu-flags gcc OPTIONS : power : 601 : -mcpu=601 ; +-cpu-flags gcc OPTIONS : power : 602 : -mcpu=602 ; +-cpu-flags gcc OPTIONS : power : 603 : -mcpu=603 ; +-cpu-flags gcc OPTIONS : power : 603e : -mcpu=603e ; +-cpu-flags gcc OPTIONS : power : 604 : -mcpu=604 ; +-cpu-flags gcc OPTIONS : power : 604e : -mcpu=604e ; +-cpu-flags gcc OPTIONS : power : 620 : -mcpu=620 ; +-cpu-flags gcc OPTIONS : power : 630 : -mcpu=630 ; +-cpu-flags gcc OPTIONS : power : 740 : -mcpu=740 ; +-cpu-flags gcc OPTIONS : power : 7400 : -mcpu=7400 ; +-cpu-flags gcc OPTIONS : power : 7450 : -mcpu=7450 ; +-cpu-flags gcc OPTIONS : power : 750 : -mcpu=750 ; +-cpu-flags gcc OPTIONS : power : 801 : -mcpu=801 ; +-cpu-flags gcc OPTIONS : power : 821 : -mcpu=821 ; +-cpu-flags gcc OPTIONS : power : 823 : -mcpu=823 ; +-cpu-flags gcc OPTIONS : power : 860 : -mcpu=860 ; +-cpu-flags gcc OPTIONS : power : 970 : -mcpu=970 ; +-cpu-flags gcc OPTIONS : power : 8540 : -mcpu=8540 ; +-cpu-flags gcc OPTIONS : power : power : -mcpu=power ; +-cpu-flags gcc OPTIONS : power : power2 : -mcpu=power2 ; +-cpu-flags gcc OPTIONS : power : power3 : -mcpu=power3 ; +-cpu-flags gcc OPTIONS : power : power4 : -mcpu=power4 ; +-cpu-flags gcc OPTIONS : power : power5 : -mcpu=power5 ; +-cpu-flags gcc OPTIONS : power : powerpc : -mcpu=powerpc ; +-cpu-flags gcc OPTIONS : power : powerpc64 : -mcpu=powerpc64 ; +-cpu-flags gcc OPTIONS : power : rios : -mcpu=rios ; +-cpu-flags gcc OPTIONS : power : rios1 : -mcpu=rios1 ; +-cpu-flags gcc OPTIONS : power : rios2 : -mcpu=rios2 ; +-cpu-flags gcc OPTIONS : power : rsc : -mcpu=rsc ; +-cpu-flags gcc OPTIONS : power : rs64a : -mcpu=rs64 ; +-# AIX variant of RS/6000 & PowerPC +-toolset.flags gcc AROPTIONS <address-model>64/<target-os>aix : "-X64" ; +-- +2.8.0 diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-smart_ptr-mips-assembly-doesn-t-compile-in-mips16e-m.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-smart_ptr-mips-assembly-doesn-t-compile-in-mips16e-m.patch deleted file mode 100644 index 2b48d0d5d..000000000 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost/0003-smart_ptr-mips-assembly-doesn-t-compile-in-mips16e-m.patch +++ /dev/null @@ -1,60 +0,0 @@ -From 4f19d72ca94418431e068cfd4ffb96ed9b289f6c Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <adraszik@tycoint.com> -Date: Wed, 24 Aug 2016 17:34:59 +0100 -Subject: [PATCH 3/4] smart_ptr: mips assembly doesn't compile in mips16e mode -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -gcc.compile.c++ <builddir>/boost/bin.v2/libs/date_time/build/gcc-4.3.1/release/threading-multi/gregorian/greg_month.o - - "mipsel-poky-linux-musl-g++" "-mel" "-mabi=32" "-msoft-float" "-march=mips32r2" "-mips16" "-minterlink-compressed" "-mtune=24kec" "-mdsp" "-Wl,-O1" "-Wl,--as-needed" "-fstack-protector-strong" "-Wl,-z,relro,-z,now" "--sysroot=<sysroot>" -ftemplate-depth-128 -O2 -pipe -g -feliminate-unused-debug-types -fdebug-prefix-map=<srcdir>=/usr/src/debug/boost/1.61.0-r0 -fdebug-prefix-map=<sysroot_host>= -fdebug-prefix-map=<sysroot>= -fstack-protector-strong -pie -fpie -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security -fvisibility-inlines-hidden -O3 -finline-functions -Wno-inline -Wall -pthread -fPIC -DBOOST_ALL_DYN_LINK=1 -DBOOST_ALL_NO_LIB=1 -DDATE_TIME_INLINE -DNDEBUG -I"." -c -o "<builddir>/boost/bin.v2/libs/date_time/build/gcc-4.3.1/release/threading-multi/gregorian/greg_month.o" "libs/date_time/src/gregorian/greg_month.cpp" - -{standard input}: Assembler messages: -{standard input}:17603: Warning: the `dsp' extension requires MIPS32 revision 2 or greater -{standard input}:17604: Error: unrecognized opcode `ll $3,4($16)' -{standard input}:17606: Error: unrecognized opcode `sc $2,4($16)' -{standard input}:17734: Error: unrecognized opcode `ll $3,8($16)' -{standard input}:17736: Error: unrecognized opcode `sc $2,8($16)' -{standard input}:18084: Error: unrecognized opcode `ll $3,4($4)' -{standard input}:18086: Error: unrecognized opcode `sc $2,4($4)' -{standard input}:18318: Error: unrecognized opcode `ll $3,8($4)' -{standard input}:18320: Error: unrecognized opcode `sc $2,8($4)' -{standard input}:19921: Error: unrecognized opcode `ll $3,4($2)' -{standard input}:19923: Error: unrecognized opcode `sc $3,4($2)' -{standard input}:20199: Error: unrecognized opcode `ll $4,4($16)' -{standard input}:20201: Error: unrecognized opcode `sc $2,4($16)' -{standard input}:23392: Error: unrecognized opcode `ll $4,8($16)' -{standard input}:23394: Error: unrecognized opcode `sc $2,8($16)' -...failed updating 1 target... - -boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp -contains hand-written MIPS assembly, which is not compatible -with the MIPS16e instruction set. - -By not using this file in MIPS16e mode, we fallback to using -g++ 4.1+ __sync intrinsics (__sync_fetch_and_add() and -__sync_val_compare_and_swap()) which are working fine. - -Signed-off-by: André Draszik <adraszik@tycoint.com> ---- -Upstream-Status: Backport https://svn.boost.org/trac/boost/ticket/12418 - boost/smart_ptr/detail/sp_counted_base.hpp | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/boost/smart_ptr/detail/sp_counted_base.hpp b/boost/smart_ptr/detail/sp_counted_base.hpp -index 0addf07..0995ca8 100644 ---- a/boost/smart_ptr/detail/sp_counted_base.hpp -+++ b/boost/smart_ptr/detail/sp_counted_base.hpp -@@ -65,7 +65,7 @@ - #elif defined( __GNUC__ ) && ( defined( __powerpc__ ) || defined( __ppc__ ) || defined( __ppc ) ) && !defined(__PATHSCALE__) && !defined( _AIX ) - # include <boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp> - --#elif defined( __GNUC__ ) && ( defined( __mips__ ) || defined( _mips ) ) && !defined(__PATHSCALE__) -+#elif defined( __GNUC__ ) && ( defined( __mips__ ) || defined( _mips ) ) && !defined(__PATHSCALE__) && !defined( __mips16 ) - # include <boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp> - - #elif defined( BOOST_SP_HAS_SYNC ) --- -2.9.3 - diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/consider-hardfp.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/consider-hardfp.patch deleted file mode 100644 index 66808a69d..000000000 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost/consider-hardfp.patch +++ /dev/null @@ -1,19 +0,0 @@ -When using soft-float, on ARM we should not expect the FE_* symbols - -Signed-off-by: Khem Raj <raj.khem@gmail.com> -Upstream-Status: Pending - -Index: boost_1_60_0/boost/test/execution_monitor.hpp -=================================================================== ---- boost_1_60_0.orig/boost/test/execution_monitor.hpp -+++ boost_1_60_0/boost/test/execution_monitor.hpp -@@ -484,7 +484,8 @@ enum masks { - BOOST_FPE_UNDERFLOW = EM_UNDERFLOW|EM_DENORMAL, - - BOOST_FPE_ALL = MCW_EM, --#elif defined(BOOST_NO_FENV_H) || defined(BOOST_CLANG) -+#elif defined(BOOST_NO_FENV_H) || defined(BOOST_CLANG) \ -+ || defined(__ARM_PCS) - BOOST_FPE_ALL = 1, - #else - BOOST_FPE_DIVBYZERO = FE_DIVBYZERO, diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost/py3.patch b/import-layers/yocto-poky/meta/recipes-support/boost/boost/py3.patch new file mode 100644 index 000000000..2b1ff1865 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost/py3.patch @@ -0,0 +1,269 @@ +Backport fixes from upstream (as of boost super-module commit 0d52b9) to improve +the building of the Boost Python module with Python 3. + +Upstream-Status: Backport +Signed-off-by: Ross Burton <ross.burton@intel.com> + +diff --git a/build/Jamfile b/build/Jamfile +index 313fdab..f14dc11 100644 +--- a/libs/python/build/Jamfile ++++ b/libs/python/build/Jamfile +@@ -6,6 +6,7 @@ import os ; + import indirect ; + import modules ; + import feature ; ++import property ; + + import python ; + +@@ -30,21 +31,8 @@ else + ; + } + +-rule find-py3-version +-{ +- local versions = [ feature.values python ] ; +- local py3ver ; +- for local v in $(versions) +- { +- if $(v) >= 3.0 +- { +- py3ver = $(v) ; +- } +- } +- return $(py3ver) ; +-} +- +-py3-version = [ find-py3-version ] ; ++py2-version = [ py-version 2 ] ; ++py3-version = [ py-version 3 ] ; + + project boost/python + : source-location ../src +@@ -52,11 +40,17 @@ project boost/python + + rule cond ( test ? : yes * : no * ) { if $(test) { return $(yes) ; } else { return $(no) ; } } + rule unless ( test ? : yes * : no * ) { if ! $(test) { return $(yes) ; } else { return $(no) ; } } ++local rule eq ( a : b ) { if $(a) = $(b) { return 1 ; } } + +-rule lib_boost_python ( is-py3 ? ) +-{ ++lib_boost_python(2) = boost_python ; ++lib_boost_python(3) = boost_python3 ; + +- lib [ cond $(is-py3) : boost_python3 : boost_python ] ++lib_boost_python($(py2-version)) = $(lib_boost_python(2)) ; ++lib_boost_python($(py3-version)) = $(lib_boost_python(3)) ; ++ ++rule lib_boost_python ( version ) ++{ ++ lib $(lib_boost_python($(version))) + : # sources + numeric.cpp + list.cpp +@@ -112,11 +106,13 @@ rule lib_boost_python ( is-py3 ? ) + <dependency>config-warning + + <python-debugging>on:<define>BOOST_DEBUG_PYTHON +- [ cond $(is-py3) : <python>$(py3-version) ] ++ <python>$(version) + + -<tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag + <tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).python-tag + ++ <conditional>@python.require-py ++ + : # default build + <link>shared + : # usage requirements +@@ -125,51 +121,68 @@ rule lib_boost_python ( is-py3 ? ) + ; + } + +-rule lib_boost_numpy ( is-py3 ? ) ++lib_boost_numpy(2) = boost_numpy ; ++lib_boost_numpy(3) = boost_numpy3 ; ++ ++lib_boost_numpy($(py2-version)) = $(lib_boost_python(2)) ; ++lib_boost_numpy($(py3-version)) = $(lib_boost_python(3)) ; ++ ++rule lib_boost_numpy ( version ) + { + numpy-include = [ python.numpy-include ] ; +- lib [ cond $(is-py3) : boost_numpy3 : boost_numpy ] ++ lib $(lib_boost_numpy($(version))) + : # sources + numpy/dtype.cpp + numpy/matrix.cpp + numpy/ndarray.cpp +- numpy/numpy.cpp +- numpy/scalars.cpp +- numpy/ufunc.cpp ++ numpy/numpy.cpp ++ numpy/scalars.cpp ++ numpy/ufunc.cpp + : # requirements ++ <link>static:<define>BOOST_NUMPY_STATIC_LIB ++ <define>BOOST_NUMPY_SOURCE + [ cond [ python.numpy ] : <library>/python//python_for_extensions ] + [ unless [ python.numpy ] : <build>no ] +- <include>$(numpy-include) +- <library>boost_python ++ <include>$(numpy-include) ++ <library>$(lib_boost_python($(version))) + <python-debugging>on:<define>BOOST_DEBUG_PYTHON +- [ cond $(is-py3) : <python>$(py3-version) ] ++ <python>$(version) + + -<tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag + <tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).python-tag + ++ <conditional>@python.require-py ++ + : # default build + <link>shared + : # usage requirements ++ <link>static:<define>BOOST_NUMPY_STATIC_LIB + <python-debugging>on:<define>BOOST_DEBUG_PYTHON + ; + } + +-libraries = boost_python ; +-libraries3 = boost_python3 ; +-if [ python.numpy ] +-{ +- libraries += boost_numpy ; +- libraries3 += boost_numpy3 ; +-} +- +-lib_boost_python ; +-lib_boost_numpy ; ++libraries = ; + +-if $(py3-version) ++for local N in 2 3 + { +- lib_boost_python yes ; +- lib_boost_numpy yes ; +- libraries += $(libraries3) ; ++ if $(py$(N)-version) ++ { ++ lib_boost_python $(py$(N)-version) ; ++ libraries += $(lib_boost_python($(py$(N)-version))) ; ++ } ++ else ++ { ++ alias $(lib_boost_python($(N))) ; ++ } ++ if $(py$(N)-version) && [ python.numpy ] ++ { ++ lib_boost_numpy $(py$(N)-version) ; ++ libraries += $(lib_boost_numpy($(py$(N)-version))) ; ++ } ++ else ++ { ++ alias $(lib_boost_numpy($(N))) ; ++ } + } + + boost-install $(libraries) ; +diff --git a/src/tools/python.jam b/src/tools/python.jam +index cc13385..bf300b8 100644 +--- a/tools/build/src/tools/python.jam ++++ b/tools/build/src/tools/python.jam +@@ -34,6 +34,7 @@ import path ; + import feature ; + import set ; + import builtin ; ++import property-set ; + + + # Make this module a project. +@@ -60,6 +61,10 @@ lib rt ; + # installed in the development system's default paths. + feature.feature pythonpath : : free optional path ; + ++# The best configured version of Python 2 and 3. ++py2-version = ; ++py3-version = ; ++ + # Initializes the Python toolset. Note that all parameters are optional. + # + # - version -- the version of Python to use. Should be in Major.Minor format, +@@ -861,6 +866,11 @@ local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? : + if ! $(version) in [ feature.values python ] + { + feature.extend python : $(version) ; ++ py$(major-minor[1])-version ?= $(version) ; ++ if $(py$(major-minor[1])-version) < $(version) ++ { ++ py$(major-minor[1])-version = $(version) ; ++ } + } + target-requirements += <python>$(version:E=default) ; + } +@@ -916,6 +926,9 @@ local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? : + } + } + ++ # In case we added duplicate requirements from what the user specified. ++ target-requirements = [ sequence.unique $(target-requirements) ] ; ++ + # Global, but conditional, requirements to give access to the interpreter + # for general utilities, like other toolsets, that run Python scripts. + toolset.add-requirements +@@ -934,19 +947,6 @@ local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? : + toolset.add-requirements <target-os>$(target-os):<python>$(version:E=default) ; + } + +- # We also set a default requirement that assigns the first python configured +- # for a particular target OS as the default. This makes it so that we can +- # select a python interpreter with only knowledge of the target OS. And hence +- # can configure different Pythons based on the target OS only. +- local toolset-requirements = [ toolset.requirements ] ; +- local toolset-target-os-requirements +- = [ property.evaluate-conditionals-in-context +- [ $(toolset-requirements).raw ] : <target-os>$(target-os) ] ; +- if ! <python> in $(toolset-target-os-requirements:G) +- { +- toolset.add-requirements <target-os>$(target-os):<python>$(version:E=default) ; +- } +- + # Register the right suffix for extensions. + register-extension-suffix $(extension-suffix) : $(target-requirements) ; + +@@ -1038,6 +1038,22 @@ local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? : + : $(usage-requirements) + ; + } ++ ++} ++ ++# Conditional rule specification that will prevent building of a target ++# if there is no matching python configuration available with the given ++# required properties. ++rule require-py ( properties * ) ++{ ++ local py-ext-target = [ $(.project).find python_for_extensions ] ; ++ local property-set = [ property-set.create $(properties) ] ; ++ property-set = [ $(property-set).expand ] ; ++ local py-ext-alternative = [ $(py-ext-target).select-alternatives $(property-set) ] ; ++ if ! $(py-ext-alternative) ++ { ++ return <build>no ; ++ } + } + + +@@ -1298,5 +1314,11 @@ rule numpy-test ( name : sources * : requirements * ) + : $(name) ] ; + } + ++rule py-version ( n ) ++{ ++ return $(py$(n)-version) ; ++} ++ + IMPORT $(__name__) : bpl-test : : bpl-test ; + IMPORT $(__name__) : numpy-test : : numpy-test ; ++IMPORT $(__name__) : py-version : : py-version ; diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.61.0.bb b/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.61.0.bb deleted file mode 100644 index 40e3870a3..000000000 --- a/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.61.0.bb +++ /dev/null @@ -1,13 +0,0 @@ -include boost-${PV}.inc -include boost.inc - -SRC_URI += "\ - file://arm-intrinsics.patch \ - file://consider-hardfp.patch \ - file://boost-CVE-2012-2677.patch \ - file://0001-boost-asio-detail-socket_types.hpp-fix-poll.h-includ.patch \ - file://0002-boost-test-execution_monitor.hpp-fix-mips-soft-float.patch \ - file://0003-smart_ptr-mips-assembly-doesn-t-compile-in-mips16e-m.patch \ - file://0004-Use-atomic-by-default-when-BOOST_NO_CXX11_HDR_ATOMIC.patch \ - file://boost-math-disable-pch-for-gcc.patch \ -" diff --git a/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.63.0.bb b/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.63.0.bb new file mode 100644 index 000000000..1107686bc --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-support/boost/boost_1.63.0.bb @@ -0,0 +1,15 @@ +require boost-${PV}.inc +require boost.inc + +SRC_URI += "\ + file://arm-intrinsics.patch \ + file://0001-When-using-soft-float-on-ARM-we-should-not-expect-th.patch \ + file://boost-CVE-2012-2677.patch \ + file://0001-boost-asio-detail-socket_types.hpp-fix-poll.h-includ.patch \ + file://0004-Use-atomic-by-default-when-BOOST_NO_CXX11_HDR_ATOMIC.patch \ + file://boost-math-disable-pch-for-gcc.patch \ + file://0001-Apply-boost-1.62.0-no-forced-flags.patch.patch \ + file://0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch \ + file://0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch \ + file://py3.patch \ +" |