Avoid fails during build of Boost 1.63.0 - Threads - multithreading

Hey hope some skilled guys of you can help..
(I've googled a lot, read many articles and questions from other people having similar problems but can't find a good answer/solution for my issue)
Tried to build boosts thread via VS2013 x64 Native Tools Command:
b2.exe --with-thread --build-type=complete toolset=msvc-12.0 architecture=x86 address-model=64 stage
Win7 64 bit
VS2013 with Update 5 installed
Boost 1.63.0 files on C:\boost_1_63_0
Question: How can I avoid that fails? (From ..\bin.v2\config.log)
...found 10 targets...
...updating 5 targets...
common.mkdir libs\config\checks\architecture\bin
common.mkdir libs\config\checks\architecture\bin\msvc-12.0
common.mkdir libs\config\checks\architecture\bin\msvc-12.0\debug
common.mkdir libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\32.obj
32.cpp
...updated 5 targets...
...found 2 targets...
...updating 1 target...
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\arm.obj
arm.cpp
libs\config\checks\architecture\arm.cpp(13) : fatal error C1189: #error : "Not ARM"
call "C:\Users\..\AppData\Local\Temp\b2_msvc_12.0_vcvarsall_x86.cmd" >nul
cl /Zm800 -nologo #"libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\arm.obj.rsp"
...failed compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\arm.obj...
...failed updating 1 target...
...found 2 targets...
...updating 1 target...
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\mips1.obj
mips1.cpp
libs\config\checks\architecture\mips1.cpp(10) : fatal error C1189: #error : "Not MIPS1"
call "C:\Users\..\AppData\Local\Temp\b2_msvc_12.0_vcvarsall_x86.cmd" >nul
cl /Zm800 -nologo #"libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\mips1.obj.rsp"
...failed compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\mips1.obj...
...failed updating 1 target...
...found 2 targets...
...updating 1 target...
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\power.obj
power.cpp
libs\config\checks\architecture\power.cpp(13) : fatal error C1189: #error : "Not PPC"
call "C:\Users\..\AppData\Local\Temp\b2_msvc_12.0_vcvarsall_x86.cmd" >nul
cl /Zm800 -nologo #"libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\power.obj.rsp"
...failed compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\power.obj...
...failed updating 1 target...
...found 2 targets...
...updating 1 target...
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\sparc.obj
sparc.cpp
libs\config\checks\architecture\sparc.cpp(10) : fatal error C1189: #error : "Not SPARC"
call "C:\Users\..\AppData\Local\Temp\b2_msvc_12.0_vcvarsall_x86.cmd" >nul
cl /Zm800 -nologo #"libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\sparc.obj.rsp"
...failed compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\sparc.obj...
...failed updating 1 target...
...found 2 targets...
...updating 1 target...
compile-c-c++ libs\config\checks\architecture\bin\msvc-12.0\debug\threading-multi\x86.obj
x86.cpp
...updated 1 target...
...found 3 targets...
...updating 3 targets...
common.mkdir bin.v2
link.touch bin.v2\test-symlink-source
link.mklink bin.v2\test-symlink
You do not have sufficient privilege to perform this operation.
if exist "bin.v2\test-symlink" del "bin.v2\test-symlink"
mklink "bin.v2\test-symlink" "test-symlink-source"
...failed link.mklink bin.v2\test-symlink...
...failed updating 1 target...
...updated 2 targets...
...found 2 targets...
...updating 2 targets...
common.mkdir bin.v2\test-junction-source
link.junction bin.v2\test-junction
Junction created for bin.v2\test-junction <<===>> bin.v2\test-junction-source
...updated 2 targets...
...found 3 targets...
...updating 3 targets...
common.mkdir bin.v2\symlink
link.touch bin.v2\test-hardlink-source
link.hardlink bin.v2\symlink\test-hardlink
Hardlink created for bin.v2\symlink\test-hardlink <<===>> bin.v2\test-hardlink-source
...updated 3 targets...
...found 1 target...
...updating 1 target...
config-cache.write bin.v2\project-cache.jam
...updated 1 target...
I figured out that the fails correlate with the output from b2 after runing the mentioned build command above, among others saying:
arm : no
mips1 : no
...
symlinks supported : no
C:\boost_1_63_0>b2.exe --with-thread --build-type=complete toolset=msvc-12.0 architecture=x86 address-model=64 stage
Performing configuration checks
- 32-bit : yes
- arm : no
- mips1 : no
- power : no
- sparc : no
- x86 : yes
- symlinks supported : no
- junctions supported : yes
- hardlinks supported : yes
What does that mean?
Why does b2 produce that output and why do these components cause that fails in the log?
Any help would be appreciated.
PS: I know that the binaris can be found precompiled but I would like to understand the issue.

