Module: Pod

Defined in:
lib/cocoapods-binary-cache/pod-binary/prebuild.rb,
lib/command/fetch.rb,
lib/command/binary.rb,
lib/command/prebuild.rb,
lib/command/visualize.rb,
lib/cocoapods-binary-cache/ui.rb,
lib/cocoapods-binary-cache/helper/podspec.rb,
lib/cocoapods-binary-cache/pod-binary/helper/names.rb,
lib/cocoapods-binary-cache/pod-binary/prebuild_dsl.rb,
lib/cocoapods-binary-cache/pod-binary/helper/passer.rb,
lib/cocoapods-binary-cache/pod-rome/build_framework.rb,
lib/cocoapods-binary-cache/pod-binary/helper/target_checker.rb,
lib/cocoapods-binary-cache/pod-binary/integration/validation.rb,
lib/cocoapods-binary-cache/pod-binary/helper/feature_switches.rb,
lib/cocoapods-binary-cache/pod-binary/helper/prebuild_sandbox.rb,
lib/cocoapods-binary-cache/pod-binary/integration/alter_specs.rb,
lib/cocoapods-binary-cache/pod-binary/integration/source_installer.rb,
lib/cocoapods-binary-cache/pod-binary/integration/remove_target_files.rb,
lib/cocoapods-binary-cache/pod-binary/integration/patch/source_installation.rb,
lib/cocoapods-binary-cache/pod-binary/integration/patch/resolve_dependencies.rb,
lib/cocoapods-binary-cache/pod-binary/helper/detected_prebuilt_pods/installer.rb,
lib/cocoapods-binary-cache/pod-binary/integration/patch/embed_framework_script.rb,
lib/cocoapods-binary-cache/pod-binary/helper/detected_prebuilt_pods/target_definition.rb

Overview

A fix in embeded frameworks script.

The framework file in pod target folder is a symblink. The EmbedFrameworksScript use readlink to read the read path. As the symlink is a relative symlink, readlink cannot handle it well. So we override the readlink to a fixed version.

Defined Under Namespace

Modules: Generator, UI Classes: Command, Config, Installer, Podfile, Prebuild, PrebuildInstaller, PrebuildSandbox, Specification

Class Method Summary collapse

Class Method Details

.fast_get_targets_for_pod_name(pod_name, targets, cache) ⇒ Object



19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# File 'lib/cocoapods-binary-cache/pod-binary/helper/names.rb', line 19

def self.fast_get_targets_for_pod_name(pod_name, targets, cache)
  pod_name = pod_name.split("/")[0] # Look for parent spec instead of subspecs
  pod_name_to_targets_hash = nil
  if cache.empty?
    pod_name_to_targets_hash = targets.reduce({}) do |sum, target|
      array = sum[target.pod_name] || []
      array << target
      sum[target.pod_name] = array
      sum
    end
    cache << pod_name_to_targets_hash
  else
    pod_name_to_targets_hash = cache.first
  end

  pod_name_to_targets_hash[pod_name] || []
end