File: make-config-pc.rb

package info (click to toggle)
snd 26.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 44,028 kB
  • sloc: ansic: 291,903; lisp: 260,506; ruby: 71,134; sh: 3,293; fortran: 2,342; csh: 1,067; makefile: 294; cpp: 294; python: 87; xml: 27; javascript: 1
file content (33 lines) | stat: -rwxr-xr-x 738 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#! /usr/bin/env ruby 

# ruby make-config-pc.rb > ruby.pc 

require "rbconfig" 
if RUBY_VERSION < "1.9"
   include Config 
else
	include RbConfig 
end
version = CONFIG["ruby_version"] 
arch = CONFIG["arch"] 
rubyhdrdir = CONFIG["rubyhdrdir"]
if rubyhdrdir.nil?
   rubyhdrdir = CONFIG["rubylibdir"]
else
	rubyhdrdir.chomp("/")
end
dldflags = CONFIG["DLDFLAGS"] 
librubyarg = CONFIG["LIBRUBYARG"] 
libs = CONFIG["LIBS"] 
rubylibdir = CONFIG["libdir"] 

print <<OUT 
Name: Ruby 
Description: Object Oriented Script Language 
Version: #{version} 
URL: http://www.ruby-lang.org 
Cflags: -I#{rubyhdrdir}/#{arch} -I#{rubyhdrdir} 
# Libs: #{dldflags} #{librubyarg} #{libs} 
Libs: -L#{rubylibdir} #{dldflags} #{librubyarg} #{libs} 
Requires: 
OUT