Class: RakeCompile::Application

Inherits:
Object
  • Object
show all
Defined in:
lib/rake-compile/application.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeApplication

Returns a new instance of Application.



17
18
19
# File 'lib/rake-compile/application.rb', line 17

def initialize()
  @libraries = []
end

Instance Attribute Details

#base_cc_flagsObject

Returns the value of attribute base_cc_flags.



6
7
8
# File 'lib/rake-compile/application.rb', line 6

def base_cc_flags
  @base_cc_flags
end

#base_cpp_flagsObject

Returns the value of attribute base_cpp_flags.



4
5
6
# File 'lib/rake-compile/application.rb', line 4

def base_cpp_flags
  @base_cpp_flags
end

#base_ld_flagsObject

Returns the value of attribute base_ld_flags.



8
9
10
# File 'lib/rake-compile/application.rb', line 8

def base_ld_flags
  @base_ld_flags
end

#build_directoryObject

Returns the value of attribute build_directory.



3
4
5
# File 'lib/rake-compile/application.rb', line 3

def build_directory
  @build_directory
end

#cc_flagsObject

Returns the value of attribute cc_flags.



7
8
9
# File 'lib/rake-compile/application.rb', line 7

def cc_flags
  @cc_flags
end

#cpp_flagsObject

Returns the value of attribute cpp_flags.



5
6
7
# File 'lib/rake-compile/application.rb', line 5

def cpp_flags
  @cpp_flags
end

#ld_flagsObject

Returns the value of attribute ld_flags.



9
10
11
# File 'lib/rake-compile/application.rb', line 9

def ld_flags
  @ld_flags
end

#librariesObject (readonly)

Returns the value of attribute libraries.



10
11
12
# File 'lib/rake-compile/application.rb', line 10

def libraries
  @libraries
end

#pchObject

Returns the value of attribute pch.



11
12
13
# File 'lib/rake-compile/application.rb', line 11

def pch
  @pch
end

Class Method Details

.appObject



13
14
15
# File 'lib/rake-compile/application.rb', line 13

def self.app
  @app ||= RakeCompile::Application.new
end

Instance Method Details

#flagsObject



33
34
35
# File 'lib/rake-compile/application.rb', line 33

def flags
  {:cc_flags => self.full_cc_flags, :cpp_flags => self.full_cpp_flags, :ld_flags => self.full_ld_flags}
end

#full_cc_flagsObject



25
26
27
# File 'lib/rake-compile/application.rb', line 25

def full_cc_flags
  "#{self.base_cc_flags} #{self.cc_flags}"
end

#full_cpp_flagsObject



21
22
23
# File 'lib/rake-compile/application.rb', line 21

def full_cpp_flags
  "#{self.base_cpp_flags} #{self.cpp_flags}"
end

#full_ld_flagsObject



29
30
31
# File 'lib/rake-compile/application.rb', line 29

def full_ld_flags
  "#{self.base_ld_flags} #{self.ld_flags}"
end