I know this question is old, but it could help someone.
The build system (boost build, a variant of jam) performs some configuration checks to determine the architecture of the system, the platform, the OS, the tool-set to use, the capabilities of some utilities, etc. That some of those tests fail, doesn't mean that the libraries requested will fail to compile, in some cases some features might not be present, for example is the ICU library is not found the ICU back-end will not be usable in boost locale. In particular some of the tests you mention:
arm : no
===> An ARM processor was not detected.
mips1 : no
===> A MIPS processor was not detected.
symlinks supported : no
===> Those are supported in Windows starting with Windows Vista, but admin privileges are required.
If you want to view the results of the tests that are performed, you can pass the options "--debug-configuration" and "-dn" (where n is the level of debug), according to "b2 --help":
General command line usage:
b2 [options] [properties] [targets]
Options, properties and targets can be specified in any order.
Important Options:
* --clean Remove targets instead of building
* -a Rebuild everything
* -n Don't execute the commands, only print them
* -d+2 Show commands as they are executed
* -d0 Suppress all informational messages
* -q Stop at first error
* --reconfigure Rerun all configuration checks
* --debug-configuration Diagnose configuration
* --debug-building Report which targets are built with what properties
* --debug-generator Diagnose generator search/execution
Further Help:
The following options can be used to obtain additional documentation.
* --help-options Print more obscure command line options.
* --help-internal Boost.Build implementation details.
* --help-doc-options Implementation details doc formatting.
You can inspect the "bin.v2\config.log" to see the tests performed and their results. For a deeper inspection you'll need to learn the syntax of jam files in the boost build system.
The official help to build from sources (boost 1_65_1) can be found here: Build Binaries From Source.
The official help of the boost build system can be found here: Boost.Build.

Related

Ros2 Colcon build failed ,rclpy -error: 'PyErr_warnformat' was not decleared in the scope

