|
1 | 1 | require "json"
|
2 |
| -require_relative './scripts/audioapi_utils' |
3 | 2 |
|
4 | 3 | package_json = JSON.parse(File.read(File.join(__dir__, "package.json")))
|
5 | 4 |
|
6 |
| -$config = find_config() |
7 |
| -assert_minimal_react_native_version($config) |
8 | 5 | $new_arch_enabled = ENV['RCT_NEW_ARCH_ENABLED'] == '1'
|
9 | 6 |
|
10 |
| -folly_flags = "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32 -DREACT_NATIVE_MINOR_VERSION=#{$config[:react_native_minor_version]}" |
| 7 | +folly_flags = "-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32" |
11 | 8 | fabric_flags = $new_arch_enabled ? '-DRCT_NEW_ARCH_ENABLED' : ''
|
12 | 9 | version_flag = "-DAUDIOAPI_VERSION=#{package_json['version']}"
|
13 | 10 |
|
@@ -36,28 +33,13 @@ Pod::Spec.new do |s|
|
36 | 33 |
|
37 | 34 | s.ios.frameworks = 'CoreFoundation', 'CoreAudio', 'AudioToolbox', 'Accelerate'
|
38 | 35 |
|
39 |
| - s.pod_target_xcconfig = { |
| 36 | + s.compiler_flags = "#{folly_flags}" |
| 37 | + |
| 38 | + s.pod_target_xcconfig = { |
40 | 39 | "USE_HEADERMAP" => "YES",
|
41 |
| - "DEFINES_MODULE" => "YES", |
42 |
| - "HEADER_SEARCH_PATHS" => '"$(PODS_TARGET_SRCROOT)/ReactCommon" "$(PODS_TARGET_SRCROOT)" "$(PODS_ROOT)/RCT-Folly" "$(PODS_ROOT)/boost" "$(PODS_ROOT)/boost-for-react-native" "$(PODS_ROOT)/DoubleConversion" "$(PODS_ROOT)/Headers/Private/React-Core" "$(PODS_ROOT)/Headers/Private/Yoga"', |
43 |
| - "FRAMEWORK_SEARCH_PATHS" => '"${PODS_CONFIGURATION_BUILD_DIR}/React-hermes"', |
44 | 40 | "CLANG_CXX_LANGUAGE_STANDARD" => "c++20",
|
45 | 41 | "GCC_PREPROCESSOR_DEFINITIONS" => '$(inherited) HAVE_ACCELERATE=1',
|
46 |
| - } |
47 |
| - s.compiler_flags = "#{folly_flags}" |
48 |
| - |
49 |
| - s.xcconfig = { |
50 |
| - "HEADER_SEARCH_PATHS" => [ |
51 |
| - '"$(PODS_ROOT)/boost"', |
52 |
| - '"$(PODS_ROOT)/boost-for-react-native"', |
53 |
| - '"$(PODS_ROOT)/glog"', |
54 |
| - '"$(PODS_ROOT)/RCT-Folly"', |
55 |
| - '"$(PODS_ROOT)/Headers/Public/React-hermes"', |
56 |
| - '"$(PODS_ROOT)/Headers/Public/hermes-engine"', |
57 |
| - "\"$(PODS_ROOT)/#{$config[:react_native_common_dir]}\"", |
58 |
| - "\"$(PODS_ROOT)/#{$config[:react_native_audioapi_dir_from_pods_root]}/ios/audioapi/ios\"", |
59 |
| - "\"$(PODS_ROOT)/#{$config[:react_native_audioapi_dir_from_pods_root]}/common/cpp/audioapi\"", |
60 |
| - ].join(' '), |
| 42 | + "HEADER_SEARCH_PATHS" => "\"$(PODS_TARGET_SRCROOT)/common/cpp\" \"$(PODS_TARGET_SRCROOT)/ios\"", |
61 | 43 | 'OTHER_CFLAGS' => "$(inherited) #{folly_flags} #{fabric_flags} #{version_flag}"
|
62 | 44 | }
|
63 | 45 |
|
|
0 commit comments