From ab8dbdf66363f3d65f0dfbcc4ec7c71b1cd69b2a Mon Sep 17 00:00:00 2001 From: Kai Dederichs Date: Wed, 8 Sep 2021 16:26:58 -0700 Subject: [PATCH] Disable gflags include (#28451) Summary: Fixes the issue explained in https://github.com/facebook/react-native/issues/28446 It basically disabled the gflags include before configure can detect the header on the users system. ## Changelog [iOS] [Fixed] - Fixed inability to build apps when gflags is installed Pull Request resolved: https://github.com/facebook/react-native/pull/28451 Test Plan: Tested by installing gflags `brew install gflags` and verifying that apps build after. Reviewed By: javache Differential Revision: D30345352 Pulled By: sota000 fbshipit-source-id: 04c98d7ddebe6708057407c4b4bf3701434822a3 --- scripts/ios-configure-glog.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/ios-configure-glog.sh b/scripts/ios-configure-glog.sh index dd79583976ba36..e30fa2ea2e156e 100755 --- a/scripts/ios-configure-glog.sh +++ b/scripts/ios-configure-glog.sh @@ -28,6 +28,10 @@ if [ -h "test-driver" ]; then rm test-driver fi +# Manually disable gflags include to fix issue https://github.com/facebook/react-native/issues/28446 +sed -i '' 's/\@ac_cv_have_libgflags\@/0/' src/glog/logging.h.in +sed -i '' 's/HAVE_LIB_GFLAGS/HAVE_LIB_GFLAGS_DISABLED/' src/config.h.in + ./configure --host arm-apple-darwin cat << EOF >> src/config.h