Trying to install Ros2 humble in ubuntu 20.04,
while executing command --> Colcon build --symlink-install
I'm getting the following error
--- stderr: rclpy
In file included from /home/kalyan/ros2_humble/src/ros2/rclpy/rclpy/src/rclpy/node.hpp:24,
from /home/kalyan/ros2_humble/src/ros2/rclpy/rclpy/src/rclpy/action_client.hpp:26,
from /home/kalyan/ros2_humble/src/ros2/rclpy/rclpy/src/rclpy/_rclpy_pybind11.cpp:24:
/home/kalyan/ros2_humble/src/ros2/rclpy/rclpy/src/rclpy/context.hpp: In destructor ‘rclpy::InitOptions::~InitOptions()’:
/home/kalyan/ros2_humble/src/ros2/rclpy/rclpy/src/rclpy/context.hpp:49:7: error: ‘PyErr_WarnFormat’ was not declared in this scope; did you mean ‘PyErr_Format’?
49 | PyErr_WarnFormat(
| ^~~~~~
| PyErr_Format
make[2]: * [CMakeFiles/_rclpy_pybind11.dir/build.make:76: CMakeFiles/_rclpy_pybind11.dir/src/rclpy/_rclpy_pybind11.cpp.o] Error 1
make[1]: * [CMakeFiles/Makefile2:104: CMakeFiles/_rclpy_pybind11.dir/all] Error 2
make: * [Makefile:141: all] Error 2
---
Failed <<< rclpy [16.2s, exited with code 2]
Aborted <<< rclcpp [26.0s]
Aborted <<< ros2cli_test_interfaces [1min 29s]
Aborted <<< diagnostic_msgs [1min 32s]
Summary: 195 packages finished [4min 31s]
1 package failed: rclpy
3 packages aborted: diagnostic_msgs rclcpp ros2cli_test_interfaces
1 package had stderr output: rclpy
141 packages not processed
Help me to overcome this error.
pyhton3 version-->3.8.10
I have the python3.9 version too,
if python version < 3.2, it dose not have PyErr_WarnFormat().seehttps://docs.python.org/3/c-api/exceptions.html.
I delete /usr/include/python2.7/ and make the default python version is 3.8.10. It work for me.

Cannot build YugabyteDB with clang12 in Alma Linux 8.5

[Question posted by a user on YugabyteDB Community Slack]
Debug build does not seem to be working in the clang12 based build:
./yb_build.sh debug --sj
[100%] Linking CXX executable ../../../tests-integration-tests/cdc_service-int-test
[100%] Built target cdc_service-int-test
make: *** [Makefile:101: all] Error 2
real 0m28.279s
user 4m4.235s
sys 0m25.477s
[2022-02-26T15:52:32 yb_build.sh:466 run_cxx_build] C++ build finished with exit code 2 (build type: debug, compiler: clang12). Timing information is available above.
==========================================================================================
YUGABYTE BUILD SUMMARY
==========================================================================================
Build type : debug
C/C++ compiler : clang12
Build architecture : x86_64
Build directory : /yb-source/build/debug-clang12-dynamic
Third-party dir : /opt/yb-build/thirdparty/yugabyte-db-thirdparty-v20211222064150-dd4872fe56-almalinux8-x86_64-clang12
C++ compilation time : 28 seconds
Exit code : 2
------------------------------------------------------------------------------------------
doing
./yb_build.sh debug --clang12 --sj
also results in an error
...
[m-1] In YugabyteDB, setting LC_COLLATE to C and all other locale settings to en_US.UTF-8 by default. Locale support will be enhanced as part of addressing https://github.com/yugabyte/yugabyte-db/issues/1557
[m-1] initdb: invalid locale name "en_US.UTF-8"
[m-1] I0226 15:54:20.630203 15811 pg_wrapper.cc:521] initdb took 124 ms
[m-1] E0226 15:54:20.630272 15811 pg_wrapper.cc:525] initdb failed: Runtime error (yb/yql/pgwrapper/pg_wrapper.cc:467): /yb-source/build/debug-clang12-dynamic/postgres/bin/initdb failed with exit code 1
[m-1] E0226 15:54:20.630429 15811 catalog_manager.cc:7776] initdb failed: Runtime error (yb/yql/pgwrapper/pg_wrapper.cc:467): /yb-source/build/debug-clang12-dynamic/postgres/bin/initdb failed with exit code 1
E0226 15:54:21.075644 15749 external_mini_cluster.cc:1247] master reported an initdb error: Runtime error (yb/yql/pgwrapper/pg_wrapper.cc:467): /yb-source/build/debug-clang12-dynamic/postgres/bin/initdb failed with exit code 1
/yb-source/src/yb/yql/pgwrapper/pg_wrapper_test_base.cc:58: Failure
Failed
Bad status: Runtime error (yb/integration-tests/external_mini_cluster.cc:1248): Failed to start masters.: initdb failed: Runtime error (yb/yql/pgwrapper/pg_wrapper.cc:467): /yb-source/build/debug-clang12-dynamic/postgres/bin/initdb failed with exit code 1
[m-1] W0226 15:54:21.096375 15815 catalog_manager.cc:2084] Tablespace refresh task failed with error Internal error (yb/master/catalog_manager.cc:1929): pg_tablespace table info not found
Test failure stack trace:
/yb-source/src/yb/yql/pgwrapper/pg_wrapper_test_base.cc:58: # 0x7f2962b044e9 yb::pgwrapper::PgWrapperTestBase::SetUp()
/yb-source/src/yb/yql/pgwrapper/create_initial_sys_catalog_snapshot.cc:29: # 0x404d94 yb::pgwrapper::CreateInitialSysCatalogSnapshotTest::SetUp()
I0226 15:54:21.706461 15749 external_mini_cluster.cc:2206] { daemon_id: m-1 bound_rpc: :0 } Starting Shutdown()
I0226 15:54:21.706606 15749 external_mini_cluster.cc:2249] Killing /yb-source/build/debug-clang12-dynamic/tests-pgwrapper/../bin/yb-master with pid 15756 with SIGKILL
I0226 15:54:21.719123 15749 test_util.cc:94] -----------------------------------------------
I0226 15:54:21.719149 15749 test_util.cc:95] Had fatal failures, leaving test files at /tmp/yb_test.tmp.32433.7631.5669.pid15685/create_initial_sys_catalog_snapshot.CreateInitialSysCatalogSnapshotTest.CreateInitialSysCatalogSnapshot.1645890856672495-15749
[ FAILED ] CreateInitialSysCatalogSnapshotTest.CreateInitialSysCatalogSnapshot (5016 ms)
[----------] 1 test from CreateInitialSysCatalogSnapshotTest (5016 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test case ran. (5016 ms total)
[ PASSED ] 0 tests.
[ FAILED ] 1 test, listed below:
[ FAILED ] CreateInitialSysCatalogSnapshotTest.CreateInitialSysCatalogSnapshot
1 FAILED TEST
I0226 15:54:21.751582 15748 run-with-timeout.cc:198] subprocess.Wait finished, waitpid() returned 256
...
[postprocess_test_result.py:246] 2022-02-26 15:54:22,577 INFO: Wrote JSON test report file: /yb-source/build/debug-clang12-dynamic/yb-test-logs/tests-pgwrapper__create_initial_sys_catalog_snapshot/CreateInitialSysCatalogSnapshotTest_CreateInitialSysCatalogSnapshot_test_report.json
(end of standard error)
Traceback (most recent call last):
File "/yb-source/python/yb/gen_initial_sys_catalog_snapshot.py", line 83, in <module>
main()
File "/yb-source/python/yb/gen_initial_sys_catalog_snapshot.py", line 74, in main
raise RuntimeError("initdb failed in %.1f sec" % elapsed_time_sec)
RuntimeError: initdb failed in 6.4 sec
make[2]: *** [src/yb/yql/pgwrapper/CMakeFiles/initial_sys_catalog_snapshot.dir/build.make:70: src/yb/yql/pgwrapper/CMakeFiles/initial_sys_catalog_snapshot] Error 1
make[1]: *** [CMakeFiles/Makefile2:51929: src/yb/yql/pgwrapper/CMakeFiles/initial_sys_catalog_snapshot.dir/all] Error 2
make: *** [Makefile:101: all] Error 2
This happens in Alma Linux 8.5. Any hints?
You need some additional packages and it should work:
dnf install langpacks-en glibc-all-langpacks -y

