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.86.0: process library does not build on iOS #25628

Open
amerry opened this issue Oct 15, 2024 · 1 comment
Open

[package] boost/1.86.0: process library does not build on iOS #25628

amerry opened this issue Oct 15, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@amerry
Copy link

amerry commented Oct 15, 2024

Description

When building the Boost package for iOS, it attempts to compile the process library by default. This fails as iOS has no subprocess support, so the necessary headers are not available.

This can be worked around by passing -o boost:without_process=True, but it would be good to have this be the default when targetting iOS, and to have the validation step check for this before starting the build.

Package and Environment Details

  • Package Name/Version: boost/1.86.0
  • Operating System+version: macOS Sonoma 14.7 targetting iOS 16.0
  • Compiler+version: apple-clang 15.0.0
  • Conan version: conan 1.65.0
  • Python version: Python 3.12.7

Conan profile

Host

[settings]
os=iOS
os.sdk=iphoneos
os.version=16.0
arch=armv8
compiler=apple-clang
compiler.version=15.0
compiler.libcxx=libc++
[options]
[conf]
[build_requires]
*: ios-cmake/4.2.0
[env]
IPHONEOS_DEPLOYMENT_TARGET=16.0

Build

[settings]
os=Macos
os_build=Macos
arch=armv8
arch_build=armv8
compiler=apple-clang
compiler.version=15
compiler.libcxx=libc++
build_type=Release
[options]
[conf]
[build_requires]
[env]

Steps to reproduce

mkdir conan-home
CONAN_USER_HOME=$PWD/conan-home conan config init
cp ios-test conan-home/.conan/profiles/ios-test
CONAN_USER_HOME=$PWD/conan-home conan conan install --build "*" -r conancenter boost/1.86.0@ -pr:b default -pr:h ios-test

Logs

Click to expand log
boost/1.86.0: Applying build-requirement: ios-cmake/4.2.0
boost/1.86.0: Applying build-requirement: b2/5.2.1
Downloading conan_sources.tgz completed [0.41k]
Decompressing conan_sources.tgz completed [0.00k]
boost/1.86.0: Configuring sources in /Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src
Downloading boost_1_86_0.tar.bz2 completed [123262.36k]                                  boost/1.86.0: /1.86.0:
boost/1.86.0:
boost/1.86.0: Apply patch (conan): Optional flag to specify iconv from either libc of libiconv
boost/1.86.0: Building your package in /Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/build/8f8460bcc3686f58aad8e2711941c222237e8e40
boost/1.86.0: Generator txt created conanbuildinfo.txt
boost/1.86.0: Calling generate()
boost/1.86.0: Aggregating env generators
boost/1.86.0: Calling build()
boost/1.86.0: WARN: replace_in_file didn't find pattern '/* thread_local */' in '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.86.0: WARN: replace_in_file didn't find pattern '/* static __thread */' in '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.86.0: WARN: replace_in_file didn't find pattern 'local generic-os = [ set.difference $(all-os) : aix darwin vxworks solaris osf hpux ] ;' in '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/tools/build/src/tools/gcc.jam' file.
boost/1.86.0: WARN: replace_in_file didn't find pattern 'local no-threading = android beos haiku sgi darwin vxworks ;' in '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/tools/build/src/tools/gcc.jam' file.
boost/1.86.0: WARN: Patching user-config.jam
boost/1.86.0: WARN:
using zlib : 1.3.1 : <include>"/Users/alex.merry/src/test/conan-home/.conan/data/zlib/1.3.1/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f/include" <search>"/Users/alex.merry/src/test/conan-home/.conan/data/zlib/1.3.1/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f/lib" <name>z ;
using bzip2 : 1.0.8 : <include>"/Users/alex.merry/src/test/conan-home/.conan/data/bzip2/1.0.8/_/_/package/5b4f31579e9c664a70b11dfd163e6e2a4008ba91/include" <search>"/Users/alex.merry/src/test/conan-home/.conan/data/bzip2/1.0.8/_/_/package/5b4f31579e9c664a70b11dfd163e6e2a4008ba91/lib" <name>bz2 ;
using "clang-darwin" :  :  "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++" -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.5.sdk -arch arm64 :
<archiver>"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar" <ranlib>"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib" <compileflags>"-I/Users/alex.merry/src/test/conan-home/.conan/data/libbacktrace/cci.20210118/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f/include" <linkflags>"-L/Users/alex.merry/src/test/conan-home/.conan/data/libbacktrace/cci.20210118/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f/lib" <target-os>"iphone"  ;
boost/1.86.0: Cross building, detecting compiler...
boost/1.86.0: Cross building flags: []
boost/1.86.0: WARN: b2 -q numa=on architecture=arm address-model=64 binary-format=mach-o abi=aapcs --layout=system --user-config=/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.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=libiconv threading=multi visibility=hidden link=static variant=release --with-atomic --with-charconv --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-iostreams --with-json --with-locale --with-log --with-nowide --with-process --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=clang-darwin cxxstd=11 pch=on -sLIBBACKTRACE_PATH=/Users/alex.merry/src/test/conan-home/.conan/data/libbacktrace/cci.20210118/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f -sICONV_PATH=/Users/alex.merry/src/test/conan-home/.conan/data/libiconv/1.17/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f linkflags="-stdlib=libc++ -mios-version-min=16.0" cxxflags="-fPIC -stdlib=libc++ -mios-version-min=16.0 -DBOOST_SP_USE_SPINLOCK" install --prefix=/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/package/8f8460bcc3686f58aad8e2711941c222237e8e40 -j12 --abbreviate-paths -d0 --debug-configuration --build-dir="/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/build/8f8460bcc3686f58aad8e2711941c222237e8e40/build-release"
notice: found boost-build.jam at /Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/boost-build.jam
notice: loading B2 from /Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/build-system.jam
notice: Searching '/etc' '/Users/alex.merry' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/util' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/tools' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/options' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/contrib' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/build' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2' for site-config configuration file 'site-config.jam'.
notice: Configuration file 'site-config.jam' not found in '/etc' '/Users/alex.merry' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/util' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/tools' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/options' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/contrib' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2/build' '/Users/alex.merry/src/test/conan-home/.conan/data/b2/5.2.1/_/_/package/4e1751b0fa83186dec61c3f59d918b6b17b28aad/bin/.b2'.
notice: Loading explicitly specified user configuration file:
    /Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/tools/build/user-config.jam
