Skip to content
Browse files

Added configuration option to specify architectures. (Without specify…

…ing xcodebuild was assuming armv7 even though the project settings specified otherwise)
  • Loading branch information...
1 parent 4c110c1 commit ce4a7c1797429cb509eeda3db5afaf401d502a69 @subdigital subdigital committed Sep 1, 2011
Showing with 10 additions and 5 deletions.
  1. +10 −5 lib/beta_builder.rb
View
15 lib/beta_builder.rb
@@ -18,6 +18,7 @@ def initialize(namespace = :beta, &block)
:workspace_path => nil,
:scheme => nil,
:app_name => nil,
+ :arch => nil,
:xcode4_archive_mode => false,
:skip_clean => false,
:verbose => false,
@@ -27,28 +28,32 @@ def initialize(namespace = :beta, &block)
yield @configuration if block_given?
define
end
-
+
def xcodebuild(*args)
# we're using tee as we still want to see our build output on screen
system("#{@configuration.xcodebuild_path} #{args.join(" ")} | tee build.output")
end
-
+
class Configuration < OpenStruct
def release_notes_text
return release_notes.call if release_notes.is_a? Proc
release_notes
end
def build_arguments
+ args = ""
if workspace_path
raise "A scheme is required if building from a workspace" unless scheme
- "-workspace '#{workspace_path}' -scheme '#{scheme}' -configuration '#{configuration}'"
+ args << "-workspace '#{workspace_path}' -scheme '#{scheme}' -configuration '#{configuration}'"
else
args = "-target '#{target}' -configuration '#{configuration}' -sdk iphoneos"
args << " -project #{project_file_path}" if project_file_path
- args
end
+
+ args << " -arch \"#{arch}\"" unless arch.nil?
+
+ args
end
-
+
def archive_name
app_name || target
end

0 comments on commit ce4a7c1

Please sign in to comment.
Something went wrong with that request. Please try again.