From a89ee3dee185c25cdb1ec84cf6012705a0f7666b Mon Sep 17 00:00:00 2001 From: Wez Furlong Date: Thu, 21 Mar 2019 15:37:16 -0700 Subject: [PATCH] fbcode_builder: teach it to build folly on macos Summary: This diff expands fbcode_builder so that it can optionally spawn a macos lego job to run a build. I've pulled in the macOS third party dependencies used by the watchman and eden builds to support this. Longer term I want to move to a more granular solution for the third party deps. Medium term we can move the logic for managing these deps to somewhere more central than just the watchman code. In the linux flavor of fbcode builder, the setup step is responsible for installing system packages, so I've inserted the LFS download of the macOS deps into that stage. In order for those macOS deps to be picked up without modifying the folly cmake we need to adjust the environment so this diff also inserts that logic at the top of each generated sandcastle step. A similar technique could potentially be used for windows builds, but note that fbcode_builder makes some assumptions about linux and requires that bash be available. Cygwin vs. native paths passed through the environment may be a real concern. That is something for a follow up diff. Reviewed By: simpkins Differential Revision: D14514601 fbshipit-source-id: c2882f45aa4b910b5e65ce6b246c750d20ca2948 --- build/fbcode_builder/specs/gmock.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/build/fbcode_builder/specs/gmock.py b/build/fbcode_builder/specs/gmock.py index 78c351b30..8b0562f7e 100644 --- a/build/fbcode_builder/specs/gmock.py +++ b/build/fbcode_builder/specs/gmock.py @@ -10,7 +10,11 @@ def fbcode_builder_spec(builder): builder.add_option('google/googletest:git_hash', 'release-1.8.1') builder.add_option( 'google/googletest:cmake_defines', - {'BUILD_GTEST': 'ON'} + { + 'BUILD_GTEST': 'ON', + # Avoid problems with MACOSX_RPATH + 'BUILD_SHARED_LIBS': 'OFF', + } ) return { 'steps': [