Class: MachO::RpathCommand

Inherits:
LoadCommand show all
Defined in:
lib/macho/load_commands.rb

Overview

A load command representing an rpath, which specifies a path that should be added to the current run path used to find @rpath prefixed dylibs. Corresponds to LC_RPATH.

Instance Attribute Summary collapse

Attributes inherited from LoadCommand

#cmd, #cmdsize, #offset

Instance Method Summary collapse

Methods inherited from LoadCommand

new_from_bin, #to_s

Methods inherited from MachOStructure

bytesize, new_from_bin

Constructor Details

#initialize(offset, cmd, cmdsize, path) ⇒ RpathCommand

Returns a new instance of RpathCommand.



861
862
863
864
# File 'lib/macho/load_commands.rb', line 861

def initialize(offset, cmd, cmdsize, path)
  super(offset, cmd, cmdsize)
  @path = path
end

Instance Attribute Details

#pathFixnum (readonly)

Returns the oath to add to the run path (lc_str).

Returns:

  • (Fixnum)

    the oath to add to the run path (lc_str)



855
856
857
# File 'lib/macho/load_commands.rb', line 855

def path
  @path
end