Commit f3d66709 authored by Fabio Pelosin's avatar Fabio Pelosin

[TargetInstaller] Set the architecture in the user build configurations.

parent 6e7f9a5c
...@@ -12,21 +12,25 @@ To install or update CocoaPods see this [guide](http://docs.cocoapods.org/guides ...@@ -12,21 +12,25 @@ To install or update CocoaPods see this [guide](http://docs.cocoapods.org/guides
[Adam Sharp](https://github.com/sharplet) [Adam Sharp](https://github.com/sharplet)
[Core#30](https://github.com/CocoaPods/Core/pull/30) [Core#30](https://github.com/CocoaPods/Core/pull/30)
###### Bug Fixes ###### Bug Fixes
* The architecture is now set in the build settings of the user build
configurations.
[Fabio Pelosin](https://github.com/irrationalfab)
[#1450](https://github.com/CocoaPods/CocoaPods/issues/1462)
[#1462](https://github.com/CocoaPods/CocoaPods/issues/1462)
* Fixed a crash related to CocoaPods being unable to resolve an unique build * Fixed a crash related to CocoaPods being unable to resolve an unique build
setting of an user target with custom build configurations. setting of an user target with custom build configurations.
[Fabio Pelosin](https://github.com/irrationalfab) [Fabio Pelosin](https://github.com/irrationalfab)
[#1462](https://github.com/CocoaPods/CocoaPods/issues/1462) [#1462](https://github.com/CocoaPods/CocoaPods/issues/1462)
[#1463](https://github.com/CocoaPods/CocoaPods/issues/1463) [#1463](https://github.com/CocoaPods/CocoaPods/issues/1463)
[#1457](https://github.com/CocoaPods/CocoaPods/issues/1457) [#1457](https://github.com/CocoaPods/CocoaPods/issues/1457)
* Fixed a defect which prevented subspecs from being dependant on a pod with a * Fixed a defect which prevented subspecs from being dependant on a pod with a
name closely matching the name of one of the subspec's parents. name closely matching the name of one of the subspec's parents.
[Noah McCann](https://github.com/nmccann) [Noah McCann](https://github.com/nmccann)
[#29](https://github.com/CocoaPods/Core/pull/29) [#29](https://github.com/CocoaPods/Core/pull/29)
## 0.26.2 ## 0.26.2
......
...@@ -17,7 +17,7 @@ GIT ...@@ -17,7 +17,7 @@ GIT
GIT GIT
remote: https://github.com/CocoaPods/Xcodeproj.git remote: https://github.com/CocoaPods/Xcodeproj.git
revision: 3389c15ec19e3660c7801bbc78d28caa21761f5b revision: 137c22774ca770e112fb8eeb2f10473db7587d16
branch: master branch: master
specs: specs:
xcodeproj (0.13.1) xcodeproj (0.13.1)
......
...@@ -43,18 +43,18 @@ module Pod ...@@ -43,18 +43,18 @@ module Pod
deployment_target = library.platform.deployment_target.to_s deployment_target = library.platform.deployment_target.to_s
@target = project.new_target(:static_library, name, platform, deployment_target) @target = project.new_target(:static_library, name, platform, deployment_target)
library.user_build_configurations.each do |bc_name, type|
configuration = @target.add_build_configuration(bc_name, type)
end
settings = {} settings = {}
if library.archs if library.archs
settings['ARCHS'] = library.archs settings['ARCHS'] = library.archs
else
settings.delete('ARCHS')
end end
@target.build_settings('Debug').merge!(settings) @target.build_configurations.each do |configuration|
@target.build_settings('Release').merge!(settings) configuration.build_settings.merge!(settings)
library.user_build_configurations.each do |bc_name, type|
@target.add_build_configuration(bc_name, type)
end end
library.target = @target library.target = @target
......
Subproject commit ecb441780888f49aa769bc93edade2e9683ecacf Subproject commit ea4f2366f53ed7e379b0bf04bb6690ac4676f350
...@@ -16,7 +16,7 @@ module Pod ...@@ -16,7 +16,7 @@ module Pod
@spec = fixture_spec('banana-lib/BananaLib.podspec') @spec = fixture_spec('banana-lib/BananaLib.podspec')
file_accessor = Sandbox::FileAccessor.new(path_list, @spec.consumer(:ios)) file_accessor = Sandbox::FileAccessor.new(path_list, @spec.consumer(:ios))
@project.add_pod_group('BananaLib', fixture('banana-lib')) @project.add_pod_group('BananaLib', fixture('banana-lib'))
group = @project.group_for_spec('BananaLib', :source_files) group = @project.group_for_spec('BananaLib')
file_accessor.source_files.each do |file| file_accessor.source_files.each do |file|
@project.add_file_reference(file, group) @project.add_file_reference(file, group)
end end
...@@ -29,5 +29,16 @@ module Pod ...@@ -29,5 +29,16 @@ module Pod
@installer = Installer::TargetInstaller.new(config.sandbox, @pod_target) @installer = Installer::TargetInstaller.new(config.sandbox, @pod_target)
end end
it "Adds the architectures to the custom build configurations of the user target" do
@pod_target.archs = "$(ARCHS_STANDARD_64_BIT)"
@installer.send(:add_target)
@installer.send(:target).resolved_build_setting('ARCHS').should == {
"Release"=>"$(ARCHS_STANDARD_64_BIT)",
"Debug"=>"$(ARCHS_STANDARD_64_BIT)",
"AppStore"=>"$(ARCHS_STANDARD_64_BIT)",
"Test"=>"$(ARCHS_STANDARD_64_BIT)"
}
end
end end
end end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment