Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

app.deployment_target not properly propagated to the pods xcodebuild #33

Closed
lrz opened this Issue · 4 comments

1 participant

@lrz
Owner

It seems that setting a value for app.deployment_target in the project's Rakefile does not have any impact on the pod dependencies build, as -mios-simulator-version-min=X is passed to the compiler where X is the SDK version.

This is an important problem that should be fixed as soon as possible since it impacts all RubyMotion developers using CocoaPods dependencies + Xcode 4.5 + targeting iOS releases below 6.0.

@lrz
Owner

Could be a bug in CocoaPods itself, as motion-cocoapods properly set the deployment target.

https://github.com/HipByte/motion-cocoapods/blob/master/lib/motion/project/cocoapods.rb#L60

@lrz
Owner

In the meantime, the following patch on /Library/RubyMotion/lib/motion/project/vendor.rb seems to work:

diff --git a/lib/motion/project/vendor.rb b/lib/motion/project/vendor.rb
index 1381816..829f5de 100644
--- a/lib/motion/project/vendor.rb
+++ b/lib/motion/project/vendor.rb
@@ -159,7 +159,7 @@ EOS
           xcopts = ''
           xcopts << "-target \"#{target}\" " if target
           xcopts << "-scheme \"#{scheme}\" " if scheme
-          sh "/usr/bin/xcodebuild -project \"#{xcodeproj}\" #{xcopts} -configuration \"#{configuration}\" -sdk #{platform.downcase}#{@config.sdk_version} #{@config.arch_flags(platform)} CONFIGURATION_BUILD_DIR=build build"
+          sh "/usr/bin/xcodebuild -project \"#{xcodeproj}\" #{xcopts} -configuration \"#{configuration}\" -sdk #{platform.downcase}#{@config.sdk_version} #{@config.arch_flags(platform)} CONFIGURATION_BUILD_DIR=build IPHONEOS_DEPLOYMENT_TARGET=#{@config.deployment_target} build"

           # Copy .a files into the platform build directory.
           prods = opts.delete(:products)
@lrz
Owner

Got confirmation that the fix works, so we will do a quick software update tomorrow.

@lrz
Owner

1.25 is released with the fix.

@lrz lrz closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.