File tree Expand file tree Collapse file tree 6 files changed +27
-3
lines changed Expand file tree Collapse file tree 6 files changed +27
-3
lines changed Original file line number Diff line number Diff line change @@ -31,3 +31,5 @@ test/Binary.xcworkspace/contents.xcworkspacedata
3131test /Binary.xcworkspace /xcshareddata /IDEWorkspaceChecks.plist
3232test /Podfile
3333test /Podfile.lock
34+
35+ * .gem
Original file line number Diff line number Diff line change 1+ Forked from https://github.com/muukii/cocoapods-binary
2+
3+ add ` forbidden_dependency_binary! ` , Prevent the automatic compilation of dependent libraries into binary as well.
4+
5+ ---
6+
17> ⚠️ This is a temporaly forked repository.
28
39https://github.com/leavez/cocoapods-binary/pull/137
Original file line number Diff line number Diff line change @@ -12,6 +12,11 @@ def all_binary!
1212 DSL . prebuild_all = true
1313 end
1414
15+ # Fobidden dependency auto build to binary
16+ def forbidden_dependency_binary!
17+ DSL . forbidden_dependency_binary = true
18+ end
19+
1520 # Enable bitcode for prebuilt frameworks
1621 def enable_bitcode_for_prebuilt_frameworks!
1722 DSL . bitcode_enabled = true
@@ -56,6 +61,9 @@ def set_custom_xcodebuild_options_for_prebuilt_frameworks(options)
5661 end
5762
5863 private
64+ class_attr_accessor :forbidden_dependency_binary
65+ forbidden_dependency_binary = false
66+
5967 class_attr_accessor :prebuild_all
6068 prebuild_all = false
6169
Original file line number Diff line number Diff line change @@ -109,6 +109,11 @@ def prebuild_frameworks!
109109 targets = self . pod_targets
110110 end
111111
112+ if Pod ::Podfile ::DSL . forbidden_dependency_binary
113+ forbidden_dependency_targets = targets . map { |t | t . recursive_dependent_targets } . flatten . uniq || [ ]
114+ targets = targets - forbidden_dependency_targets
115+ end
116+
112117 targets = targets . reject { |pod_target | sandbox . local? ( pod_target . pod_name ) }
113118
114119
Original file line number Diff line number Diff line change 11module CocoapodsBinary
2- VERSION = "0.4.4 "
2+ VERSION = "0.4.5 "
33end
Original file line number Diff line number Diff line change @@ -81,8 +81,11 @@ def prebuild_pod_targets
8181 if not Podfile ::DSL . prebuild_all
8282 targets = targets . select { |pod_target | prebuild_names . include? ( pod_target . pod_name ) }
8383 end
84- dependency_targets = targets . map { |t | t . recursive_dependent_targets } . flatten . uniq || [ ]
85- targets = ( targets + dependency_targets ) . uniq
84+
85+ if not Podfile ::DSL . forbidden_dependency_binary
86+ dependency_targets = targets . map { |t | t . recursive_dependent_targets } . flatten . uniq || [ ]
87+ targets = ( targets + dependency_targets ) . uniq
88+ end
8689
8790 # filter should not prebuild
8891 explict_should_not_names = target_definition . should_not_prebuild_framework_pod_names
You can’t perform that action at this time.
0 commit comments