notice: Searching '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/source/src/tools/build' for user-config configuration file 'user-config.jam'.
notice: Loading user-config configuration file 'user-config.jam' from '/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.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 '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++' '-isysroot' '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.5.sdk' '-arch' 'arm64' for clang-darwin, condition <toolset>clang-15
notice: [openssl] Using pre-installed library
notice: [openssl] Condition
notice: using boost library auto_config <layout>system
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] ...does not invoke a working interpreter
notice: [python-cfg] Python headers and libraries not found.
Performing configuration checks

    - default address-model    : 64-bit [1]
    - default architecture     : arm [1]
    - cxx11_static_assert      : yes [2]
    - cxx11_variadic_templates : yes [2]
    - cxx11_decltype           : yes [2]
    - GCC libquadmath and __float128 support : no [2]
    - cxx11_hdr_ratio          : yes [2]
    - cxx11_template_aliases   : yes [2]
    - cxx11_char16_t           : yes [2]
    - cxx11_char32_t           : yes [2]
    - has std::atomic_ref      : no [2]
    - has statx                : no [2]
    - has statx syscall        : no [2]
    - cxx11_rvalue_references  : yes [2]
    - cxx11_scoped_enums       : yes [2]
    - cxx11_noexcept           : yes [2]
    - cxx11_nullptr            : yes [2]
    - cxx11_defaulted_functions : yes [2]
    - cxx11_defaulted_moves    : yes [2]
    - cxx11_deleted_functions  : yes [2]
    - cxx11_function_template_default_args : yes [2]
    - cxx11_final              : yes [2]
    - cxx11_override           : yes [2]
    - has init_priority attribute : yes [2]
    - has stat::st_blksize     : no [2]
    - has stat::st_mtim        : no [2]
    - has stat::st_mtimensec   : no [2]
    - has stat::st_mtimespec   : yes [2]
    - has stat::st_birthtim    : no [2]
    - has stat::st_birthtimensec : no [2]
    - has stat::st_birthtimespec : yes [2]
    - has fdopendir(O_NOFOLLOW) : yes [2]
    - has dirent::d_type       : yes [2]
    - has POSIX *at APIs       : no [2]
    - has fallocate            : no [2]
    - cxx11_auto_declarations  : yes [2]
    - cxx11_constexpr          : yes [2]
    - cxx11_hdr_mutex          : yes [2]
    - cxx11_hdr_tuple          : yes [2]
    - cxx11_lambdas            : yes [2]
    - cxx11_thread_local       : yes [2]
    - zlib                     : yes [2]
    - bzip2                    : yes [2]
    - cxx11_basic_alignas      : yes [2]
    - iconv (libc)             : no [2]
    - iconv (separate)         : yes [2]
    - cxx11_hdr_functional     : yes [2]
    - cxx11_hdr_type_traits    : yes [2]
    - cxx11_range_based_for    : yes [2]
    - cxx11_smart_ptr          : yes [2]
    - native atomic int32 supported : yes [2]
    - native syslog supported  : yes [2]
    - pthread supports robust mutexes : no [2]
    - Boost.Regex is header-only : yes [2]
    - lockfree boost::atomic_flag : yes [2]
    - Has Large File Support   : yes [2]
    - Has attribute init_priority : 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_allocator          : yes [2]
    - cxx11_explicit_conversion_operators : yes [2]
    - has_icu builds           : no [2]
    - std_wstreambuf builds    : yes [2]
    - std_wstreambuf           : yes [2]
    - libbacktrace builds      : yes [2]
    - addr2line builds         : no [2]
    - cxx11_rvalue_references  : yes [3]
    - addr2line builds         : no [3]
    - WinDbg builds            : no [2]
    - WinDbg builds            : no [3]
    - WinDbgCached builds      : no [2]
    - WinDbgCached builds      : no [3]
    - BOOST_COMP_GNUC >= 4.3.0 : no [2]
    - cxx11_hdr_thread         : yes [2]
    - cxx11_hdr_regex          : yes [2]

