[cairo-commit] rcairo .cvsignore, 1.2, 1.3 ChangeLog, 1.114,
1.115 README, 1.10, 1.11 extconf.rb, NONE, 1.1 setup.rb, 1.4, NONE
Kouhei Sutou
commit at pdx.freedesktop.org
Tue Mar 6 04:17:40 PST 2007
- Previous message: [cairo-commit] rcairo/samples pac.rb, 1.5, 1.6 pac2.rb, 1.5,
1.6 png.rb, 1.11, 1.12 text-on-path.rb, 1.2, 1.3 text2.rb, 1.5, 1.6
- Next message: [cairo-commit] rcairo/packages/cairo .cvsignore,1.1,NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Committed by: kou
Update of /cvs/cairo/rcairo
In directory kemper:/tmp/cvs-serv14983
Modified Files:
.cvsignore ChangeLog README
Added Files:
extconf.rb
Removed Files:
setup.rb
Log Message:
* setup.rb: removed dependency on setup.rb. used Ruby-GNOME2 style.
* extconf.rb: moved from packages/cairo/ext/.
* packages/cairo/ext: move to ...
* src/: ... here.
* packages/cairo/lib: move to ...
* src/lib: ... here.
* README, samples/: followed the changes.
Index: .cvsignore
===================================================================
RCS file: /cvs/cairo/rcairo/.cvsignore,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- .cvsignore 1 Sep 2004 15:53:16 -0000 1.2
+++ .cvsignore 6 Mar 2007 12:17:33 -0000 1.3
@@ -1,3 +1,2 @@
-{arch}
-InstalledFiles
-config.save
+Makefile
+mkmf.log
Index: ChangeLog
===================================================================
RCS file: /cvs/cairo/rcairo/ChangeLog,v
retrieving revision 1.114
retrieving revision 1.115
diff -u -d -r1.114 -r1.115
--- ChangeLog 3 Mar 2007 13:53:29 -0000 1.114
+++ ChangeLog 6 Mar 2007 12:17:33 -0000 1.115
@@ -1,3 +1,18 @@
+2007-03-06 Kouhei Sutou <kou at cozmixng.org>
+
+ * setup.rb: removed dependency on setup.rb. used Ruby-GNOME2
+ style.
+
+ * extconf.rb: moved from packages/cairo/ext/.
+
+ * packages/cairo/ext: move to ...
+ * src/: ... here.
+
+ * packages/cairo/lib: move to ...
+ * src/lib: ... here.
+
+ * README, samples/: followed the changes.
+
2007-03-03 Kouhei Sutou <kou at cozmixng.org>
* packages/cairo/ext/rb_cairo_context.c: supported cairo 1.3.16.
Index: README
===================================================================
RCS file: /cvs/cairo/rcairo/README,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- README 1 Jul 2006 14:45:55 -0000 1.10
+++ README 6 Mar 2007 12:17:33 -0000 1.11
@@ -15,12 +15,12 @@
Compiling
---------
-% ruby setup.rb config # to check for dependencies and create Makefiles
-% ruby setup.rb setup # to compile
+% ruby extconf.rb # to check for dependencies and create Makefiles
+% make # to compile
-# ruby setup.rb install # to install the cairo extension.
- # the samples in the samples folder should be able
- # to run before installation.
+# make install # to install the cairo extension.
+ # the samples in the samples folder should be able
+ # to run before installation.
Mailing list
------------
--- NEW FILE: extconf.rb ---
#!/usr/bin/env ruby
# vim: filetype=ruby:expandtab:shiftwidth=2:tabstop=8:softtabstop=2 :
require 'mkmf'
require 'pkg-config'
require 'fileutils'
# from mkmf-gnome2.rb
STDOUT.print("checking for GCC... ")
STDOUT.flush
if macro_defined?("__GNUC__", "")
STDOUT.print "yes\n"
$CFLAGS += ' -Wall'
$cc_is_gcc = true
else
STDOUT.print "no\n"
$cc_is_gcc = false
end
def check_win32()
STDOUT.print("checking for Win32 OS... ")
STDOUT.flush
if /cygwin|mingw|mswin32/ =~ RUBY_PLATFORM
$defs << "-DRUBY_CAIRO_PLATFORM_WIN32"
STDOUT.print "yes\n"
if $cc_is_gcc
if /^2\./ =~ `#{Config::CONFIG['CC']} -dumpversion`.chomp
$CFLAGS += ' -fnative-struct'
else
$CFLAGS += ' -mms-bitfields'
end
end
else
STDOUT.print "no\n"
end
end
def set_output_lib(target_name)
if /cygwin|mingw/ =~ RUBY_PLATFORM
filename = "libruby-#{target_name}.a"
if RUBY_VERSION > "1.8.0"
$DLDFLAGS << ",--out-implib=#{filename}" if filename
elsif RUBY_VERSION > "1.8"
$DLDFLAGS.gsub!(/ -Wl,--out-implib=[^ ]+/, '')
$DLDFLAGS << " -Wl,--out-implib=#{filename}" if filename
else
$DLDFLAGS.gsub!(/ --output-lib\s+[^ ]+/, '')
$DLDFLAGS << " --output-lib #{filename}" if filename
end
elsif /mswin32/ =~ RUBY_PLATFORM
filename = "libruby-#{target_name}.lib"
$DLDFLAGS.gsub!(/ --output-lib\s+[^ ]+/, '')
$DLDFLAGS.gsub!(/ \/IMPLIB:[^ ]+/, '')
$DLDFLAGS << " /IMPLIB:#{filename}" if filename
end
end
def setup_win32(target_name)
check_win32
set_output_lib(target_name)
end
def create_makefile_at_srcdir(pkg_name, srcdir, defs=nil)
begin
Dir.mkdir(srcdir) unless File.exist?(srcdir)
Dir.chdir(srcdir)
yield if block_given?
$defs << defs if defs
create_makefile(pkg_name, srcdir)
ensure
Dir.chdir('..')
end
end
def create_top_makefile(sub_dirs=["src"])
File.open("Makefile", "w") do |mfile|
if /mswin32/ =~ RUBY_PLATFORM
mfile.print <<MSWIN32_END
all:
#{sub_dirs.map{|d| " @cd #{d}\n @nmake -nologo all\n @cd ..\n"}.join('')}
install:
#{sub_dirs.map{|d| " @cd #{d}\n @nmake -nologo install DESTDIR=$(DESTDIR)\n @cd ..\n"}.join('')}
site-install:
#{sub_dirs.map{|d| " @cd #{d}\n @nmake -nologo site-install DESTDIR=$(DESTDIR)\n @cd ..\n"}.join('')}
clean:
#{sub_dirs.map{|d| " @cd #{d}\n @nmake -nologo clean\n @cd ..\n"}.join('')} @if exist extconf.h del extconf.h
@if exist conftest.* del conftest.*
@if exist *.lib del *.lib
@if exist *~ del *~
@if exist mkmf.log del mkmf.log
MSWIN32_END
else
mfile.print <<END
all:
#{sub_dirs.map{|d| " @cd #{d}; make all\n"}.join('')}
install:
#{sub_dirs.map{|d| " @cd #{d}; make install\n"}.join('')}
site-install:
#{sub_dirs.map{|d| " @cd #{d}; make site-install\n"}.join('')}
clean:
#{sub_dirs.map{|d| " @cd #{d}; make clean\n"}.join('')}
distclean: clean
#{sub_dirs.map{|d| " @cd #{d}; make distclean\n"}.join('')}
@rm -f Makefile extconf.h conftest.*
@rm -f core *~ mkmf.log
END
end
end
end
pkg = "cairo"
modname = "cairo"
srcdir = File.join(File.expand_path(File.dirname(__FILE__)), "src")
major, minor, micro = 1, 2, 0
PKGConfig.have_package(pkg, major, minor, micro) or exit 1
setup_win32(File.basename(modname))
create_makefile_at_srcdir(modname, srcdir, "-DRUBY_CAIRO_COMPILATION")
create_top_makefile
--- setup.rb DELETED ---
- Previous message: [cairo-commit] rcairo/samples pac.rb, 1.5, 1.6 pac2.rb, 1.5,
1.6 png.rb, 1.11, 1.12 text-on-path.rb, 1.2, 1.3 text2.rb, 1.5, 1.6
- Next message: [cairo-commit] rcairo/packages/cairo .cvsignore,1.1,NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the cairo-commit
mailing list