Xenomai 3.1 mercury prologue failed for thread running official demo

Hello I have the following problem running a Xenomai demo: "prologue failed for thread" EINVAL
debian:~/xenomai_mercury_lib/demo$ sudo ./alchemy/altency
0"000.665| WARNING: [main] prologue failed for thread <anonymous>, EINVAL
== Sampling period: 100 us
== Test mode: periodic user-mode task
== All results in microseconds
0"000.997| WARNING: [main] prologue failed for thread alt-display-2077, EINVAL
altency: failed to create display task, code -22
What I have:
debian 10.10.0-amd64, installed inside a VirtualBox
xenomai 3.1 mercury installed and built for 32bit target
xenomai configure:
../xenomai-3.1/configure --enable-lores-clock --with-core=mercury --enable-smp --enable-pshared CFLAGS="-m32 -O2" LDFLAGS="-m32"
Maybe something is missing inside the underlying OS? Something to install?
Do you have some ideas?
Thanks a lot.

"make test" output errors command after installed preCICE on Centos 7

I get an error the following after run make test command in preCICE on Centos 7. Did anyone encounter this problem?
Thank you...
cmake parameters when building
cmake3 .. -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Debug -DMPI=ON
-DMPIEXEC_EXECUTABLE=/opt/ohpc/pub/mpi/openmpi3-gnu8/3.1.4/bin/mpiexec
-DCMAKE_INSTALL_PREFIX=/opt $PRECICE_ROOT
[root#headnode build]# make test
Running tests...
Test project /opt/precice-1.6.1/build
Start 1: precice.Base
1/4 Test #1: precice.Base .....................***Failed 0.01 sec
Start 2: precice.MPI_Ports
2/4 Test #2: precice.MPI_Ports ................***Failed 0.01 sec
Start 3: precice.PetRBFParallel
3/4 Test #3: precice.PetRBFParallel ...........***Failed 0.01 sec
Start 4: precice.NoMPI
4/4 Test #4: precice.NoMPI .................... Passed 4.09 sec
25% tests passed, 3 tests failed out of 4
Label Time Summary:
canfail = 0.02 sec*proc (2 tests)
Total Test time (real) = 4.14 sec
The following tests FAILED:
1 - precice.Base (Failed)
2 - precice.MPI_Ports (Failed)
3 - precice.PetRBFParallel (Failed)
Errors while running CTest
make: *** [test] Error 8
Before running test as root enter following :
export OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1
export OMPI_ALLOW_RUN_AS_ROOT=1

Tty.c: loadable library and perl binaries are mismatched

I upgraded Ubuntu from zesty to bionic. In the process perl was upgraded from 5.24.1 to 5.26.1. Now I am getting this error when I try to install Expect.
Tty.c: loadable library and perl binaries are mismatched
I have re-installed IO::Tty and that says it has installed correctly. There are other modules that are reporting similar errors.
Here is the full output from the failed Expect install.
Fetching http://www.cpan.org/authors/id/J/JA/JACOBY/Expect-1.35.tar.gz
-> OK
Unpacking Expect-1.35.tar.gz
Entering Expect-1.35
Checking configure dependencies from META.json
Checking if you have ExtUtils::MakeMaker 6.64 ... Yes (7.24)
Configuring Expect-1.35
Running Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Expect
Writing MYMETA.yml and MYMETA.json
-> OK
Checking dependencies from MYMETA.json ...
Checking if you have Fcntl 0 ... Yes (1.13)
Checking if you have IO::Handle 0 ... Yes (1.36)
Checking if you have IO::Pty 1.11 ... Yes (1.12)
Checking if you have Errno 0 ... Yes (1.28)
Checking if you have Test::More 1.00 ... Yes (1.302162)
Checking if you have Exporter 0 ... Yes (5.72)
Checking if you have IO::Tty 1.11 ... Yes (1.12)
Checking if you have File::Temp 0 ... Yes (0.2309)
Checking if you have POSIX 0 ... Yes (1.76)
Checking if you have Carp 0 ... Yes (1.42)
Building and testing Expect-1.35
cp lib/Expect.pm blib/lib/Expect.pm
Manifying 1 pod document
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/01-test.t .......
Dubious, test returned 1 (wstat 256, 0x100)
Failed 14/14 subtests
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/02-bc.t .........
Dubious, test returned 1 (wstat 256, 0x100)
No subtests run
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/03-log.t ........
Dubious, test returned 1 (wstat 256, 0x100)
Failed 11/11 subtests
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/04-multiline.t ..
Dubious, test returned 1 (wstat 256, 0x100)
Failed 33/33 subtests
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/10-internal.t ...
Dubious, test returned 1 (wstat 256, 0x100)
Failed 17/17 subtests
Tty.c: loadable library and perl binaries are mismatched (got handshake key 0xdb80080, needed 0xde00080)
t/11-calc.t .......
Dubious, test returned 1 (wstat 256, 0x100)
No subtests run
Test Summary Report
-------------------
t/01-test.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: Bad plan. You planned 14 tests but ran 0.
t/02-bc.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: No plan found in TAP output
t/03-log.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: Bad plan. You planned 11 tests but ran 0.
t/04-multiline.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: Bad plan. You planned 33 tests but ran 0.
t/10-internal.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: Bad plan. You planned 17 tests but ran 0.
t/11-calc.t (Wstat: 256 Tests: 0 Failed: 0)
Non-zero exit status: 1
Parse errors: No plan found in TAP output
Files=6, Tests=0, 2 wallclock secs ( 0.08 usr 0.03 sys + 1.87 cusr 0.21 csys = 2.19 CPU)
Result: FAIL
Failed 6/6 test programs. 0/0 subtests failed.
Makefile:856: recipe for target 'test_dynamic' failed
make: *** [test_dynamic] Error 1
-> FAIL Installing Expect failed. See /home/chronos/.cpanm/work/1554249881.4055/build.log for details. Retry with --force to force install it.
chronos#BattleShip:~/app$ perl -v
This is perl 5, version 26, subversion 1 (v5.26.1) built for x86_64-linux-gnu-thread-multi
(with 67 registered patches, see perl -V for more detail)
Copyright 1987-2017, Larry Wall
Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.
Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
I deleted my ~/perl5 directory. Expect installed fine.

Resources