Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[package] boost/1.70-1.80: Errors with cross-compilation to armv8 following latest recipe update #14767

Closed
evansneath opened this issue Dec 15, 2022 · 10 comments · Fixed by #14776
Labels
bug Something isn't working

Comments

@evansneath
Copy link

Description

Following the latest commit c679b7c6f5642fc49b6a2b1cbb9ecf2f05dbf3c6 with modifications to update the boost recipe to support conan v2, cross-compilation builds of boost from linux x86-64 to linux arm-64 now fail to build.

This is confirmed to be an issue relating only to the latest commit due to cross-compilation working fine until yesterday and with showing successful building using the previous recipe revision (cfb90226b9dfe2f948b861b54ef5dab6).

Package and Environment Details

  • Package Name/Version: boost/1.70 through boost/1.80 (boost/1.69.0 seems to be the only version unaffected)
  • Operating System+version: Linux Ubuntu 18.04
  • Compiler+version: GCC 7
  • Docker image: n/a
  • Conan version: conan 1.55.0
  • Python version: Python 3.8.0

Conan profile

Contents of profiles/linux-arm-64

toolchain=aarch64-linux-gnu

[settings]
os=Linux
arch=armv8
compiler=gcc
compiler.version=7
compiler.libcxx=libstdc++11
build_type=Release

[env]
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER
CONAN_CMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE=BOTH
CHOST=$toolchain
CC=$toolchain-gcc
CXX=$toolchain-g++

Steps to reproduce

Fails (see logs below)

conan install -r conancenter boost/1.79.0@ -pr:b=default -pr:h=linux-arm-64 --update --build missing --build outdated

Succeeds (using previous recipe revision):

conan install -r conancenter boost/1.79.0@#cfb90226b9dfe2f948b861b54ef5dab6 -pr:b=default -pr:h=linux-arm-64 --update --build missing --build outdated

Logs

Click to expand log
Configuration (profile_host):
[settings]
arch=armv8
build_type=Release
compiler=gcc
compiler.libcxx=libstdc++11
compiler.version=7
os=Linux
[options]
[build_requires]
[env]
CC=aarch64-linux-gnu-gcc
CHOST=aarch64-linux-gnu
CONAN_CMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE=BOTH
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER
CXX=aarch64-linux-gnu-g++
Configuration (profile_build):
[settings]
arch=x86_64
build_type=Release
compiler=gcc
compiler.libcxx=libstdc++11
compiler.version=7
os=Linux
[options]
[build_requires]
[env]
CC=gcc
CONAN_CMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE=BOTH
CONAN_CMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER
CXX=g++
bzip2/1.0.8: WARN: Can't update, no package in remote
bzip2/1.0.8: Package is up to date
libbacktrace/cci.20210118: WARN: Can't update, no package in remote
libbacktrace/cci.20210118: Package is up to date
zlib/1.2.13: WARN: Can't update, no package in remote
zlib/1.2.13: Package is up to date
boost/1.79.0: WARN: Package binary is corrupted, removing: 3aac81ffa04cca0028f0506d5a46ab398161b6d4
b2/4.9.2: Package is up to date
Installing package: boost/1.79.0
Requirements
    boost/1.79.0 from 'conancenter' - Cache
    bzip2/1.0.8 from 'conancenter' - Cache
    libbacktrace/cci.20210118 from 'conancenter' - Cache
    zlib/1.2.13 from 'conancenter' - Cache
Packages
    boost/1.79.0:3aac81ffa04cca0028f0506d5a46ab398161b6d4 - Build
    bzip2/1.0.8:75c0a8a066a2422a4e85cba63decf52760f1010c - Cache
    libbacktrace/cci.20210118:8fd38d381db52e2495321ce060b9f457656f6c8f - Cache
    zlib/1.2.13:8fd38d381db52e2495321ce060b9f457656f6c8f - Cache
Build requirements
    b2/4.9.2 from 'conancenter' - Cache
Build requirements packages
    b2/4.9.2:4db1be536558d833e52e862fd84d64d75c2b3656 - Cache

