Class: Phoenx::ApplicationTargetBuilder
- Inherits:
-
TestableTargetBuilder
- Object
- TargetBuilder
- TestableTargetBuilder
- Phoenx::ApplicationTargetBuilder
- Defined in:
- lib/phoenx/use_cases/generate_target.rb
Instance Attribute Summary
Attributes inherited from TargetBuilder
#framework_files, #project, #project_spec, #target_spec
Instance Method Summary collapse
Methods inherited from TestableTargetBuilder
#add_schemes, #add_test_targets, #generate_target_scheme, #sort_build_phases
Methods inherited from TargetBuilder
#add_build_phase_scripts, #add_config_files, #add_frameworks_and_libraries, #add_headers, #add_private_headers, #add_project_headers, #add_public_headers, #add_resources, #add_sources, #add_support_files, #add_system_dependencies, #configure_target, #initialize
Constructor Details
This class inherits a constructor from Phoenx::TargetBuilder
Instance Method Details
#add_sub_projects ⇒ Object
275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 |
# File 'lib/phoenx/use_cases/generate_target.rb', line 275 def add_sub_projects super frameworks_group = @project.main_group.find_subpath(FRAMEWORKS_ROOT,false) @target_spec.dependencies.each do |dp| file = nil if dp. == false next end if dp.path == nil # Copy internal references target = Phoenx.target_for_name(@project,dp.target_name) build_file = @copy_frameworks.add_file_reference(target.product_reference) build_file.settings = ATTRIBUTES_CODE_SIGN_ON_COPY else # Copy external products proj_file = frameworks_group.find_file_by_path(dp.path) proj = Xcodeproj::Project::open(dp.path) target = Phoenx.target_for_name(proj,dp.target_name) proj_file.file_reference_proxies.each do |e| if e.remote_ref.remote_global_id_string == target.product_reference.uuid build_file = @copy_frameworks.add_file_reference(e) build_file.settings = ATTRIBUTES_CODE_SIGN_ON_COPY end end end end end |
#build ⇒ Object
303 304 305 306 307 308 309 310 311 312 |
# File 'lib/phoenx/use_cases/generate_target.rb', line 303 def build @target = @project.new_target(@target_spec.target_type, @target_spec.name, @target_spec.platform, @target_spec.version) @copy_frameworks = @target.new_copy_files_build_phase "Embed Frameworks" @copy_frameworks.symbol_dst_subfolder_spec = :frameworks super() self.framework_files.each do |file| build_file = @copy_frameworks.add_file_reference(file) build_file.settings = ATTRIBUTES_CODE_SIGN_ON_COPY end end |
#target ⇒ Object
314 315 316 |
# File 'lib/phoenx/use_cases/generate_target.rb', line 314 def target return @target end |