cocoapods 1.6.0.beta.1 → 1.6.0.beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +94 -4
- data/lib/cocoapods/command/cache/clean.rb +1 -1
- data/lib/cocoapods/command/init.rb +3 -1
- data/lib/cocoapods/command/outdated.rb +2 -2
- data/lib/cocoapods/executable.rb +1 -1
- data/lib/cocoapods/gem_version.rb +1 -1
- data/lib/cocoapods/generator/acknowledgements/plist.rb +3 -3
- data/lib/cocoapods/generator/app_target_helper.rb +2 -4
- data/lib/cocoapods/generator/copy_resources_script.rb +8 -3
- data/lib/cocoapods/generator/embed_frameworks_script.rb +24 -18
- data/lib/cocoapods/installer.rb +37 -21
- data/lib/cocoapods/installer/analyzer.rb +19 -13
- data/lib/cocoapods/installer/analyzer/locking_dependency_analyzer.rb +5 -0
- data/lib/cocoapods/installer/analyzer/target_inspection_result.rb +5 -0
- data/lib/cocoapods/installer/installation_options.rb +2 -0
- data/lib/cocoapods/installer/pod_source_installer.rb +1 -1
- data/lib/cocoapods/installer/post_install_hooks_context.rb +1 -1
- data/lib/cocoapods/installer/user_project_integrator.rb +6 -2
- data/lib/cocoapods/installer/user_project_integrator/target_integrator.rb +42 -12
- data/lib/cocoapods/installer/xcode/pods_project_generator.rb +2 -4
- data/lib/cocoapods/installer/xcode/pods_project_generator/app_host_installer.rb +14 -5
- data/lib/cocoapods/installer/xcode/pods_project_generator/file_references_installer.rb +12 -6
- data/lib/cocoapods/installer/xcode/pods_project_generator/pod_target_installer.rb +22 -11
- data/lib/cocoapods/installer/xcode/pods_project_generator/pod_target_integrator.rb +29 -18
- data/lib/cocoapods/installer/xcode/target_validator.rb +1 -1
- data/lib/cocoapods/project.rb +2 -0
- data/lib/cocoapods/resolver.rb +42 -49
- data/lib/cocoapods/resolver/resolver_specification.rb +41 -0
- data/lib/cocoapods/sandbox.rb +21 -17
- data/lib/cocoapods/target/aggregate_target.rb +3 -1
- data/lib/cocoapods/target/build_settings.rb +35 -12
- data/lib/cocoapods/target/framework_paths.rb +36 -0
- data/lib/cocoapods/target/pod_target.rb +16 -17
- data/lib/cocoapods/validator.rb +18 -5
- metadata +18 -10
@@ -0,0 +1,36 @@
|
|
1
|
+
module Pod
|
2
|
+
class Target
|
3
|
+
class FrameworkPaths
|
4
|
+
# @return [String] the path to the .framework
|
5
|
+
#
|
6
|
+
attr_reader :source_path
|
7
|
+
|
8
|
+
# @return [String, Nil] the dSYM path, if one exists
|
9
|
+
#
|
10
|
+
attr_reader :dsym_path
|
11
|
+
|
12
|
+
def initialize(source_path, dsym_path = nil)
|
13
|
+
@source_path = source_path
|
14
|
+
@dsym_path = dsym_path
|
15
|
+
end
|
16
|
+
|
17
|
+
def ==(other)
|
18
|
+
if other.class == self.class
|
19
|
+
other.source_path == @source_path && other.dsym_path == @dsym_path
|
20
|
+
else
|
21
|
+
false
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
alias eql? ==
|
26
|
+
|
27
|
+
def hash
|
28
|
+
if (dsym = dsym_path)
|
29
|
+
[source_path, dsym].hash
|
30
|
+
else
|
31
|
+
source_path.hash
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'cocoapods/target/framework_paths'
|
2
|
+
|
1
3
|
module Pod
|
2
4
|
# Stores the information relative to the target used to compile a single Pod.
|
3
5
|
# A pod can have one or more activated spec, subspecs and test specs.
|
@@ -244,34 +246,27 @@ module Pod
|
|
244
246
|
!test_specs.empty?
|
245
247
|
end
|
246
248
|
|
247
|
-
# @return [Hash{String=>Array<
|
249
|
+
# @return [Hash{String=>Array<FrameworkPaths>}] The vendored and non vendored framework paths this target
|
248
250
|
# depends upon keyed by spec name. For the root spec and subspecs the framework path of the target itself
|
249
251
|
# is included.
|
250
252
|
#
|
251
253
|
def framework_paths
|
252
254
|
@framework_paths ||= begin
|
253
255
|
file_accessors.each_with_object({}) do |file_accessor, hash|
|
254
|
-
frameworks =
|
255
|
-
file_accessor.vendored_dynamic_artifacts.map do |framework_path|
|
256
|
+
frameworks = file_accessor.vendored_dynamic_artifacts.map do |framework_path|
|
256
257
|
relative_path_to_sandbox = framework_path.relative_path_from(sandbox.root)
|
257
|
-
|
258
|
-
:input_path => "${PODS_ROOT}/#{relative_path_to_sandbox}",
|
259
|
-
:output_path => "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/#{framework_path.basename}" }
|
258
|
+
framework_source = "${PODS_ROOT}/#{relative_path_to_sandbox}"
|
260
259
|
# Until this can be configured, assume the dSYM file uses the file name as the framework.
|
261
260
|
# See https://github.com/CocoaPods/CocoaPods/issues/1698
|
262
261
|
dsym_name = "#{framework_path.basename}.dSYM"
|
263
262
|
dsym_path = Pathname.new("#{framework_path.dirname}/#{dsym_name}")
|
264
|
-
if dsym_path.exist?
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
end
|
269
|
-
frameworks << framework
|
263
|
+
dsym_source = if dsym_path.exist?
|
264
|
+
"${PODS_ROOT}/#{relative_path_to_sandbox}.dSYM"
|
265
|
+
end
|
266
|
+
FrameworkPaths.new(framework_source, dsym_source)
|
270
267
|
end
|
271
268
|
if !file_accessor.spec.test_specification? && should_build? && requires_frameworks? && !static_framework?
|
272
|
-
frameworks << {
|
273
|
-
:input_path => build_product_path('${BUILT_PRODUCTS_DIR}'),
|
274
|
-
:output_path => "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/#{product_name}" }
|
269
|
+
frameworks << FrameworkPaths.new(build_product_path('${BUILT_PRODUCTS_DIR}'))
|
275
270
|
end
|
276
271
|
hash[file_accessor.spec.name] = frameworks
|
277
272
|
end
|
@@ -517,11 +512,15 @@ module Pod
|
|
517
512
|
# @param [Boolean] include_dependent_targets_for_test_spec
|
518
513
|
# whether to include header search paths for test dependent targets
|
519
514
|
#
|
515
|
+
# @param [Boolean] include_private_headers
|
516
|
+
# whether to include header search paths for private headers of this
|
517
|
+
# target
|
518
|
+
#
|
520
519
|
# @return [Array<String>] The set of header search paths this target uses.
|
521
520
|
#
|
522
|
-
def header_search_paths(include_dependent_targets_for_test_spec: nil)
|
521
|
+
def header_search_paths(include_dependent_targets_for_test_spec: nil, include_private_headers: true)
|
523
522
|
header_search_paths = []
|
524
|
-
header_search_paths.concat(build_headers.search_paths(platform, nil, false))
|
523
|
+
header_search_paths.concat(build_headers.search_paths(platform, nil, false)) if include_private_headers
|
525
524
|
header_search_paths.concat(sandbox.public_headers.search_paths(platform, pod_name, uses_modular_headers?))
|
526
525
|
dependent_targets = recursive_dependent_targets
|
527
526
|
dependent_targets += recursive_test_dependent_targets(include_dependent_targets_for_test_spec) if include_dependent_targets_for_test_spec
|
data/lib/cocoapods/validator.rb
CHANGED
@@ -511,7 +511,8 @@ module Pod
|
|
511
511
|
end
|
512
512
|
|
513
513
|
def download_pod
|
514
|
-
|
514
|
+
test_spec_names = consumer.spec.test_specs.select { |ts| ts.supported_on_platform?(consumer.platform_name) }.map(&:name)
|
515
|
+
podfile = podfile_from_spec(consumer.platform_name, deployment_target, use_frameworks, test_spec_names, use_modular_headers)
|
515
516
|
sandbox = Sandbox.new(config.sandbox_root)
|
516
517
|
@installer = Installer.new(sandbox, podfile)
|
517
518
|
@installer.use_default_plugins = false
|
@@ -635,10 +636,14 @@ module Pod
|
|
635
636
|
UI.message "\nTesting with `xcodebuild`.\n".yellow do
|
636
637
|
pod_target = @installer.pod_targets.find { |pt| pt.pod_name == spec.root.name }
|
637
638
|
consumer.spec.test_specs.each do |test_spec|
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
|
639
|
+
if !test_spec.supported_on_platform?(consumer.platform_name)
|
640
|
+
UI.warn "Skipping test spec `#{test_spec.name}` on platform `#{consumer.platform_name}` since it is not supported.\n".yellow
|
641
|
+
else
|
642
|
+
scheme = @installer.target_installation_results.first[pod_target.name].native_target_for_spec(test_spec)
|
643
|
+
output = xcodebuild('test', scheme, 'Debug')
|
644
|
+
parsed_output = parse_xcodebuild_output(output)
|
645
|
+
translate_output_to_linter_messages(parsed_output)
|
646
|
+
end
|
642
647
|
end
|
643
648
|
end
|
644
649
|
end
|
@@ -916,6 +921,14 @@ module Pod
|
|
916
921
|
when :ios
|
917
922
|
command += %w(CODE_SIGN_IDENTITY=- -sdk iphonesimulator)
|
918
923
|
command += Fourflusher::SimControl.new.destination(:oldest, 'iOS', deployment_target)
|
924
|
+
xcconfig = consumer.pod_target_xcconfig
|
925
|
+
if xcconfig
|
926
|
+
archs = xcconfig['VALID_ARCHS']
|
927
|
+
if archs && (archs.include? 'armv7') && !(archs.include? 'i386') && (archs.include? 'x86_64')
|
928
|
+
# Prevent Xcodebuild from testing the non-existent i386 simulator if armv7 is specified without i386
|
929
|
+
command += %w(ARCHS=x86_64)
|
930
|
+
end
|
931
|
+
end
|
919
932
|
when :watchos
|
920
933
|
command += %w(CODE_SIGN_IDENTITY=- -sdk watchsimulator)
|
921
934
|
command += Fourflusher::SimControl.new.destination(:oldest, 'watchOS', deployment_target)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocoapods
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.0.beta.
|
4
|
+
version: 1.6.0.beta.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eloy Duran
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2018-
|
14
|
+
date: 2018-10-17 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: cocoapods-core
|
@@ -19,14 +19,14 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - '='
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 1.6.0.beta.
|
22
|
+
version: 1.6.0.beta.2
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - '='
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 1.6.0.beta.
|
29
|
+
version: 1.6.0.beta.2
|
30
30
|
- !ruby/object:Gem::Dependency
|
31
31
|
name: claide
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|
@@ -73,7 +73,7 @@ dependencies:
|
|
73
73
|
requirements:
|
74
74
|
- - ">="
|
75
75
|
- !ruby/object:Gem::Version
|
76
|
-
version: 1.2.
|
76
|
+
version: 1.2.2
|
77
77
|
- - "<"
|
78
78
|
- !ruby/object:Gem::Version
|
79
79
|
version: '2.0'
|
@@ -83,7 +83,7 @@ dependencies:
|
|
83
83
|
requirements:
|
84
84
|
- - ">="
|
85
85
|
- !ruby/object:Gem::Version
|
86
|
-
version: 1.2.
|
86
|
+
version: 1.2.2
|
87
87
|
- - "<"
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: '2.0'
|
@@ -207,7 +207,7 @@ dependencies:
|
|
207
207
|
requirements:
|
208
208
|
- - ">="
|
209
209
|
- !ruby/object:Gem::Version
|
210
|
-
version: 1.
|
210
|
+
version: 1.7.0
|
211
211
|
- - "<"
|
212
212
|
- !ruby/object:Gem::Version
|
213
213
|
version: '2.0'
|
@@ -217,7 +217,7 @@ dependencies:
|
|
217
217
|
requirements:
|
218
218
|
- - ">="
|
219
219
|
- !ruby/object:Gem::Version
|
220
|
-
version: 1.
|
220
|
+
version: 1.7.0
|
221
221
|
- - "<"
|
222
222
|
- !ruby/object:Gem::Version
|
223
223
|
version: '2.0'
|
@@ -317,14 +317,20 @@ dependencies:
|
|
317
317
|
requirements:
|
318
318
|
- - "~>"
|
319
319
|
- !ruby/object:Gem::Version
|
320
|
-
version: '1.
|
320
|
+
version: '1.3'
|
321
|
+
- - ">="
|
322
|
+
- !ruby/object:Gem::Version
|
323
|
+
version: 1.3.1
|
321
324
|
type: :runtime
|
322
325
|
prerelease: false
|
323
326
|
version_requirements: !ruby/object:Gem::Requirement
|
324
327
|
requirements:
|
325
328
|
- - "~>"
|
326
329
|
- !ruby/object:Gem::Version
|
327
|
-
version: '1.
|
330
|
+
version: '1.3'
|
331
|
+
- - ">="
|
332
|
+
- !ruby/object:Gem::Version
|
333
|
+
version: 1.3.1
|
328
334
|
- !ruby/object:Gem::Dependency
|
329
335
|
name: bacon
|
330
336
|
requirement: !ruby/object:Gem::Requirement
|
@@ -491,6 +497,7 @@ files:
|
|
491
497
|
- lib/cocoapods/project.rb
|
492
498
|
- lib/cocoapods/resolver.rb
|
493
499
|
- lib/cocoapods/resolver/lazy_specification.rb
|
500
|
+
- lib/cocoapods/resolver/resolver_specification.rb
|
494
501
|
- lib/cocoapods/sandbox.rb
|
495
502
|
- lib/cocoapods/sandbox/file_accessor.rb
|
496
503
|
- lib/cocoapods/sandbox/headers_store.rb
|
@@ -501,6 +508,7 @@ files:
|
|
501
508
|
- lib/cocoapods/target.rb
|
502
509
|
- lib/cocoapods/target/aggregate_target.rb
|
503
510
|
- lib/cocoapods/target/build_settings.rb
|
511
|
+
- lib/cocoapods/target/framework_paths.rb
|
504
512
|
- lib/cocoapods/target/pod_target.rb
|
505
513
|
- lib/cocoapods/user_interface.rb
|
506
514
|
- lib/cocoapods/user_interface/error_report.rb
|