Cross-build from 'Linux:x86_64' to 'Linux:armv8'
Installing (downloading, building) binaries...
b2/4.9.2: Already installed!
bzip2/1.0.8: Already installed!
libbacktrace/cci.20210118: Already installed!
zlib/1.2.13: Already installed!
boost/1.79.0: Applying build-requirement: b2/4.9.2
boost/1.79.0: WARN: Build folder is dirty, removing it: /home/esneath/.conan/data/boost/1.79.0/_/_/build/3aac81ffa04cca0028f0506d5a46ab398161b6d4
boost/1.79.0: Building your package in /home/esneath/.conan/data/boost/1.79.0/_/_/build/3aac81ffa04cca0028f0506d5a46ab398161b6d4
boost/1.79.0: Generator txt created conanbuildinfo.txt
boost/1.79.0: Calling generate()
boost/1.79.0: Aggregating env generators
boost/1.79.0: Calling build()
boost/1.79.0: WARN: replace_in_file didn't find pattern '$(>) > $(<)' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/libs/stacktrace/build/Jamfile.v2' file.
boost/1.79.0: WARN: replace_in_file didn't find pattern '/* thread_local */' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.79.0: WARN: replace_in_file didn't find pattern '/* static __thread */' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.79.0: WARN: replace_in_file didn't find pattern 'local generic-os = [ set.difference $(all-os) : aix darwin vxworks solaris osf hpux ] ;' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/src/tools/gcc.jam' file.
boost/1.79.0: WARN: replace_in_file didn't find pattern 'local no-threading = android beos haiku sgi darwin vxworks ;' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/src/tools/gcc.jam' file.
boost/1.79.0: WARN: replace_in_file didn't find pattern '    <conditional>@numa' in '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/libs/fiber/build/Jamfile.v2' file.
boost/1.79.0: WARN: Patching user-config.jam
boost/1.79.0: WARN: 
using zlib : 1.2.13 : <include>"/home/esneath/.conan/data/zlib/1.2.13/_/_/package/8fd38d381db52e2495321ce060b9f457656f6c8f/include" <search>"/home/esneath/.conan/data/zlib/1.2.13/_/_/package/8fd38d381db52e2495321ce060b9f457656f6c8f/lib" <name>z ;
using bzip2 : 1.0.8 : <include>"/home/esneath/.conan/data/bzip2/1.0.8/_/_/package/75c0a8a066a2422a4e85cba63decf52760f1010c/include" <search>"/home/esneath/.conan/data/bzip2/1.0.8/_/_/package/75c0a8a066a2422a4e85cba63decf52760f1010c/lib" <name>bz2 ;
using "gcc" :  :  /usr/bin/g++-7 : 
<compileflags>"-I/home/esneath/.conan/data/libbacktrace/cci.20210118/_/_/package/8fd38d381db52e2495321ce060b9f457656f6c8f/include" <linkflags>"-L/home/esneath/.conan/data/libbacktrace/cci.20210118/_/_/package/8fd38d381db52e2495321ce060b9f457656f6c8f/lib"  ;
boost/1.79.0: Cross building, detecting compiler...
boost/1.79.0: Cross building flags: []
boost/1.79.0: WARN: b2 -q numa=on target-os=linux architecture=arm address-model=64 binary-format=elf abi=aapcs --layout=system --user-config=/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=release --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-wave toolset=gcc define=_GLIBCXX_USE_CXX11_ABI=1 pch=on linkflags="" cxxflags="-fPIC -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/home/esneath/.conan/data/boost/1.79.0/_/_/package/3aac81ffa04cca0028f0506d5a46ab398161b6d4 -j16 --abbreviate-paths -d0 --debug-configuration --build-dir="/home/esneath/.conan/data/boost/1.79.0/_/_/build/3aac81ffa04cca0028f0506d5a46ab398161b6d4/build-release"
notice: found boost-build.jam at /home/esneath/.conan/data/boost/1.79.0/_/_/source/src/boost-build.jam
notice: loading B2 from /home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/kernel/bootstrap.jam
notice: Searching '/etc' '/home/esneath' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/kernel' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/util' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/build' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/tools' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/contrib' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/.' for site-config configuration file 'site-config.jam'.
notice: Configuration file 'site-config.jam' not found in '/etc' '/home/esneath' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/kernel' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/util' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/build' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/tools' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/contrib' '/home/esneath/.conan/data/b2/4.9.2/_/_/package/4db1be536558d833e52e862fd84d64d75c2b3656/bin/.b2/.'.
notice: Loading explicitly specified user configuration file:
    /home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/user-config.jam
