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

Add a note about OpenSSL for macOS developers. #331

Closed
z-aki opened this issue Nov 22, 2020 · 18 comments
Closed

Add a note about OpenSSL for macOS developers. #331

z-aki opened this issue Nov 22, 2020 · 18 comments

Comments

@z-aki
Copy link
Contributor

z-aki commented Nov 22, 2020

Describe the bug
Since the "build after push" workflow uses this hack, it makes sense to add something that works for macOS users to the build docs.
echo "PKG_CONFIG_PATH=$(brew --prefix)/opt/[email protected]/lib/pkgconfig" >> $GITHUB_ENV

I saw that pkg_check_modules is being used for finding grpc. If CMake's modules were used, I could specify OPENSSL_ROOT_DIR and make it work.

To Reproduce
Run
cmake -DENABLE_UNIT_TESTS=OFF -DENABLE_FUNC_TESTS=OFF ../Bear/
And see

-- Looking for gRPC::grpc++ dependency
-- Checking for modules 'protobuf>=3.11;grpc++>=1.28'
--   Package 'openssl', required by 'grpc', not found
-- Looking for gRPC::grpc++ dependency -- not found

Expected behavior
Find the keg only OpenSSL using some environment variable or cmake variable.

Environment:

  • OS name: Darwin
  • OS version: 10.14
  • OS architecture: x86_64
  • Bear version: master branch
  • Bear install method: building from source
@z-aki
Copy link
Contributor Author

z-aki commented Nov 22, 2020

Now that I overcame this hurdle, and the one listed here #313, I was greeted with std::filesystem::path not available on macOS 10.14. I tried to avoid that by using gcc-10 and g++-10 as compliers. They were set properly for top level project:

cmake -C ../xccmake.cmake -DENABLE_UNIT_TESTS=OFF -DENABLE_FUNC_TESTS=OFF ../Bear/
loading initial cache file ../xccmake.cmake
-- The C compiler identification is GNU 10.2.0
-- The CXX compiler identification is GNU 10.2.0

but sub-projects are a mess:

[ 55%] Performing configure step for 'BearSource'
loading initial cache file /Users/e/Applications/Bear/build/subprojects/tmp/BearSource/BearSource-cache-Release.cmake
-- The C compiler identification is AppleClang 10.0.1.10010046
-- The CXX compiler identification is GNU 10.2.0

Creating the main project as an external project seems highly fragile to me.
Moving on with this mismatched set of compilers was set to be doomed from the start, but here are the linker errors:

