Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
690c7f5e
Commit
690c7f5e
authored
Sep 26, 2017
by
Dimitris Koutsogiorgas
Committed by
GitHub
Sep 26, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #7058 from paulb777/sf-subspec
Build subspecs in static frameworks without error
parents
ebadf446
a960d8b5
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
2 deletions
+31
-2
CHANGELOG.md
CHANGELOG.md
+3
-1
target.rb
lib/cocoapods/target.rb
+1
-1
matryoshka.podspec
spec/fixtures/matryoshka/matryoshka.podspec
+2
-0
target_validator_spec.rb
spec/unit/installer/xcode/target_validator_spec.rb
+25
-0
No files found.
CHANGELOG.md
View file @
690c7f5e
...
...
@@ -12,7 +12,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
##### Bug Fixes
*
None.
*
Build subspecs in static frameworks without error
[
Paul Beusterien
](
https://github.com/paulb777
)
[
#7058
](
https://github.com/CocoaPods/CocoaPods/pull/7058
)
## 1.4.0.beta.1 (2017-09-24)
...
...
lib/cocoapods/target.rb
View file @
690c7f5e
...
...
@@ -93,7 +93,7 @@ module Pod
# @return [Boolean] Whether the target should build a static framework.
#
def
static_framework?
!
is_a?
(
Pod
::
AggregateTarget
)
&&
specs
.
any?
&&
specs
.
all?
(
&
:static_framework
)
!
is_a?
(
Pod
::
AggregateTarget
)
&&
specs
.
any?
&&
specs
.
flat_map
(
&
:root
).
all?
(
&
:static_framework
)
end
#-------------------------------------------------------------------------#
...
...
spec/fixtures/matryoshka/matryoshka.podspec
View file @
690c7f5e
...
...
@@ -7,6 +7,7 @@ Pod::Spec.new do |s|
s
.
homepage
=
"http://httpbin.org/html"
s
.
source
=
{
:git
=>
"http://malyutin.local/matryoshka.git"
,
:tag
=>
s
.
version
.
to_s
}
s
.
license
=
'MIT'
s
.
static_framework
=
true
s
.
source_files
=
'Outmost.{h,m}'
...
...
@@ -26,5 +27,6 @@ Pod::Spec.new do |s|
s
.
subspec
'Bar'
do
|
ss
|
ss
.
source_files
=
'Bar/Bar.{h,m}'
ss
.
dependency
'monkey'
end
end
spec/unit/installer/xcode/target_validator_spec.rb
View file @
690c7f5e
...
...
@@ -181,6 +181,31 @@ module Pod
end
end
describe
'#verify_no_static_framework_transitive_dependencies_with_static_framework'
do
before
do
fixture_path
=
ROOT
+
'spec/fixtures'
config
.
repos_dir
=
fixture_path
+
'spec-repos'
@podfile
=
Pod
::
Podfile
.
new
do
install!
'cocoapods'
,
'integrate_targets'
=>
false
platform
:ios
,
'8.0'
project
'SampleProject/SampleProject'
use_frameworks!
pod
'matryoshka/Bar'
,
:path
=>
(
fixture_path
+
'matryoshka'
).
to_s
pod
'monkey'
,
:path
=>
(
fixture_path
+
'monkey'
).
to_s
target
'SampleProject'
end
@lockfile
=
generate_lockfile
@file
=
Pathname
(
'/yolo.m'
)
@file
.
stubs
(
:realpath
).
returns
(
@file
)
end
it
'allows transitive static dependencies when building a static framework'
do
@validator
=
create_validator
(
config
.
sandbox
,
@podfile
,
@lockfile
)
should
.
not
.
raise
(
Informative
)
{
@validator
.
send
:verify_no_static_framework_transitive_dependencies
}
end
end
#-------------------------------------------------------------------------#
describe
'#verify_no_pods_used_with_multiple_swift_versions'
do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment