Compile with `-isysroot $(xcrun --sdk-path) when building on MacOS
ClosedPublic

Authored by arichardson on Aug 28 2018, 11:20 AM.

Details

Summary

Otherwise /usr/local/include is searched for headers before /usr/include
but /usr/lib is searched for libraries before /usr/local/lib.
This can cause highly confusing errors when building and should prevent
building against homebrew-provided headers instead of the system ones.

See also https://langui.sh/2015/07/24/osx-clang-include-lib-search-paths/

Test Plan

sucessfully built kate+deps on MacOS (failed before)

Diff Detail

Repository
R138 Craft
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
arichardson requested review of this revision.Aug 28 2018, 11:20 AM
arichardson created this revision.
arichardson added a reviewer: Craft.
vonreth accepted this revision.Sep 3 2018, 5:21 PM
This revision is now accepted and ready to land.Sep 3 2018, 5:21 PM
This revision was automatically updated to reflect the committed changes.