linker error
[  0%] Built target grpc_dependency
[  0%] Built target googletest_dependency
[  0%] Built target nlohmann_json_dependency
[  0%] Built target fmt_dependency
[  0%] Built target spdlog_dependency
[ 11%] Performing build step for 'BearSource'
[  1%] Built target flags_a
[  3%] Built target shell_a
[ 15%] Built target sys_a
[ 30%] Built target exec_a
[ 35%] Built target supervise_a
[ 39%] Built target reporter_a
[ 41%] Building CXX object intercept/CMakeFiles/er.dir/source/report/supervisor/Application.cc.o
[ 43%] Building CXX object intercept/CMakeFiles/er.dir/source/report/supervisor/main.cc.o
[ 45%] Linking CXX executable er
Undefined symbols for architecture x86_64:
  "__ZN3fmt2v76detail7vformatB5cxx11ENS0_17basic_string_viewIcEENS0_11format_argsE", referenced from:
      __ZZ4mainENKUlRKT_E_clIN5flags9ArgumentsEEEDaS1_ in main.cc.o
      _main in main.cc.o
      __ZNK3rpc12EventFactory5startEiiRKNS_16ExecutionContextE in EventFactory.cc.o
      __ZNK3rpc12EventFactory6signalEi in EventFactory.cc.o
      __ZNK3rpc12EventFactory9terminateEi in EventFactory.cc.o
      __ZN12_GLOBAL__N_112create_errorERKN4grpc6StatusE in InterceptClient.cc.o
      __ZN12_GLOBAL__N_114format_optionsERSoRKNSt7__cxx114listISt4pairIKSt17basic_string_viewIcSt11char_traitsIcEEN5flags6OptionEESaISB_EEE in Flags.cc.o
      ...
  "__ZN4grpc13CreateChannelERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt10shared_ptrINS_18ChannelCredentialsEE", referenced from:
      __ZN3rpc15InterceptClientC1ERKNS_7SessionE in InterceptClient.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE3AddEv", referenced from:
      __ZNK3rpc12EventFactory5startEiiRKNS_16ExecutionContextE in EventFactory.cc.o
      __ZN9supervise13Event_Started14_InternalParseEPKcPN6google8protobuf8internal12ParseContextE in supervise.pb.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE5ClearEv", referenced from:
      __ZN9supervise13Event_Started5ClearEv in supervise.pb.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE9MergeFromERKS8_", referenced from:
      __ZN9supervise13Event_Started9MergeFromERKS0_ in supervise.pb.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC1EPNS0_5ArenaE", referenced from:
      __ZN9supervise13Event_StartedC1EPN6google8protobuf5ArenaE in supervise.pb.cc.o
      __ZL52InitDefaultsscc_info_Event_Started_supervise_2eprotov in supervise.pb.cc.o
      __ZN6google8protobuf5Arena18CreateMaybeMessageIN9supervise13Event_StartedEJEEEPT_PS1_DpOT0_ in supervise.pb.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC1ERKS8_", referenced from:
      __ZN9supervise13Event_StartedC1ERKS0_ in supervise.pb.cc.o
  "__ZN6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEED1Ev", referenced from:
      __ZN9supervise13Event_StartedD1Ev in supervise.pb.cc.o
  "__ZN6google8protobuf2io19EpsCopyOutputStream18WriteStringOutlineEjRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPh", referenced from:
      __ZNK6google8protobuf8internal12MapEntryImplIN9supervise39Event_Started_EnvironmentEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE18_InternalSerializeEPhPNS0_2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZNK6google8protobuf8internal12MapEntryImplIN9supervise32Environment_ValuesEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE18_InternalSerializeEPhPNS0_2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZN6google8protobuf8internal13MapEntryFuncsINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_LNS1_14WireFormatLite9FieldTypeE9ELSA_9EE17InternalSerializeEiRKS8_SD_PhPNS0_2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZNK9supervise13Event_Started18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
  "__ZN6google8protobuf2io19EpsCopyOutputStream30WriteStringMaybeAliasedOutlineEjRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPh", referenced from:
      __ZNK9supervise14ResolveRequest18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZNK9supervise15ResolveResponse18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZNK9supervise13Event_Started18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
      __ZNK9supervise5Event18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
  "__ZN6google8protobuf8internal17UnknownFieldParseEjPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKcPNS1_12ParseContextE", referenced from:
      __ZN6google8protobuf8internal12MapEntryImplIN9supervise39Event_Started_EnvironmentEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE14_InternalParseEPKcPNS1_12ParseContextE in supervise.pb.cc.o
      __ZN6google8protobuf8internal12MapEntryImplIN9supervise32Environment_ValuesEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE14_InternalParseEPKcPNS1_12ParseContextE in supervise.pb.cc.o
  "__ZN6google8protobuf8internal18EpsCopyInputStream18ReadStringFallbackEPKciPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", referenced from:
      __ZN6google8protobuf8internal12MapEntryImplIN9supervise39Event_Started_EnvironmentEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE14_InternalParseEPKcPNS1_12ParseContextE in supervise.pb.cc.o
      __ZN6google8protobuf8internal12MapEntryImplIN9supervise32Environment_ValuesEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE14_InternalParseEPKcPNS1_12ParseContextE in supervise.pb.cc.o
      __ZN6google8protobuf8internal14MapTypeHandlerILNS1_14WireFormatLite9FieldTypeE9ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE4ReadEPKcPNS1_12ParseContextEPSA_ in supervise.pb.cc.o
  "__ZN6google8protobuf8internal24InlineGreedyStringParserEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKcPNS1_12ParseContextE", referenced from:
      __ZN9supervise14ResolveRequest14_InternalParseEPKcPN6google8protobuf8internal12ParseContextE in supervise.pb.cc.o
      __ZN9supervise15ResolveResponse14_InternalParseEPKcPN6google8protobuf8internal12ParseContextE in supervise.pb.cc.o
      __ZN9supervise13Event_Started14_InternalParseEPKcPN6google8protobuf8internal12ParseContextE in supervise.pb.cc.o
      __ZN9supervise5Event14_InternalParseEPKcPN6google8protobuf8internal12ParseContextE in supervise.pb.cc.o
  "__ZN6google8protobuf8internal26fixed_address_empty_stringB5cxx11E", referenced from:
      __ZNK3rpc12EventFactory5startEiiRKNS_16ExecutionContextE in EventFactory.cc.o
      __ZNK3rpc12EventFactory6signalEi in EventFactory.cc.o
      __ZNK3rpc12EventFactory9terminateEi in EventFactory.cc.o
      __ZN3rpc15InterceptClient19get_wrapped_commandERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE in InterceptClient.cc.o
      __ZL71InitDefaultsscc_info_Environment_ValuesEntry_DoNotUse_supervise_2eprotov in supervise.pb.cc.o
      __ZL78InitDefaultsscc_info_Event_Started_EnvironmentEntry_DoNotUse_supervise_2eprotov in supervise.pb.cc.o
      __ZNK6google8protobuf8internal12MapEntryImplIN9supervise32Environment_ValuesEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EE3NewEv in supervise.pb.cc.o
      ...
  "__ZN6spdlog11set_patternENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_17pattern_time_typeE", referenced from:
      __ZZ4mainENKUlRKT_E_clIN5flags9ArgumentsEEEDaS1_ in main.cc.o
      _main in main.cc.o
  "__ZN6spdlog16stderr_logger_mtINS_19synchronous_factoryEEESt10shared_ptrINS_6loggerEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", referenced from:
      _main in main.cc.o
  "__ZN6spdlog18set_default_loggerESt10shared_ptrINS_6loggerEE", referenced from:
      _main in main.cc.o
  "__ZNK3fmt2v76detail10locale_ref3getISt6localeEET_v", referenced from:
      __ZN3fmt2v76detail5valueINS0_20basic_format_contextINS1_15buffer_appenderIcEEcEEE17format_custom_argIN12_GLOBAL__N_112PointerArrayENS1_18fallback_formatterISA_cvEEEEvPKvRNS0_26basic_format_parse_contextIcNS1_13error_handlerEEERS6_ in main.cc.o
      __ZN3fmt2v76detail5valueINS0_20basic_format_contextINS1_15buffer_appenderIcEEcEEE17format_custom_argIN5flags9ArgumentsENS1_18fallback_formatterISA_cvEEEEvPKvRNS0_26basic_format_parse_contextIcNS1_13error_handlerEEERS6_ in main.cc.o
      __ZN3fmt2v76detail5valueINS0_20basic_format_contextINS1_15buffer_appenderIcEEcEEE17format_custom_argIN12_GLOBAL__N_19ArgumentsENS1_18fallback_formatterISA_cvEEEEvPKvRNS0_26basic_format_parse_contextIcNS1_13error_handlerEEERS6_ in Process.cc.o
  "__ZNK6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE3GetEi", referenced from:
      __ZNK9supervise13Event_Started12ByteSizeLongEv in supervise.pb.cc.o
      __ZNK9supervise13Event_Started18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
  "__ZNK6google8protobuf16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE4sizeEv", referenced from:
      __ZNK9supervise13Event_Started12ByteSizeLongEv in supervise.pb.cc.o
      __ZNK9supervise13Event_Started18_InternalSerializeEPhPN6google8protobuf2io19EpsCopyOutputStreamE in supervise.pb.cc.o
  "__ZNK6google8protobuf7Message11GetTypeNameB5cxx11Ev", referenced from:
      __ZTVN9supervise14ResolveRequestE in supervise.pb.cc.o
      __ZTVN9supervise15ResolveResponseE in supervise.pb.cc.o
      __ZTVN9supervise11EnvironmentE in supervise.pb.cc.o
      __ZTVN9supervise13Event_StartedE in supervise.pb.cc.o
      __ZTVN9supervise16Event_TerminatedE in supervise.pb.cc.o
      __ZTVN9supervise15Event_SignalledE in supervise.pb.cc.o
      __ZTVN9supervise5EventE in supervise.pb.cc.o
      ...
  "__ZNK6google8protobuf7Message25InitializationErrorStringB5cxx11Ev", referenced from:
      __ZTVN6google8protobuf8internal12MapEntryImplIN9supervise32Environment_ValuesEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EEE in supervise.pb.cc.o
      __ZTVN6google8protobuf8internal8MapEntryIN9supervise32Environment_ValuesEntry_DoNotUseENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESA_LNS1_14WireFormatLite9FieldTypeE9ELSC_9ELi0EEE in supervise.pb.cc.o
      __ZTVN6google8protobuf8internal12MapEntryImplIN9supervise39Event_Started_EnvironmentEntry_DoNotUseENS0_7MessageENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESB_LNS1_14WireFormatLite9FieldTypeE9ELSD_9ELi0EEE in supervise.pb.cc.o
      __ZTVN6google8protobuf8internal8MapEntryIN9supervise39Event_Started_EnvironmentEntry_DoNotUseENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESA_LNS1_14WireFormatLite9FieldTypeE9ELSC_9ELi0EEE in supervise.pb.cc.o
      __ZTVN9supervise14ResolveRequestE in supervise.pb.cc.o
      __ZTVN9supervise15ResolveResponseE in supervise.pb.cc.o
      __ZTVN9supervise32Environment_ValuesEntry_DoNotUseE in supervise.pb.cc.o
      ...
ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[5]: *** [intercept/er] Error 1
make[4]: *** [intercept/CMakeFiles/er.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [subprojects/Stamp/BearSource/BearSource-build] Error 2
make[1]: *** [CMakeFiles/BearSource.dir/all] Error 2
make: *** [all] Error 2

@z-aki
Copy link
Contributor Author

z-aki commented Nov 22, 2020

All this because Bear 4.0 is not available on brew.

@rizsotto
Copy link
Owner

Hey @z-aki , thanks for this report.

Yeah, the sub-project might still have bugs, but it's still the best way to handle 3rd-party-dependencies (to my best knowledge and according to the book i've read on the subject)... I was only deal with the CXX compiler, because there are no C source files in the project. But that might be still used in cases when the C linking is explicitly requested. I'll update that part.