notice: Searching '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build' for user-config configuration file 'user-config.jam'.
notice: Loading user-config configuration file 'user-config.jam' from '/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build'.
notice: [zlib] Using pre-installed library
notice: [zlib] Condition
notice: [bzip2] Using pre-installed library
notice: [bzip2] Condition
notice: will use '/usr/bin/g++-7' for gcc, condition <toolset>gcc-7
notice: using gcc libraries :: <toolset>gcc-7 :: /usr/bin /usr/lib /usr/lib32 /usr/lib64
notice: using gcc archiver :: <toolset>gcc-7 :: /usr/bin/ar
warning: toolset gcc initialization: can not find tool windres
warning: initialized from /home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/user-config.jam:5
notice: using rc compiler :: <toolset>gcc-7 :: /usr/bin/as
notice: [zlib] zlib is already configured
notice: [bzip2] bzip is already configured
notice: iostreams: not using lzma compression 
notice: iostreams: not using zstd compression 
notice: [python-cfg] Configuring python...
notice: [python-cfg] Checking interpreter command "python"...
notice: [python-cfg] running command 'python -c "from sys import *; print('version=%d.%d\nplatform=%s\nprefix=%s\nexec_prefix=%s\nexecutable=%s' % (version_info[0],version_info[1],platform,prefix,exec_prefix,executable))" 2>&1'
notice: [python-cfg] ...requested configuration matched!
notice: [python-cfg] Details of this Python configuration:
notice: [python-cfg]   interpreter command: "python"
notice: [python-cfg]   include path: "/usr/include/python2.7"
notice: [python-cfg]   library path: "/usr/lib/python2.7/config" "/usr/lib"
notice: [python-cfg] Checking for NumPy...
notice: [python-cfg] running command 'python -c "import sys; sys.stderr = sys.stdout; import numpy; print(numpy.get_include())"'
notice: [python-cfg] NumPy disabled. Reason:
notice: [python-cfg]   python -c "import sys; sys.stderr = sys.stdout; import numpy; print(numpy.get_include())" aborted with 
notice: [python-cfg]   Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named numpy
Performing configuration checks

    - default address-model    : 64-bit [1]
    - default architecture     : x86 [1]
    - has std::atomic_ref      : no [2]
    - has statx                : no [2]
    - has statx syscall        : yes [2]
    - has init_priority attribute : yes [2]
    - has stat::st_blksize     : yes [2]
    - has stat::st_mtim        : yes [2]
    - has stat::st_mtimensec   : no [2]
    - has stat::st_mtimespec   : no [2]
    - has stat::st_birthtim    : no [2]
    - has stat::st_birthtimensec : no [2]
    - has stat::st_birthtimespec : no [2]
    - has fdopendir(O_NOFOLLOW) : yes [2]
    - cxx11_auto_declarations  : yes [2]
    - cxx11_constexpr          : yes [2]
    - cxx11_defaulted_functions : yes [2]
    - cxx11_final              : yes [2]
    - cxx11_hdr_mutex          : yes [2]
    - cxx11_hdr_tuple          : yes [2]
    - cxx11_lambdas            : yes [2]
    - cxx11_noexcept           : yes [2]
    - cxx11_nullptr            : yes [2]
    - cxx11_rvalue_references  : yes [2]
    - cxx11_template_aliases   : yes [2]
    - cxx11_thread_local       : yes [2]
    - cxx11_variadic_templates : yes [2]
    - has_icu builds           : no [2]
    - zlib                     : yes [3]
    - bzip2                    : no [3]
    - cxx11_decltype           : yes [2]
    - cxx11_basic_alignas      : yes [2]
    - iconv (libc)             : yes [2]
    - native atomic int32 supported : yes [2]
    - native syslog supported  : yes [2]
    - pthread supports robust mutexes : yes [2]
    - lockfree boost::atomic_flag : yes [2]
    - gcc visibility           : yes [2]
    - sfinae_expr              : yes [2]
    - cxx11_unified_initialization_syntax : yes [2]
    - cxx11_hdr_initializer_list : yes [2]
    - cxx11_hdr_chrono         : yes [2]
    - cxx11_numeric_limits     : yes [2]
    - cxx11_hdr_array          : yes [2]
    - cxx11_hdr_atomic         : yes [2]
    - cxx11_hdr_type_traits    : yes [2]
    - cxx11_allocator          : yes [2]
    - cxx11_explicit_conversion_operators : yes [2]
    - long double support      : yes [2]
    - cxx11_static_assert      : yes [2]
    - std::fstream is moveable and swappable : yes [2]
    - Has Large File Support   : yes [2]
    - Has attribute init_priority : yes [2]
    - libbacktrace builds      : yes [2]
    - addr2line builds         : yes [2]
    - WinDbg builds            : no [2]
    - WinDbg builds            : no [4]
    - WinDbgCached builds      : no [2]
    - WinDbgCached builds      : no [4]
    - BOOST_COMP_GNUC >= 4.3.0 : yes [2]
    - cxx11_hdr_thread         : yes [2]
    - cxx11_hdr_regex          : yes [2]

[1] gcc-7
[2] gcc-7/rls/abi-apcs/archt-arm/bst.l-lbc/bst.l-on/bst.l-off/lnk-sttc/nm-on/pythn-2.7/thrdp-pthrd/thrd-mlt/vsblt-hdn
[3] lnk-sttc
[4] gcc-7/rls/abi-apcs/archt-arm/bst.l-lbc/bst.l-on/bst.l-off/bld-no/lnk-sttc/nm-on/pythn-2.7/thrdp-pthrd/thrd-mlt/vsblt-hdn

Component configuration:

    - atomic                   : building
    - chrono                   : building
    - container                : building
    - context                  : building
    - contract                 : building
    - coroutine                : building
    - date_time                : building
    - exception                : building
    - fiber                    : building
    - filesystem               : building
    - graph                    : building
    - graph_parallel           : not building
    - headers                  : not building
    - iostreams                : building
    - json                     : building
    - locale                   : building
    - log                      : building
    - math                     : building
    - mpi                      : not building
    - nowide                   : building
    - program_options          : building
    - python                   : not building
    - random                   : building
    - regex                    : building
    - serialization            : building
    - stacktrace               : building
    - system                   : building
    - test                     : building
    - thread                   : building
    - timer                    : building
    - type_erasure             : building
    - wave                     : building

