Skip to content

Commit

Permalink
Merge pull request #12009 from marcuswu0814/master
Browse files Browse the repository at this point in the history
  • Loading branch information
justinseanmartin committed Jul 30, 2023
2 parents 400f290 + 032ce36 commit 53893a2
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 7 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
* Use safe_load during custom YAML config loading.
[Dimitris Koutsogiorgas](https://github.com/dnkoutso)
[#11974](https://github.com/CocoaPods/CocoaPods/pull/11974)

* Xcode 15 fix: Replace `DT_TOOLCHAIN_DIR` with `TOOLCHAIN_DIR` when generating script.
[Marcus Wu](https://github.com/marcuswu0814)
[#12009](https://github.com/CocoaPods/CocoaPods/pull/12009)

## 1.12.1 (2023-04-18)

Expand Down
2 changes: 1 addition & 1 deletion lib/cocoapods/generator/embed_frameworks_script.rb
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def script
mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
COCOAPODS_PARALLEL_CODE_SIGN="${COCOAPODS_PARALLEL_CODE_SIGN:-false}"
SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"
SWIFT_STDLIB_PATH="${TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"
BCSYMBOLMAP_DIR="BCSymbolMaps"
Expand Down
4 changes: 2 additions & 2 deletions lib/cocoapods/target/build_settings.rb
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ def _ld_runpath_search_paths(requires_host_target: false, test_bundle: false, us
else
"'@loader_path/Frameworks'"
end
paths << '${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}' if uses_swift
paths << '${TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}' if uses_swift
else
paths << "'@executable_path/Frameworks'"
paths << "'@loader_path/Frameworks'"
Expand Down Expand Up @@ -866,7 +866,7 @@ def linker_names_from_libraries(libraries)
search_paths = vendored_static_library_search_paths + vendored_dynamic_library_search_paths
if target.uses_swift? || other_swift_flags_without_swift?
search_paths << '/usr/lib/swift'
search_paths << '${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}'
search_paths << '${TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}'
search_paths << '$(PLATFORM_DIR)/Developer/Library/Frameworks' if test_xcconfig?
end
return search_paths if target.build_as_framework? || !target.should_build?
Expand Down
2 changes: 1 addition & 1 deletion spec/cocoapods-integration-specs
Submodule cocoapods-integration-specs updated 96 files
+1 −1 install_custom_module_map/after/Pods/Target Support Files/Pods-Example/Pods-Example-frameworks.sh
+1 −1 install_custom_module_name/after/Pods/Target Support Files/Pods-Example/Pods-Example-frameworks.sh
+1 −1 ...l_framework_inhibiting_warnings/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp-frameworks.sh
+1 −1 install_framework_resources/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp-frameworks.sh
+1 −1 ...l_header_mappings_dir/after/Pods/Target Support Files/Pods-OtherSampleApp/Pods-OtherSampleApp-frameworks.sh
+1 −1 ...er_mappings_dir_macos/after/Pods/Target Support Files/Pods-OtherSampleApp/Pods-OtherSampleApp-frameworks.sh
+1 −1 install_inhibiting_warnings/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib-App-frameworks.sh
+1 −1 ...ll_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib-AppWithDep-frameworks.sh
+1 −1 ...ltiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib-Unit-UnitTests3-frameworks.sh
+1 −1 ...ltiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib-Unit-UnitTests4-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.app.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.app.release.xcconfig
+1 −1 ...l_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.appwithdep.debug.xcconfig
+1 −1 ...multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.appwithdep.release.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.release.xcconfig
+1 −1 ...tiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests3.debug.xcconfig
+1 −1 ...ple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests3.release.xcconfig
+1 −1 ...tiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests4.debug.xcconfig
+1 −1 ...ple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests4.release.xcconfig
+1 −1 ...tiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests5.debug.xcconfig
+1 −1 ...ple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests5.release.xcconfig
+1 −1 ...tiple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests6.debug.xcconfig
+1 −1 ...ple_test_specs/after/Pods/Target Support Files/HostedTestLib/HostedTestLib.unit-unittests6.release.xcconfig
+1 −1 ...s/after/Pods/Target Support Files/Pods-InstallMultipleTestSpecs/Pods-InstallMultipleTestSpecs-frameworks.sh
+1 −1 .../after/Pods/Target Support Files/Pods-InstallMultipleTestSpecs/Pods-InstallMultipleTestSpecs.debug.xcconfig
+1 −1 ...fter/Pods/Target Support Files/Pods-InstallMultipleTestSpecs/Pods-InstallMultipleTestSpecs.release.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/Pods-Other/Pods-Other-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib-App-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib-Unit-UnitTests1-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib-Unit-UnitTests2-frameworks.sh
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.app.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.app.release.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.release.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.unit-unittests1.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.unit-unittests1.release.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.unit-unittests2.debug.xcconfig
+1 −1 install_multiple_test_specs/after/Pods/Target Support Files/TestLib/TestLib.unit-unittests2.release.xcconfig
+1 −1 install_search_paths_inheritance/after/Pods/Target Support Files/Pods-App/Pods-App-frameworks.sh
+1 −1 install_search_paths_inheritance/after/Pods/Target Support Files/Pods-Test/Pods-Test-frameworks.sh
+1 −1 ...et Support Files/CustomModuleMapPod-framework-iOS/CustomModuleMapPod-framework-iOS-Unit-Tests-frameworks.sh
+1 −1 ...upport Files/CustomModuleMapPod-framework-macOS/CustomModuleMapPod-framework-macOS-Unit-Tests-frameworks.sh
+1 −1 ...ules/after/Pods/Target Support Files/MixedPod-framework-iOS/MixedPod-framework-iOS-Unit-Tests-frameworks.sh
+1 −1 ..._swift_modules/after/Pods/Target Support Files/MixedPod-framework-iOS/MixedPod-framework-iOS.debug.xcconfig
+1 −1 ...wift_modules/after/Pods/Target Support Files/MixedPod-framework-iOS/MixedPod-framework-iOS.release.xcconfig
+1 −1 ...les/after/Pods/Target Support Files/MixedPod-framework-iOS/MixedPod-framework-iOS.unit-tests.debug.xcconfig
+1 −1 ...s/after/Pods/Target Support Files/MixedPod-framework-iOS/MixedPod-framework-iOS.unit-tests.release.xcconfig
+1 −1 .../after/Pods/Target Support Files/MixedPod-framework-macOS/MixedPod-framework-macOS-Unit-Tests-frameworks.sh
+1 −1 ...ft_modules/after/Pods/Target Support Files/MixedPod-framework-macOS/MixedPod-framework-macOS.debug.xcconfig
+1 −1 ..._modules/after/Pods/Target Support Files/MixedPod-framework-macOS/MixedPod-framework-macOS.release.xcconfig
+2 −2 ...after/Pods/Target Support Files/MixedPod-framework-macOS/MixedPod-framework-macOS.unit-tests.debug.xcconfig
+2 −2 ...ter/Pods/Target Support Files/MixedPod-framework-macOS/MixedPod-framework-macOS.unit-tests.release.xcconfig
+1 −1 ...modules/after/Pods/Target Support Files/MixedPod-library-iOS/MixedPod-library-iOS.unit-tests.debug.xcconfig
+1 −1 ...dules/after/Pods/Target Support Files/MixedPod-library-iOS/MixedPod-library-iOS.unit-tests.release.xcconfig
+2 −2 ...les/after/Pods/Target Support Files/MixedPod-library-macOS/MixedPod-library-macOS.unit-tests.debug.xcconfig
+2 −2 ...s/after/Pods/Target Support Files/MixedPod-library-macOS/MixedPod-library-macOS.unit-tests.release.xcconfig
+1 −1 ...odules/after/Pods/Target Support Files/ObjCPod-framework-iOS/ObjCPod-framework-iOS-Unit-Tests-frameworks.sh
+1 −1 ...es/after/Pods/Target Support Files/ObjCPod-framework-macOS/ObjCPod-framework-macOS-Unit-Tests-frameworks.sh
+1 −1 ...get Support Files/Pods-Abstract Target-iOS Pods-Dynamic/Pods-Abstract Target-iOS Pods-Dynamic-frameworks.sh
+1 −1 ...et Support Files/Pods-Abstract Target-iOS Pods-Dynamic/Pods-Abstract Target-iOS Pods-Dynamic.debug.xcconfig
+1 −1 ... Support Files/Pods-Abstract Target-iOS Pods-Dynamic/Pods-Abstract Target-iOS Pods-Dynamic.release.xcconfig
+1 −1 ...rget Support Files/Pods-Abstract Target-iOS Pods-Static/Pods-Abstract Target-iOS Pods-Static.debug.xcconfig
+1 −1 ...et Support Files/Pods-Abstract Target-iOS Pods-Static/Pods-Abstract Target-iOS Pods-Static.release.xcconfig
+1 −1 ...Support Files/Pods-Abstract Target-macOS Pods-Dynamic/Pods-Abstract Target-macOS Pods-Dynamic-frameworks.sh
+2 −2 ...upport Files/Pods-Abstract Target-macOS Pods-Dynamic/Pods-Abstract Target-macOS Pods-Dynamic.debug.xcconfig
+2 −2 ...port Files/Pods-Abstract Target-macOS Pods-Dynamic/Pods-Abstract Target-macOS Pods-Dynamic.release.xcconfig
+1 −1 ... Support Files/Pods-Abstract Target-macOS Pods-Static/Pods-Abstract Target-macOS Pods-Static.debug.xcconfig
+1 −1 ...upport Files/Pods-Abstract Target-macOS Pods-Static/Pods-Abstract Target-macOS Pods-Static.release.xcconfig
+1 −1 ...ules/after/Pods/Target Support Files/SwiftPod-framework-iOS/SwiftPod-framework-iOS-Unit-Tests-frameworks.sh
+1 −1 ..._swift_modules/after/Pods/Target Support Files/SwiftPod-framework-iOS/SwiftPod-framework-iOS.debug.xcconfig
+1 −1 ...wift_modules/after/Pods/Target Support Files/SwiftPod-framework-iOS/SwiftPod-framework-iOS.release.xcconfig
+1 −1 ...les/after/Pods/Target Support Files/SwiftPod-framework-iOS/SwiftPod-framework-iOS.unit-tests.debug.xcconfig
+1 −1 ...s/after/Pods/Target Support Files/SwiftPod-framework-iOS/SwiftPod-framework-iOS.unit-tests.release.xcconfig
+1 −1 .../after/Pods/Target Support Files/SwiftPod-framework-macOS/SwiftPod-framework-macOS-Unit-Tests-frameworks.sh
+1 −1 ...ft_modules/after/Pods/Target Support Files/SwiftPod-framework-macOS/SwiftPod-framework-macOS.debug.xcconfig
+1 −1 ..._modules/after/Pods/Target Support Files/SwiftPod-framework-macOS/SwiftPod-framework-macOS.release.xcconfig
+2 −2 ...after/Pods/Target Support Files/SwiftPod-framework-macOS/SwiftPod-framework-macOS.unit-tests.debug.xcconfig
+2 −2 ...ter/Pods/Target Support Files/SwiftPod-framework-macOS/SwiftPod-framework-macOS.unit-tests.release.xcconfig
+1 −1 ...modules/after/Pods/Target Support Files/SwiftPod-library-iOS/SwiftPod-library-iOS.unit-tests.debug.xcconfig
+1 −1 ...dules/after/Pods/Target Support Files/SwiftPod-library-iOS/SwiftPod-library-iOS.unit-tests.release.xcconfig
+2 −2 ...les/after/Pods/Target Support Files/SwiftPod-library-macOS/SwiftPod-library-macOS.unit-tests.debug.xcconfig
+2 −2 ...s/after/Pods/Target Support Files/SwiftPod-library-macOS/SwiftPod-library-macOS.unit-tests.release.xcconfig
+1 −1 install_subspecs/after/Pods/Target Support Files/Pods-OS X App/Pods-OS X App-frameworks.sh
+1 −1 install_vendored_dynamic_framework/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp-frameworks.sh
+1 −1 ...all_vendored_dynamic_framework/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp.debug.xcconfig
+1 −1 ...l_vendored_dynamic_framework/after/Pods/Target Support Files/Pods-SampleApp/Pods-SampleApp.release.xcconfig
+1 −1 install_vendored_dynamic_framework/after/Pods/Target Support Files/RealmSwift/RealmSwift.debug.xcconfig
+1 −1 install_vendored_dynamic_framework/after/Pods/Target Support Files/RealmSwift/RealmSwift.release.xcconfig
+1 −1 ...red_static_library_xcframework/after/Pods/Target Support Files/BananaLib/BananaLib-Unit-Tests-frameworks.sh
+1 −1 ...ework/after/Pods/Target Support Files/Pods-XCFrameworkIntegration/Pods-XCFrameworkIntegration-frameworks.sh
+1 −1 ...ll_vendored_static_xcframework/after/Pods/Target Support Files/BananaLib/BananaLib-Unit-Tests-frameworks.sh
+1 −1 ...ework/after/Pods/Target Support Files/Pods-XCFrameworkIntegration/Pods-XCFrameworkIntegration-frameworks.sh
+1 −1 install_vendored_xcframework/after/Pods/Target Support Files/BananaLib/BananaLib-Unit-Tests-frameworks.sh
+1 −1 ...ework/after/Pods/Target Support Files/Pods-XCFrameworkIntegration/Pods-XCFrameworkIntegration-frameworks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -432,15 +432,15 @@ def pod_target(spec, target_definition)
mock_user_target = mock('usertarget')
mock_user_target.stubs(:symbol_type).returns(:unit_test_bundle)
@target.stubs(:user_targets).returns([mock_user_target])
@generator.generate.to_hash['LD_RUNPATH_SEARCH_PATHS'].should == %q[$(inherited) /usr/lib/swift "$(PLATFORM_DIR)/Developer/Library/Frameworks" '@executable_path/../Frameworks' '@loader_path/../Frameworks' "${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"]
@generator.generate.to_hash['LD_RUNPATH_SEARCH_PATHS'].should == %q[$(inherited) /usr/lib/swift "$(PLATFORM_DIR)/Developer/Library/Frameworks" '@executable_path/../Frameworks' '@loader_path/../Frameworks' "${TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"]
end

it 'includes correct default runpath search path list for OSX application user target' do
@target.stubs(:platform).returns(Platform.new(:osx, '10.10'))
mock_user_target = mock('usertarget')
mock_user_target.stubs(:symbol_type).returns(:application)
@target.stubs(:user_targets).returns([mock_user_target])
@generator.generate.to_hash['LD_RUNPATH_SEARCH_PATHS'].should == %q[$(inherited) /usr/lib/swift '@executable_path/../Frameworks' '@loader_path/Frameworks' "${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"]
@generator.generate.to_hash['LD_RUNPATH_SEARCH_PATHS'].should == %q[$(inherited) /usr/lib/swift '@executable_path/../Frameworks' '@loader_path/Frameworks' "${TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"]
end

it 'uses the target definition swift version' do
Expand Down

0 comments on commit 53893a2

Please sign in to comment.