About using CMake files or PkgConfig to find gRPC: not all distro install the CMake files, but all install the PkgConfig files. (eg.: Fedora has only PkgConfig files in the package.) I'm happy to get a PR where it looks for the CMake file first and falls back to PkgConfig. :)

Yes, brew does not yet have the latest Bear. (My experience with brew got painful, specially the gRPC dependency gets broken every 3 months. I think it's still in a broken state now.) I'm happy to get PRs for this platform, since I do not own macOS machine.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 23, 2020

I have zero experience with GCC. I can probably make it work with Apple clang and LLVM clang if the std::filesystem::path restriction is removed.

@rizsotto
Copy link
Owner

Why shall the std::filesystem be removed? According to this page, those shall be available on macOS too with the Clang compiler.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 23, 2020

To clarify, std::filesystem is fine, std::filesystem::path is not. GCC works fine however. But on default installations, GCC is just an alias to Clang. I made some changes to use proper GCC via brew but Bear shouldn't be supporting some compiler installed using some package manager.(EDIT LLVMClang is an exception to that. That and AppleClang behave very similar.)

@z-aki
Copy link
Contributor Author

z-aki commented Nov 23, 2020

Since AppleClang introduced <filesystem> in Xcode 11, people using less than that will have to download llvm toolchain from either brew or compile from source. (I've done the latter.) So my changes will target those people.

LLVMClang compiles and runs code with std::filesystem::path just by adding add_compile_definitions(_LIBCPP_DISABLE_AVAILABILITY). So one problem down.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 23, 2020

Yeah, the sub-project might still have bugs, but it's still the best way to handle 3rd-party-dependencies (to my best knowledge and according to the book i've read on the subject)

Yes, but only for third party projects. For the main project (Bear), I'm having a difficult time adding (experimenting with -stdlib=libc++) /removing (labsl_dynamic_annotations) linker flags, adding definitions _LIBCPP_DISABLE_AVAILABILITY , using generators other than make or ninja since the ExternalProject_Add does the last part opaquely in some sub-directory.

I hope it would be welcome if we trade-off the ease of a single ExternalProject_Add call with a more flexible and configurable Cmake script.

@rizsotto
Copy link
Owner

I'm not sure if the external project is the biggest enemy in this build. :)

What is the pain point to add/remove flags in an external project?

@z-aki
Copy link
Contributor Author

z-aki commented Nov 24, 2020

What is the pain point to add/remove flags in an external project?

I didn't realise that I had to add flags, definitions in the source/CMakeLists.txt file, not the top level one.

I'm not sure if the external project is the biggest enemy in this build. :)

  • I like to work with Xcode generator and external project configures BearProject in some folder down there not quickly available to me. So in the Xcode project all I see is Cmake files.
  • Since that configuration happens as an Xcode build step, I cannot set environment variables easily.

In the ideal world, Cmake configures once, and then we get straight to the C++ code.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 24, 2020

https://pasteall.org/b1O2/slim This is what got me over all the linking errors. Though I admit I had to issue a brew switch abseil 20200225.2 to avoid the -labsl_dynamic_annotations issue. Now when I launch bear from its custom install directory, it says

$ ../install/bin/bear --
/bin/sh: /bin/intercept: No such file or directory
/bin/sh: /bin/citnames: No such file or directory
$

Do you happen to know why ?

@rizsotto
Copy link
Owner

add_dependencies(
    bear

There you need to list all targets (not only bear, but intercept, wrapper and citnames too).

And also look for the source/config.h.in that contains the path where these binaries will be installed. (In your case it's /bin, but it's suppose to be /usr/local/bin, unless specified otherwise).

@rizsotto
Copy link
Owner

@z-aki what is the trick to downgrade the abseil dependency? Can you pass what command to run for that? (I would like to see the build passing on CI again.)

@rizsotto
Copy link
Owner

About the external project... I'm not using XCode, but CLion. And instead of opening the project CMakeList.txt I open the source/CMakeList.txt as a project, and it works like a charm. :)

If you can't have all dependencies from packages, but the parent project has to build it, then you need to pass a few flags in the settings.

I am not saying this is ideal, but might help to work with the current CMake setup.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 24, 2020

brew switch abseil 20200225.2

If that doesn't work right away, download the abseil tarball from an old brew formula (ruby file of abseil) and put it in Cellar/abseil/ and run the switch again.

I think better fix would be to remove the link flag using Cmake if that library is now merged in some other flag.

I decided to drop the idea of removing subproject for Bear reluctantly. It's a bigger change, connected with tests and stuff. Here's a probable filesystem fix: https://pasteall.org/UHVa/slim I'll open a PR once I test a few things.

@z-aki
Copy link
Contributor Author

z-aki commented Nov 24, 2020

About the external project... I'm not using XCode, but CLion. And instead of opening the project CMakeList.txt I open the source/CMakeList.txt as a project, and it works like a charm. :)

Hmm, didn't think of that. Thanks. Changing the source dir is better. I get some false positives by clangd about missing headers, but it's better than nothing.

CC=clang CXX=clang++ cmake ../Bear/source/ -DCMAKE_INSTALL_PREFIX=/Users/t/Applications/Bear/install \
-DROOT_INSTALL_PREFIX=/Users/t/Applications/Bear/install -DCMAKE_CXX_STANDARD=17 \
-DCMAKE_PROJECT_VERSION=3.0.3 -G "Sublime Text 2 - Ninja" -DCMAKE_EXPORT_COMPILE_COMMANDS=ON

Anyway, pull request here: #334

@rizsotto
Copy link
Owner

Thanks @z-aki for your time and efforts. I did the rewrite (of Bear) mostly to satisfy macOS users. (The concept of using compiler wrappers were to address the macOS static make command problem and workaround SIP limitations.)

To my best understanding the current problems with this platform are:

  • That Brew grpc package is broken (which I've run into on the CI). Solution for this can be just waiting while it got fixed. :)
    • I've tried to lean into it, but it's hard to know what needs to be done.
  • And std::filesystem::path is not available on older versions. Solutions for this can be...
    • Not use std::filesystem::path type. Which way I have to implement if for all platforms.
    • Use newer compilers which have support. (This is what you've done. I think it specific to certain versions of macOS, and the workaround should be in the packaging repo.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants