[depends] Boost fails to build on OSX 10.11, Xcode 7.3.1 #7998

issue fanquake opened this issue on May 4, 2016
  1. fanquake commented at 2:06 AM on May 4, 2016: member
    clang: warning: optimization flag '-finline-functions' is not supported
    In file included from libs/thread/src/pthread/once.cpp:8:
    In file included from libs/thread/src/pthread/./once_atomic.cpp:9:
    In file included from ./boost/thread/once.hpp:20:
    In file included from ./boost/thread/pthread/once_atomic.hpp:16:
    ./boost/thread/detail/move.hpp:31:10: fatal error: 'type_traits' file not found
    #include <type_traits>
    

    It seems adding -stdlib=libc++ to the cxxflags fixes the issue

    This also occurs with the x86_64-apple-darwin11 prefix

  2. fanquake commented at 2:15 AM on May 4, 2016: member

    @theuni if this would be an appropriate fix I can add it it to #7993

  3. theuni commented at 5:09 AM on May 4, 2016: member

    Hmm, I would expect you to have the same problem with all other c++ deps as well.

    Let's just match the way we do it on the host side. Does this work?

    diff --git a/depends/builders/darwin.mk b/depends/builders/darwin.mk
    index 200d6ed..27f550a 100644
    --- a/depends/builders/darwin.mk
    +++ b/depends/builders/darwin.mk
    @@ -11,7 +11,7 @@ build_darwin_DOWNLOAD = curl --location --fail --connect-timeout $(DOWNLOAD_CONN
    
     #darwin host on darwin builder. overrides darwin host preferences.
     darwin_CC=$(shell xcrun -f clang) -mmacosx-version-min=$(OSX_MIN_VERSION)
    -darwin_CXX:=$(shell xcrun -f clang++) -mmacosx-version-min=$(OSX_MIN_VERSION)
    +darwin_CXX:=$(shell xcrun -f clang++) -mmacosx-version-min=$(OSX_MIN_VERSION) -stdlib=libc++
     darwin_AR:=$(shell xcrun -f ar)
     darwin_RANLIB:=$(shell xcrun -f ranlib)
     darwin_STRIP:=$(shell xcrun -f strip)
    
  4. jonasschnelli added the label MacOSX on May 4, 2016
  5. jonasschnelli added the label Build system on May 4, 2016
  6. laanwj closed this on May 5, 2016

  7. MarcoFalke locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me