[1] clng-15
[2] clng-drwn-15/rls/arm_6/bst.l-lbcnv/bst.l-on/bst.l-off/cxstd-11-iso/lnk-sttc/nm-on/thrd-mlt/vsblt-hdn
[3] clng-drwn-15/rls/arm_6/bst.l-lbcnv/bst.l-on/bst.l-off/bld-no/cxstd-11-iso/lnk-sttc/nm-on/thrd-mlt/vsblt-hdn

Component configuration:

    - atomic                   : building
    - charconv                 : building
    - chrono                   : building
    - cobalt                   : not building
    - container                : building
    - context                  : building
    - contract                 : building
    - coroutine                : building
    - date_time                : building
    - exception                : building
    - fiber                    : building
    - filesystem               : building
    - graph                    : not building
    - graph_parallel           : not building
    - headers                  : not building
    - iostreams                : building
    - json                     : building
    - locale                   : building
    - log                      : building
    - math                     : not building
    - mpi                      : not building
    - nowide                   : building
    - process                  : 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
    - url                      : building
    - wave                     : building
    - predef                   : not building

libs/process/src/ext/cmd.cpp:26:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/ext/cwd.cpp:27:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/ext/proc_info.cpp:23:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/ext/exe.cpp:28:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/ext/env.cpp:24:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/pid.cpp:20:10: fatal error: 'sys/proc_info.h' file not found
#include <sys/proc_info.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.
libs/process/src/shell.cpp:100:15: error: 'wordexp' is unavailable: not available on iOS
    auto cd = wordexp(input_.c_str(), &we, WRDE_NOCMD);
              ^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.5.sdk/usr/include/wordexp.h:81:5: note: 'wordexp' has been explicitly marked unavailable here
int wordexp(const char * __restrict, wordexp_t * __restrict, int) __OSX_AVAILABLE_STARTING(__MAC_10_0, __IPHONE_NA);
    ^
libs/process/src/shell.cpp:117:9: error: 'wordfree' is unavailable: not available on iOS
        wordfree(&we);
        ^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.5.sdk/usr/include/wordexp.h:82:6: note: 'wordfree' has been explicitly marked unavailable here
void wordfree(wordexp_t *) __OSX_AVAILABLE_STARTING(__MAC_10_0, __IPHONE_NA);
     ^
2 errors generated.

...failed updating 0 target...
boost/1.86.0:
boost/1.86.0: ERROR: Package '8f8460bcc3686f58aad8e2711941c222237e8e40' build failed
boost/1.86.0: WARN: Build folder /Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/build/8f8460bcc3686f58aad8e2711941c222237e8e40/build-release
ERROR: boost/1.86.0: Error in build() method, line 1165
	self.run(full_command)
	ConanException: Error 1 while executing b2 -q numa=on architecture=arm address-model=64 binary-format=mach-o abi=aapcs --layout=system --user-config=/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.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=libiconv threading=multi visibility=hidden link=static variant=release --with-atomic --with-charconv --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-iostreams --with-json --with-locale --with-log --with-nowide --with-process --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=clang-darwin cxxstd=11 pch=on -sLIBBACKTRACE_PATH=/Users/alex.merry/src/test/conan-home/.conan/data/libbacktrace/cci.20210118/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f -sICONV_PATH=/Users/alex.merry/src/test/conan-home/.conan/data/libiconv/1.17/_/_/package/1ddb58ac7e257e3384e314d3ccbe212774f5889f linkflags="-stdlib=libc++ -mios-version-min=16.0" cxxflags="-fPIC -stdlib=libc++ -mios-version-min=16.0 -DBOOST_SP_USE_SPINLOCK" install --prefix=/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/package/8f8460bcc3686f58aad8e2711941c222237e8e40 -j12 --abbreviate-paths -d0 --debug-configuration --build-dir="/Users/alex.merry/src/test/conan-home/.conan/data/boost/1.86.0/_/_/build/8f8460bcc3686f58aad8e2711941c222237e8e40/build-release"
@amerry amerry added the bug Something isn't working label Oct 15, 2024
@amerry
Copy link
Author

amerry commented Oct 15, 2024

NB: I have a local fix for this, which I will submit in a PR (once I've had project access approved), but the contribution guidelines indicated there should be an issue first.

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
Development

No branches or pull requests

1 participant