Class: Header
Overview
A generic Header class that installs header files into $(PKGINCLUDEDIR)
Instance Attribute Summary
Attributes inherited from Buildable
#buildable, #cflags, #distributable, #enable, #id, #installable, #ldadd, #localdep, #output, #output_type, #project, #rpath, #sources, #sysdep, #topdir
Instance Method Summary collapse
- #build ⇒ Object
-
#initialize(options) ⇒ Header
constructor
A new instance of Header.
- #makedepends ⇒ Object
Methods inherited from Buildable
#binary?, #expand_sources, #finalize, #library?, #library_type, #objects
Constructor Details
#initialize(options) ⇒ Header
Returns a new instance of Header.
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/makeconf/header.rb', line 5 def initialize() raise ArgumentError unless .kind_of?(Hash) # KLUDGE - parent constructor will barf unless we delete our # custom options @namespace = [:namespace] .delete :namespace super() end |
Instance Method Details
#build ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/makeconf/header.rb', line 16 def build mk = Makefile.new mk.distribute(@sources) dest = '$(INCLUDEDIR)' dest += '/' + @namespace unless @namespace.nil? @project.installer.install( :sources => @sources, :dest => dest, :mode => '644' ) return mk end |
#makedepends ⇒ Object
33 34 35 |
# File 'lib/makeconf/header.rb', line 33 def makedepends [] end |