|
Boost-Build : |
Subject: Re: [Boost-build] #7706 : cross compiling of threads library - JamFile.v2
From: Jürgen Hunold (jhunold_at_[hidden])
Date: 2012-12-10 09:54:31
Hi Vicente,
On Sunday, 9. December 2012 16:59:28 Vicente J. Botet Escriba wrote:
> Le 09/12/12 16:00, Steven Watanabe a écrit :
> > What is properties? Where is it defined?
> > If it's undefined, then it's treated as
> > an empty list, so the test is, of course, false.
>
> You are right. the variable properties is not seen in this function. Do
> you know how cross compile?
It seems that you can't get properties outside of the project rule. I've done
some (quick) experimenting. Running
b2 -j4 gcc-msvc target-os=windows
on this hack at least creates "bin.v2/libs/thread/build/gcc-mingw-
msvc/debug/target-os-windows/threadapi-win32/libboost_thread_win32.dll.a"
which looks right.
The patch contains a lot of debug echos and needs some cleanup.
the basic idea is to use the "conditional" property to select the right api
via a modified "check_default_threadapi" copied from "default api"
<conditional>@check_default_threadapi
This will at least start compilation. Setting the default api and thus
eliminating the "win32" and "pthread" suffix is unresolved. Maybe Steven can
help with this rather advanced problem.
I hope this helps.
Yours,
Jürgen
-- * Dipl.-Math. Jürgen Hunold ! * voice: ++49 4257 300 ! Fährstraße 1 * fax : ++49 4257 300 ! 31609 Balge/Sebbenhausen * jhunold_at_gmx.eu ! Germany
-*- mode: compilation; default-directory: "/home/hunold/src/devel/boost/libs/thread/build/" -*-
Compilation started at Mon Dec 10 15:44:40
b2 -j4 -l180 gcc-msvc target-os=windows
set props
check props <abi>sysv <asynch-exceptions>off <binary-format>elf <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.check_default_threadapi <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.requirements <conditional>@Jamfile</home/hunold/src/devel/boost>%Jamfile</home/hunold/src/devel/boost>.handle-static-runtime <debug-symbols>on <doxygen.doxproc.index>no <doxygen.processor>xsltproc <exception-handling>on <extern-c-nothrow>off <format>html <hardcode-dll-paths>true <host-os>linux <inlining>off <install-dependencies>off <library>/boost/system//boost_system <link>shared <optimization>off <os>LINUX <pch>off <preserve-test-targets>on <profiling>off <python-debugging>off <python>2.7 <qt3support>off <qt5>5.0 <qt>4.8 <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <suppress-import-lib>false <symlink-location>project-relative <target-os>windows <threadapi>pthread <threading>multi <toolset-gcc:flavor>mingw <toolset-gcc:version>msvc <toolset>gcc <user-interface>console <variant>debug <warnings-as-errors>off <warnings>all
************************************************************
Trying to build Boost.Thread with pthread support.
If you need pthread you should specify the paths.
You can specify them in site-config.jam, user-config.jam
or in the environment.
For example:
PTW32_INCLUDE=C:\Program Files\ptw32\Pre-built2\include
PTW32_LIB=C:\Program Files\ptw32\Pre-built2\lib
************************************************************
check props <abi>sysv <asynch-exceptions>off <binary-format>elf <build>no <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.check_default_threadapi <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.requirements <conditional>@Jamfile</home/hunold/src/devel/boost>%Jamfile</home/hunold/src/devel/boost>.handle-static-runtime <cxxflags>-Wextra <cxxflags>-Wno-long-long <cxxflags>-fPIC <cxxflags>-fdiagnostics-show-option <cxxflags>-pedantic <debug-symbols>on <define>BOOST_THREAD_BUILD_DLL=1 <define>BOOST_THREAD_DONT_USE_CHRONO <doxygen.doxproc.index>no <doxygen.processor>xsltproc <exception-handling>on <extern-c-nothrow>off <format>html <hardcode-dll-paths>true <host-os>linux <inlining>off <install-dependencies>off <library>/boost/system//boost_system <link>shared <optimization>off <os>LINUX <pch>off <preserve-test-targets>on <profiling>off <python-debugging>off <python>2.7 <qt3support>off <qt5>5.0 <qt>4.8 <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <suppress-import-lib>false <symlink-location>project-relative <target-os>windows <threadapi>win32 <threading>multi <toolset-gcc:flavor>mingw <toolset-gcc:version>msvc <toolset>gcc <user-interface>console <variant>debug <warnings-as-errors>off <warnings>all
check props <abi>sysv <asynch-exceptions>off <binary-format>elf <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.check_default_threadapi <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.requirements <conditional>@Jamfile</home/hunold/src/devel/boost>%Jamfile</home/hunold/src/devel/boost>.handle-static-runtime <cxxflags>-Wextra <cxxflags>-Wno-long-long <cxxflags>-fPIC <cxxflags>-fdiagnostics-show-option <cxxflags>-pedantic <debug-symbols>on <define>BOOST_THREAD_BUILD_DLL=1 <define>BOOST_THREAD_DONT_USE_CHRONO <doxygen.doxproc.index>no <doxygen.processor>xsltproc <exception-handling>on <extern-c-nothrow>off <format>html <hardcode-dll-paths>true <host-os>linux <inlining>off <install-dependencies>off <library>/boost/system//boost_system <link>shared <optimization>off <os>LINUX <pch>off <preserve-test-targets>on <profiling>off <python-debugging>off <python>2.7 <qt3support>off <qt5>5.0 <qt>4.8 <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <suppress-import-lib>false <symlink-location>project-relative <target-os>windows <threadapi>win32 <threading>multi <toolset-gcc:flavor>mingw <toolset-gcc:version>msvc <toolset>gcc <user-interface>console <variant>debug <warnings-as-errors>off <warnings>all
check props <abi>sysv <asynch-exceptions>off <binary-format>elf <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.check_default_threadapi <conditional>@Jamfile</home/hunold/src/devel/boost>%Jamfile</home/hunold/src/devel/boost>.handle-static-runtime <debug-symbols>on <doxygen.doxproc.index>no <doxygen.processor>xsltproc <exception-handling>on <extern-c-nothrow>off <format>html <hardcode-dll-paths>true <host-os>linux <inlining>off <install-dependencies>off <library>/boost/system//boost_system <link>shared <optimization>off <os>LINUX <pch>off <preserve-test-targets>on <profiling>off <python-debugging>off <python>2.7 <qt3support>off <qt5>5.0 <qt>4.8 <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <suppress-import-lib>false <symlink-location>project-relative <target-os>windows <threadapi>win32 <threading>multi <toolset-gcc:flavor>mingw <toolset-gcc:version>msvc <toolset>gcc <user-interface>console <variant>debug <warnings-as-errors>off <warnings>all
check props <abi>sysv <asynch-exceptions>off <binary-format>elf <conditional>@Jamfile</home/hunold/src/devel/boost/libs/thread/build>%Jamfile</home/hunold/src/devel/boost/libs/thread/build>.check_default_threadapi <conditional>@Jamfile</home/hunold/src/devel/boost>%Jamfile</home/hunold/src/devel/boost>.handle-static-runtime <cxxflags>-Wextra <cxxflags>-Wno-long-long <cxxflags>-fPIC <cxxflags>-fdiagnostics-show-option <cxxflags>-pedantic <debug-symbols>on <define>BOOST_THREAD_BUILD_DLL=1 <doxygen.doxproc.index>no <doxygen.processor>xsltproc <exception-handling>on <extern-c-nothrow>off <format>html <hardcode-dll-paths>true <host-os>linux <inlining>off <install-dependencies>off <library>/boost/system//boost_system <link>shared <optimization>off <os>LINUX <pch>off <preserve-test-targets>on <profiling>off <python-debugging>off <python>2.7 <qt3support>off <qt5>5.0 <qt>4.8 <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <suppress-import-lib>false <symlink-location>project-relative <target-os>windows <threadapi>win32 <threading>multi <toolset-gcc:flavor>mingw <toolset-gcc:version>msvc <toolset>gcc <user-interface>console <variant>debug <warnings-as-errors>off <warnings>all
set props
set props
...patience...
...found 1012 targets...
...updating 18 targets...
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug/target-os-windows
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32
common.mkdir /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/win32
gcc.compile.c++ /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/win32/tss_dll.o
/home/hunold/src/devel/boost/libs/thread/src/win32/tss_dll.cpp:1: warning: -fPIC ignored for target (all code is position independent)
gcc.compile.c++ /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/win32/tss_pe.o
/home/hunold/src/devel/boost/libs/thread/src/win32/tss_pe.cpp:1: warning: -fPIC ignored for target (all code is position independent)
gcc.compile.c++ /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/error_code.o
/home/hunold/src/devel/boost/libs/system/src/error_code.cpp:1: warning: -fPIC ignored for target (all code is position independent)
gcc.link.dll /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/libboost_system.dll.a
Creating library file: /home/hunold/src/devel/boost/bin.v2/libs/system/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/libboost_system.dll.a
gcc.compile.c++ /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/future.o
/home/hunold/src/devel/boost/libs/thread/src/future.cpp:1: warning: -fPIC ignored for target (all code is position independent)
gcc.compile.c++ /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/win32/thread.o
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:1: warning: -fPIC ignored for target (all code is position independent)
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp: In static member function âstatic unsigned int boost::thread::hardware_concurrency()â:
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::dwPageSizeâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::lpMinimumApplicationAddressâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::lpMaximumApplicationAddressâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::dwActiveProcessorMaskâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::dwNumberOfProcessorsâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::dwProcessorTypeâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::dwAllocationGranularityâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::wProcessorLevelâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:405: warning: missing initializer for member â_SYSTEM_INFO::wProcessorRevisionâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp: In function âLARGE_INTEGER boost::this_thread::<unnamed>::get_due_time(const boost::detail::timeout&)â:
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:428: warning: missing initializer for member â_LARGE_INTEGER::<anonymous struct>::HighPartâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wMonthâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wDayOfWeekâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wDayâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wHourâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wMinuteâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wSecondâ [-Wmissing-field-initializers]
/home/hunold/src/devel/boost/libs/thread/src/win32/thread.cpp:442: warning: missing initializer for member â_SYSTEMTIME::wMillisecondsâ [-Wmissing-field-initializers]
gcc.link.dll /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/libboost_thread_win32.dll.a
Creating library file: /home/hunold/src/devel/boost/bin.v2/libs/thread/build/gcc-mingw-msvc/debug/target-os-windows/threadapi-win32/libboost_thread_win32.dll.a
...updated 18 targets...
Compilation finished at Mon Dec 10 15:44:43
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk