nixenvironment 0.0.104 → 0.0.105
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/nixenvironment +17 -5
- data/lib/nixenvironment/version.rb +1 -1
- data/lib/nixenvironment/xcodebuild.rb +2 -6
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 82d6d44bb8dc0c0ec99fb0a51d04201423dbf908
|
4
|
+
data.tar.gz: ca297587fa3cb40462014a1b24dbfc41f4feaa83
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e03e37c6af2d9e5b26df8423d461d8297eeab0bbf0295dd9cf16436129b34e410a9c6fd73bf7f9f18aefba2b4be336c17630985bf22872d77f2c5b20e3891e5f
|
7
|
+
data.tar.gz: f42c618fd17f5317ac783fd769f07a0e852fd6e20622d2177a8daf1f3f24cc8cf6f945ed39d8e40c85559e7b006e59ebdf401a459503019ce9964f65e7348611
|
data/bin/nixenvironment
CHANGED
@@ -91,6 +91,7 @@ command :build do |c|
|
|
91
91
|
c.option '--requires_fullscreen', 'Set UIRequiresFullScreen to YES in Info.plist (ios)'
|
92
92
|
c.option '--skip_working_copy_check', 'Skip working copy cleaning check'
|
93
93
|
c.option '--share_schemes', 'Share schemes for xcode project'
|
94
|
+
c.option '--xc_args ARGS', String, 'Pass arguments to xcodebuild'
|
94
95
|
c.action do |_args, options|
|
95
96
|
options.default :config => 'Debug', :ipa => 'device', :icon_tagger => 'full', :unity_path => 'UNITY'
|
96
97
|
unity_platform = options.unity_platform
|
@@ -177,7 +178,7 @@ command :build do |c|
|
|
177
178
|
|
178
179
|
begin
|
179
180
|
prebuild(options.config, options.app_version, options.requires_fullscreen, options.skip_working_copy_check)
|
180
|
-
build(options.config, options.xcconfig, options.ipa, options.ndsym, options.icon_tagger)
|
181
|
+
build(options.config, options.xcconfig, options.ipa, options.ndsym, options.icon_tagger, options.xc_args)
|
181
182
|
ensure
|
182
183
|
restore_info_plists
|
183
184
|
end
|
@@ -508,7 +509,7 @@ def prebuild(config, app_version, requires_fullscreen, skip_working_copy_check)
|
|
508
509
|
update_info_plists(config, app_version, requires_fullscreen)
|
509
510
|
end
|
510
511
|
|
511
|
-
def build(config, xcconfig, ipa, ndsym, icon_tagger)
|
512
|
+
def build(config, xcconfig, ipa, ndsym, icon_tagger, xc_args)
|
512
513
|
project_to_build = @config_settings[PROJECT_TO_BUILD_KEY]
|
513
514
|
project_target_to_build = @config_settings[PROJECT_TARGET_TO_BUILD_KEY]
|
514
515
|
workspace_to_build = @config_settings[WORKSPACE_TO_BUILD_KEY]
|
@@ -521,10 +522,21 @@ def build(config, xcconfig, ipa, ndsym, icon_tagger)
|
|
521
522
|
|
522
523
|
debug_information_format = ndsym ? 'dwarf' : 'dwarf-with-dsym'
|
523
524
|
|
524
|
-
other_args = { 'DEBUG_INFORMATION_FORMAT' => debug_information_format,
|
525
|
-
'
|
525
|
+
other_args = { 'DEBUG_INFORMATION_FORMAT' => debug_information_format,
|
526
|
+
'DWARF_DSYM_FOLDER_PATH' => dwarf_dsym_folder_path,
|
527
|
+
'CONFIGURATION_BUILD_DIR' => configuration_build_dir,
|
528
|
+
'BUILT_PRODUCTS_DIR' => built_products_dir,
|
529
|
+
'GCC_PRECOMPILE_PREFIX_HEADER' => 'NO', # set "Precompile Prefix Header" flag to "NO"; otherwise it can throw error ".pch.pch has been modified since the precompiled header"
|
530
|
+
'ENABLE_BITCODE' => 'NO'} # need this in order to build unity <= 5.2.0 generated projects. TODO: remove me!
|
531
|
+
other_args_str = other_args.map { |key, value| "#{key}='#{value}'" }.join(' ')
|
526
532
|
|
527
|
-
|
533
|
+
if xc_args.present?
|
534
|
+
xc_args.concat(" #{other_args_str}")
|
535
|
+
else
|
536
|
+
xc_args = other_args_str
|
537
|
+
end
|
538
|
+
|
539
|
+
Xcodebuild.build(sdk, config, xcconfig, project_to_build, project_target_to_build, workspace_to_build, workspace_scheme_to_build, env_var_prefix, xc_args)
|
528
540
|
|
529
541
|
error('Build error!') unless Xcodebuild.last_cmd_success?
|
530
542
|
|
@@ -26,7 +26,7 @@ module Nixenvironment
|
|
26
26
|
end
|
27
27
|
|
28
28
|
# other => other args to be passed to xcodebuild
|
29
|
-
def self.build(sdk = nil, config = nil, xcconfig = nil, project = nil, target = nil, workspace = nil, scheme = nil, env_var_prefix = nil,
|
29
|
+
def self.build(sdk = nil, config = nil, xcconfig = nil, project = nil, target = nil, workspace = nil, scheme = nil, env_var_prefix = nil, xc_args = nil)
|
30
30
|
build_args = []
|
31
31
|
build_args << "-sdk '#{sdk}'" if sdk.present?
|
32
32
|
build_args << "-configuration '#{config}'" if config.present?
|
@@ -57,11 +57,7 @@ module Nixenvironment
|
|
57
57
|
build_args << "GCC_PREPROCESSOR_DEFINITIONS='$GCC_PREPROCESSOR_DEFINITIONS#{vars_to_define}'" if vars_to_define.present?
|
58
58
|
end
|
59
59
|
|
60
|
-
|
61
|
-
# otherwise it can throw error ".pch.pch has been modified since the precompiled header"
|
62
|
-
build_args << 'GCC_PRECOMPILE_PREFIX_HEADER=NO'
|
63
|
-
build_args << 'ENABLE_BITCODE=NO' # need this in order to build unity <= 5.2.0 generated projects. TODO: remove me!
|
64
|
-
build_args << other.map { |key, value| "#{key}='#{value}'" }.join(' ')
|
60
|
+
build_args << xc_args if xc_args.present?
|
65
61
|
build_args << '| xcpretty -c; exit ${PIPESTATUS[0]}'
|
66
62
|
|
67
63
|
execute(nil, build_args)
|