summaryrefslogtreecommitdiff
path: root/x11/ruby-gtk
diff options
context:
space:
mode:
Diffstat (limited to 'x11/ruby-gtk')
-rw-r--r--x11/ruby-gtk/Makefile54
-rw-r--r--x11/ruby-gtk/files/md51
-rw-r--r--x11/ruby-gtk/patches/patch-aa36
-rw-r--r--x11/ruby-gtk/pkg/COMMENT1
-rw-r--r--x11/ruby-gtk/pkg/DESCR6
-rw-r--r--x11/ruby-gtk/pkg/PLIST18
6 files changed, 116 insertions, 0 deletions
diff --git a/x11/ruby-gtk/Makefile b/x11/ruby-gtk/Makefile
new file mode 100644
index 00000000000..296c284d243
--- /dev/null
+++ b/x11/ruby-gtk/Makefile
@@ -0,0 +1,54 @@
+# New ports collection makefile for: ruby-gtk
+# Version required: 0.21
+# Date created: 19 April 1999
+# Whom: Yasuhiro Fukuma <yasuf@big.or.jp>
+#
+# $FreeBSD: ports/x11-toolkits/ruby-gtk/Makefile,v 1.3 1999/08/31 02:59:33 peter Exp $
+#
+
+DISTNAME= ruby-gtk-0.21
+CATEGORIES= x11-toolkits
+MASTER_SITES= http://www.ueda.info.waseda.ac.jp/~igarashi/ruby/ \
+ ftp://ftp.netlab.co.jp/pub/lang/ruby/contrib/ \
+ ftp://ftp.TokyoNet.AD.JP/pub/misc/ruby/contrib/ \
+ ftp://ftp.iij.ad.jp/pub/lang/ruby/contrib/ \
+ ftp://blade.nagaokaut.ac.jp/pub/lang/ruby/contrib/ \
+ ftp://ftp.krnet.ne.jp/pub/ruby/contrib/ \
+ ftp://mirror.nucba.ac.jp/mirror/ruby/contrib/
+
+MAINTAINER= yasuf@big.or.jp
+
+BUILD_DEPENDS= ruby:${PORTSDIR}/lang/ruby
+RUN_DEPENDS= ruby:${PORTSDIR}/lang/ruby
+LIB_DEPENDS= gtk12.2:${PORTSDIR}/x11-toolkits/gtk12
+
+USE_XLIB= yes
+WRKSRC= ${WRKDIR}/gtk
+PLIST_SUB+= RUBY_VER="${RUBY_VER}" RUBY_ARCH="${RUBY_ARCH}"
+
+RUBY= ${PREFIX}/bin/ruby
+RUBY_VER= 1.4
+RUBY_ARCH= ${ARCH}-freebsd${OSREL}
+
+.if defined(NO_IMLIB)
+GTK_CONFIG?= ${X11BASE}/bin/gtk12-config
+.else
+LIB_DEPENDS+= Imlib.4:${PORTSDIR}/graphics/imlib
+GTK_CONFIG?= ${X11BASE}/bin/imlib-config
+.endif
+
+do-configure:
+ @cd ${WRKSRC}; ${SETENV} ${CONFIGURE_ENV} ${RUBY} extconf.rb ${GTK_CONFIG}
+
+post-install:
+ ${INSTALL_DATA} ${WRKSRC}/lib/*.rb ${PREFIX}/lib/ruby/${RUBY_VER}
+ ${MKDIR} ${PREFIX}/share/examples/ruby/gtk
+ ${INSTALL_DATA} ${WRKSRC}/sample/*.rb ${PREFIX}/share/examples/ruby/gtk
+ ${MKDIR} ${PREFIX}/share/examples/ruby/gtk/browser
+ ${INSTALL_DATA} ${WRKSRC}/doc/*.rb ${PREFIX}/share/examples/ruby/gtk/browser
+.if !defined(NO_IMLIB)
+ ${MKDIR} ${PREFIX}/share/examples/ruby/gtk/gdkimlib
+ ${INSTALL_DATA} ${WRKSRC}/sample/gdkimlib/*.rb ${PREFIX}/share/examples/ruby/gtk/gdkimlib
+.endif
+
+.include <bsd.port.mk>
diff --git a/x11/ruby-gtk/files/md5 b/x11/ruby-gtk/files/md5
new file mode 100644
index 00000000000..37e06183a4c
--- /dev/null
+++ b/x11/ruby-gtk/files/md5
@@ -0,0 +1 @@
+MD5 (ruby-gtk-0.21.tar.gz) = c93477a649e5982379fcba756ab8825c
diff --git a/x11/ruby-gtk/patches/patch-aa b/x11/ruby-gtk/patches/patch-aa
new file mode 100644
index 00000000000..c225b857c02
--- /dev/null
+++ b/x11/ruby-gtk/patches/patch-aa
@@ -0,0 +1,36 @@
+--- extconf.rb.orig Sat Aug 7 02:57:08 1999
++++ extconf.rb Wed Aug 25 08:44:11 1999
+@@ -8,22 +8,26 @@
+ # detect GTK+ (and Imlib) configurations
+ #
+ if /mswin32/ !~ PLATFORM
+- config_cmds = [
+- ["imlib-config", "--libs-gdk", "--cflags-gdk"],
+- ["gtk-config", "--libs", "--cflags"],
+- ]
++ config_cmds = ["imlib-config", "gtk-config"]
+ if ARGV.size > 0
+- config_cmds.unshift([ARGV[0], "--libs", "--cflags"])
++ config_cmds.unshift(ARGV[0])
+ end
+
+ begin
+- config_cmds.each do |config_cmd, config_libs, config_cflags|
++ config_cmds.each do |config_cmd|
+ version = `#{config_cmd} --version`
+ if not version.chomp.empty?
++ if /^imlib/ === File.basename(config_cmd)
++ with_imlib = true
++ config_libs, config_cflags = "--libs-gdk", "--cflags-gdk"
++ else
++ with_imlib = false
++ config_libs, config_cflags = "--libs", "--cflags"
++ end
+ $LDFLAGS, *libs = `#{config_cmd} #{config_libs}`.chomp.split(/(-l.*)/)
+ $libs = libs.join(' ') + ' ' + $libs
+ $CFLAGS = `#{config_cmd} #{config_cflags}`.chomp
+- if /^imlib/ === config_cmd
++ if with_imlib
+ $CFLAGS = $CFLAGS + " -DHAVE_GDKIMLIB"
+ STDERR.puts("Imlib support enabled.")
+ end
diff --git a/x11/ruby-gtk/pkg/COMMENT b/x11/ruby-gtk/pkg/COMMENT
new file mode 100644
index 00000000000..779fba338a5
--- /dev/null
+++ b/x11/ruby-gtk/pkg/COMMENT
@@ -0,0 +1 @@
+Ruby interface to Gtk+ toolkits
diff --git a/x11/ruby-gtk/pkg/DESCR b/x11/ruby-gtk/pkg/DESCR
new file mode 100644
index 00000000000..61d97de5782
--- /dev/null
+++ b/x11/ruby-gtk/pkg/DESCR
@@ -0,0 +1,6 @@
+Ruby extension module to use Gtk+.
+
+WWW: http://www.ueda.info.waseda.ac.jp/~igarashi/ruby/gtk.html
+
+- Yasuhiro Fukuma
+yasuf@big.or.jp
diff --git a/x11/ruby-gtk/pkg/PLIST b/x11/ruby-gtk/pkg/PLIST
new file mode 100644
index 00000000000..edd0a1e93db
--- /dev/null
+++ b/x11/ruby-gtk/pkg/PLIST
@@ -0,0 +1,18 @@
+lib/ruby/%%RUBY_VER%%/%%RUBY_ARCH%%/gtk.so
+lib/ruby/%%RUBY_VER%%/gtkcompat.rb
+share/examples/ruby/gtk/drawing.rb
+share/examples/ruby/gtk/helloworld.rb
+share/examples/ruby/gtk/text.rb
+share/examples/ruby/gtk/texthook.rb
+share/examples/ruby/gtk/browser/gtkbrows.rb
+share/examples/ruby/gtk/browser/rbbr_gtk.rb
+share/examples/ruby/gtk/browser/rbbr_rb.rb
+share/examples/ruby/gtk/browser/rbdump.rb
+@dirrm share/examples/ruby/gtk/browser
+share/examples/ruby/gtk/gdkimlib/sample1.rb
+share/examples/ruby/gtk/gdkimlib/sample2.rb
+share/examples/ruby/gtk/gdkimlib/sample3.rb
+share/examples/ruby/gtk/gdkimlib/sample4.rb
+share/examples/ruby/gtk/gdkimlib/sample5.rb
+@dirrm share/examples/ruby/gtk/gdkimlib
+@dirrm share/examples/ruby/gtk