Top Level Namespace

Defined Under Namespace

Modules: Glfw Classes: GLFWimage

Constant Summary collapse

RUBYVER =
" -DRUBY_VERSION=" + RUBY_VERSION.split(".").join

Instance Method Summary collapse

Instance Method Details

#parse_libglfwpcin(path) ⇒ Object

parses options for compiler and linker from will-be-pkgconfig file created after compiling the bundled GLFW library itself



31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# File 'ext/glfw/mkrf_conf.rb', line 31

def parse_libglfwpcin(path)
	libs = cflags = ""
	f = File.open(path)
	f.each do |line|
		case line
		when /Libs/
			tmp = line.chop.split("-lglfw")
			if tmp and tmp.size>=2
				libs = tmp[1]
			end
		when /Cflags/
			tmp = line.chop.split("}")
			if tmp and tmp.size>=2
				cflags = tmp[1]
			end
		end
	end
	[cflags,libs]	
end