make_arm64_aapcs_elf_gas.S: Assembler messages:
make_arm64_aapcs_elf_gas.S:61: Error: too many memory references for `and'
make_arm64_aapcs_elf_gas.S:64: Error: too many memory references for `sub'
make_arm64_aapcs_elf_gas.S:68: Error: invalid char '[' beginning operand 2 `[x0'
make_arm64_aapcs_elf_gas.S:72: Error: no such instruction: `adr x1,finish'
make_arm64_aapcs_elf_gas.S:73: Error: invalid char '[' beginning operand 2 `[x0'
make_arm64_aapcs_elf_gas.S:75: Error: operand size mismatch for `ret'
make_arm64_aapcs_elf_gas.S:79: Error: expecting operand after ','; got nothing
make_arm64_aapcs_elf_gas.S:81: Error: no such instruction: `bl _exit'
jump_arm64_aapcs_elf_gas.S: Assembler messages:
jump_arm64_aapcs_elf_gas.S:61: Error: too many memory references for `sub'
jump_arm64_aapcs_elf_gas.S:64: Error: no such instruction: `stp d8,d9,[sp,'
jump_arm64_aapcs_elf_gas.S:65: Error: no such instruction: `stp d10,d11,[sp,'
jump_arm64_aapcs_elf_gas.S:66: Error: no such instruction: `stp d12,d13,[sp,'
jump_arm64_aapcs_elf_gas.S:67: Error: no such instruction: `stp d14,d15,[sp,'
jump_arm64_aapcs_elf_gas.S:70: Error: no such instruction: `stp x19,x20,[sp,'
jump_arm64_aapcs_elf_gas.S:71: Error: no such instruction: `stp x21,x22,[sp,'
jump_arm64_aapcs_elf_gas.S:72: Error: no such instruction: `stp x23,x24,[sp,'
jump_arm64_aapcs_elf_gas.S:73: Error: no such instruction: `stp x25,x26,[sp,'
jump_arm64_aapcs_elf_gas.S:74: Error: no such instruction: `stp x27,x28,[sp,'
jump_arm64_aapcs_elf_gas.S:75: Error: no such instruction: `stp x29,x30,[sp,'
jump_arm64_aapcs_elf_gas.S:78: Error: invalid char '[' beginning operand 2 `[sp'
jump_arm64_aapcs_elf_gas.S:81: Error: too many memory references for `mov'
jump_arm64_aapcs_elf_gas.S:84: Error: too many memory references for `mov'
jump_arm64_aapcs_elf_gas.S:87: Error: no such instruction: `ldp d8,d9,[sp,'
jump_arm64_aapcs_elf_gas.S:88: Error: no such instruction: `ldp d10,d11,[sp,'
jump_arm64_aapcs_elf_gas.S:89: Error: no such instruction: `ldp d12,d13,[sp,'
jump_arm64_aapcs_elf_gas.S:90: Error: no such instruction: `ldp d14,d15,[sp,'
jump_arm64_aapcs_elf_gas.S:93: Error: no such instruction: `ldp x19,x20,[sp,'
jump_arm64_aapcs_elf_gas.S:94: Error: no such instruction: `ldp x21,x22,[sp,'
jump_arm64_aapcs_elf_gas.S:95: Error: no such instruction: `ldp x23,x24,[sp,'
jump_arm64_aapcs_elf_gas.S:96: Error: no such instruction: `ldp x25,x26,[sp,'
jump_arm64_aapcs_elf_gas.S:97: Error: no such instruction: `ldp x27,x28,[sp,'
jump_arm64_aapcs_elf_gas.S:98: Error: no such instruction: `ldp x29,x30,[sp,'
jump_arm64_aapcs_elf_gas.S:103: Error: too many memory references for `mov'
jump_arm64_aapcs_elf_gas.S:106: Error: no such instruction: `ldr x4,[sp,'
jump_arm64_aapcs_elf_gas.S:109: Error: too many memory references for `add'
jump_arm64_aapcs_elf_gas.S:111: Error: operand size mismatch for `ret'
ontop_arm64_aapcs_elf_gas.S: Assembler messages:
ontop_arm64_aapcs_elf_gas.S:61: Error: too many memory references for `sub'
ontop_arm64_aapcs_elf_gas.S:64: Error: no such instruction: `stp d8,d9,[sp,'
ontop_arm64_aapcs_elf_gas.S:65: Error: no such instruction: `stp d10,d11,[sp,'
ontop_arm64_aapcs_elf_gas.S:66: Error: no such instruction: `stp d12,d13,[sp,'
ontop_arm64_aapcs_elf_gas.S:67: Error: no such instruction: `stp d14,d15,[sp,'
ontop_arm64_aapcs_elf_gas.S:70: Error: no such instruction: `stp x19,x20,[sp,'
ontop_arm64_aapcs_elf_gas.S:71: Error: no such instruction: `stp x21,x22,[sp,'
ontop_arm64_aapcs_elf_gas.S:72: Error: no such instruction: `stp x23,x24,[sp,'
ontop_arm64_aapcs_elf_gas.S:73: Error: no such instruction: `stp x25,x26,[sp,'
ontop_arm64_aapcs_elf_gas.S:74: Error: no such instruction: `stp x27,x28,[sp,'
ontop_arm64_aapcs_elf_gas.S:75: Error: no such instruction: `stp x29,x30,[sp,'
ontop_arm64_aapcs_elf_gas.S:78: Error: invalid char '[' beginning operand 2 `[sp'
ontop_arm64_aapcs_elf_gas.S:81: Error: too many memory references for `mov'
ontop_arm64_aapcs_elf_gas.S:84: Error: too many memory references for `mov'
ontop_arm64_aapcs_elf_gas.S:87: Error: no such instruction: `ldp d8,d9,[sp,'
ontop_arm64_aapcs_elf_gas.S:88: Error: no such instruction: `ldp d10,d11,[sp,'
ontop_arm64_aapcs_elf_gas.S:89: Error: no such instruction: `ldp d12,d13,[sp,'
ontop_arm64_aapcs_elf_gas.S:90: Error: no such instruction: `ldp d14,d15,[sp,'
ontop_arm64_aapcs_elf_gas.S:93: Error: no such instruction: `ldp x19,x20,[sp,'
ontop_arm64_aapcs_elf_gas.S:94: Error: no such instruction: `ldp x21,x22,[sp,'
ontop_arm64_aapcs_elf_gas.S:95: Error: no such instruction: `ldp x23,x24,[sp,'
ontop_arm64_aapcs_elf_gas.S:96: Error: no such instruction: `ldp x25,x26,[sp,'
ontop_arm64_aapcs_elf_gas.S:97: Error: no such instruction: `ldp x27,x28,[sp,'
ontop_arm64_aapcs_elf_gas.S:98: Error: no such instruction: `ldp x29,x30,[sp,'
ontop_arm64_aapcs_elf_gas.S:103: Error: too many memory references for `mov'
ontop_arm64_aapcs_elf_gas.S:107: Error: too many memory references for `add'
ontop_arm64_aapcs_elf_gas.S:110: Error: operand size mismatch for `ret'
...failed updating 2 targets...
boost/1.79.0: 
boost/1.79.0: ERROR: Package '3aac81ffa04cca0028f0506d5a46ab398161b6d4' build failed
boost/1.79.0: WARN: Build folder /home/esneath/.conan/data/boost/1.79.0/_/_/build/3aac81ffa04cca0028f0506d5a46ab398161b6d4/build-release
ERROR: boost/1.79.0: Error in build() method, line 850
        self.run(full_command)
        ConanException: Error 1 while executing b2 -q numa=on target-os=linux architecture=arm address-model=64 binary-format=elf abi=aapcs --layout=system --user-config=/home/esneath/.conan/data/boost/1.79.0/_/_/source/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=release --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-wave toolset=gcc define=_GLIBCXX_USE_CXX11_ABI=1 pch=on linkflags="" cxxflags="-fPIC -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/home/esneath/.conan/data/boost/1.79.0/_/_/package/3aac81ffa04cca0028f0506d5a46ab398161b6d4 -j16 --abbreviate-paths -d0 --debug-configuration --build-dir="/home/esneath/.conan/data/boost/1.79.0/_/_/build/3aac81ffa04cca0028f0506d5a46ab398161b6d4/build-release"```

</details>
@evansneath evansneath added the bug Something isn't working label Dec 15, 2022
@evansneath evansneath changed the title [package] boost/1.70-1.80: Errors with cross-compilation to arm following latest recipe update [package] boost/1.70-1.80: Errors with cross-compilation to armv8 following latest recipe update Dec 15, 2022
@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 16, 2022

You may have to duplicate [env] section of your profile into [buildenv] section.

@Reavolt
Copy link

Reavolt commented Dec 16, 2022

@SpaceIm We have a similar problem. Duplicate section did not help.

@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 16, 2022

Can you try again with modifications in #14776 please? (still with a [buildenv] block in your profile).

@evansneath
Copy link
Author

evansneath commented Dec 16, 2022

@SpaceIm, duplication [env] block to a new [buildenv] block in the host profile (profiles/linux-arm-64 in my case) did work and the build now succeeds. I did not need to add any other options or change any conan settings.

Even though this fixes the issue, I'm not sure this is a suitable long-term fix for this package with conan v1 users since it forces an addition to the optional [buildenv] profile section and ignores the established convention of the [env] section working in the expected way for this package that it does for all other packages. It seems like there will be a lot more people with this issue if this is kept as the status quo. Just my opinion as an enterprise conan user who's tired of recipe updates for stable versions breaking builds.

Thank you for the workaround.

@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 16, 2022

@evansneath I understand, but I think there is nothing conan-center recipes migrated to conan v2 can do to have 100% support of legacy conan v1 profiles, since AFAIK conan client breaks itself this convention in all conan v2 build helpers (like it breaks CONAN_CMAKE_GENERATOR not listened anymore in recipes based on CMakeToolchain, or CONAN_CMAKE_TOOLCHAIN etc).

/cc @memsharded

@evansneath
Copy link
Author

evansneath commented Dec 16, 2022

@SpaceIm We have a similar problem. Duplicate section did not help.

@Reavolt, the prescribed fix worked for me, but it seems like it might not if you're running with an older version of conan that doesn't support the [buildenv] tag (as of v1.35.0 per buildenv docs)

@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 16, 2022

Latest RREV of boost recipe in conan-center doesn't support conan client < 1.53.0, and it should raise an error if you try to run conan command against this RREV:

required_conan_version = ">=1.53.0"

@evansneath
Copy link
Author

@SpaceIm, that makes sense. We'll add this section to all of our conan profiles. Looks like the best mitigating factor going forward is to specifically pin our required third-party packages to specific RREVs in order to shelter our build process from the upcoming v2 migration churn.

@SpaceIm
Copy link
Contributor

SpaceIm commented Dec 16, 2022

yes: https://github.com/conan-io/conan-center-index/blob/master/docs/consuming_recipes.md

Otherwise, I think conan-center (or conan) doc lacks documentation to explain how a user profile should be written to be conan v1/v2 compatible (due to lack of backward compatibility of legacy env vars, and forward compatibility of new buildenv vars & config), something like this for example:

toolchain=aarch64-linux-gnu

[settings]
os=Linux
arch=armv8
compiler=gcc
compiler.version=7
compiler.libcxx=libstdc++11
build_type=Release
[conf]
# for conan v2 recipes
tools.build:compiler_executables.c=$toolchain-gcc
tools.build:compiler_executables.cpp=$toolchain-g++
tools.cmake.cmaketoolchain:generator=Ninja
tools.cmake.cmaketoolchain:user_toolchain=path/to/my_toolchain.cmake
tools.gnu:make_program=make
[buildenv]
# for conan v2 recipes as well
CHOST=$toolchain
CC=$toolchain-gcc
CXX=$toolchain-g++
[env]
# for conan v1 recipes
CHOST=$toolchain
CC=$toolchain-gcc
CXX=$toolchain-g++
CONAN_CMAKE_GENERATOR=Ninja
CONAN_CMAKE_TOOLCHAIN_FILE=path/to/my_toolchain.cmake
CONAN_MAKE_PROGRAM=make

or better with jinja profile:

{% set toolchain = "aarch64-linux-gnu" %}

[settings]
os=Linux
arch=armv8
compiler=gcc
compiler.version=7
compiler.libcxx=libstdc++11
build_type=Release
[conf]
{# for conan v2 recipes #}
tools.build:compiler_executables.c={{ toolchain }}-gcc
tools.build:compiler_executables.cpp={{ toolchain }}-g++
tools.cmake.cmaketoolchain:generator=Ninja
tools.cmake.cmaketoolchain:user_toolchain=path/to/my_toolchain.cmake
tools.gnu:make_program=make
[buildenv]
{# for conan v2 recipes as well #}
CHOST={{ toolchain }}
CC={{ toolchain }}-gcc
CXX={{ toolchain }}-g++
[env]
{# for conan v1 recipes #}
CHOST={{ toolchain }}
CC={{ toolchain }}-gcc
CXX={{ toolchain }}-g++
CONAN_CMAKE_GENERATOR=Ninja
CONAN_CMAKE_TOOLCHAIN_FILE=path/to/my_toolchain.cmake
CONAN_MAKE_PROGRAM=make

or a compatiblity matrix between legacy env vars & new config

@evansneath
Copy link
Author

This is really useful input. We'll be making these changes across all of our profiles. Thanks again for the help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
3 participants