aboutsummaryrefslogtreecommitdiffstats
path: root/databases
diff options
context:
space:
mode:
authorPhilip M. Gollucci <pgollucci@FreeBSD.org>2010-12-12 12:10:34 +0800
committerPhilip M. Gollucci <pgollucci@FreeBSD.org>2010-12-12 12:10:34 +0800
commit8789a9f61cdb628c6d4ca5cc31698cb60a298e57 (patch)
tree92100f0927cf9207e05ac63d4feb7293c4a05445 /databases
parentbdfce06846bbeca0134e6e31923e757e533c927a (diff)
downloadfreebsd-ports-gnome-8789a9f61cdb628c6d4ca5cc31698cb60a298e57.tar.gz
freebsd-ports-gnome-8789a9f61cdb628c6d4ca5cc31698cb60a298e57.tar.zst
freebsd-ports-gnome-8789a9f61cdb628c6d4ca5cc31698cb60a298e57.zip
Ruby/OCI8 is a ruby interface for Oracle using OCI8 API.
PR: ports/111501 Submitted by: Simun Mikecin <numisemis at yahoo dot com>
Diffstat (limited to 'databases')
-rw-r--r--databases/Makefile1
-rw-r--r--databases/ruby-oci8/Makefile42
-rw-r--r--databases/ruby-oci8/distinfo3
-rw-r--r--databases/ruby-oci8/files/patch-ext_oci8_oraconf.rb47
-rw-r--r--databases/ruby-oci8/pkg-descr1
-rw-r--r--databases/ruby-oci8/pkg-plist9
6 files changed, 103 insertions, 0 deletions
diff --git a/databases/Makefile b/databases/Makefile
index 5d4ef03602d4..ef3f36a444d0 100644
--- a/databases/Makefile
+++ b/databases/Makefile
@@ -703,6 +703,7 @@
SUBDIR += ruby-msql
SUBDIR += ruby-mysql
SUBDIR += ruby-o_dbm
+ SUBDIR += ruby-oci8
SUBDIR += ruby-odbc
SUBDIR += ruby-pg
SUBDIR += ruby-postgres
diff --git a/databases/ruby-oci8/Makefile b/databases/ruby-oci8/Makefile
new file mode 100644
index 000000000000..e8e3ec427b07
--- /dev/null
+++ b/databases/ruby-oci8/Makefile
@@ -0,0 +1,42 @@
+# New ports collection makefile for: ruby-oci8
+# Date created: 10 April 2007
+# Whom: Simun Mikecin <numisemis at yahoo dot com>
+#
+# $FreeBSD$
+#
+
+PORTNAME= oci8
+DISTVERSION= 1.0.0rc1
+CATEGORIES= databases ruby
+MASTER_SITES= RF
+MASTER_SITE_SUBDIR=ruby-oci8
+PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX}
+DISTNAME= ruby-${PORTNAME}-${DISTVERSION:S/rc/-rc/}
+DIST_SUBDIR= ruby
+
+MAINTAINER= numisemis@yahoo.com
+COMMENT= Ruby interface to Oracle OCI8
+
+BUILD_DEPENDS= ${LOCALBASE}/oracle8-client/lib/libclntsh.a:${PORTSDIR}/databases/oracle8-client
+RUN_DEPENDS= ${LOCALBASE}/oracle8-client/lib/libclntsh.a:${PORTSDIR}/databases/oracle8-client
+
+MAKE_JOBS_UNSAFE= yes
+
+USE_RUBY= yes
+USE_RUBY_EXTCONF= yes
+RUBY_EXTCONF_SUBDIRS= ext/oci8
+
+CONFIGURE_ARGS= --with-instant-client="${LOCALBASE}/oracle8-client/lib"
+INSTALL_TARGET= site-install
+
+DOCS_EN= ChangeLog README
+
+post-install:
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${RUBY_MODDOCDIR}
+.for f in ${DOCS_EN}
+ ${INSTALL_DATA} ${WRKSRC}/${f} ${RUBY_MODDOCDIR}/
+.endfor
+.endif
+
+.include <bsd.port.mk>
diff --git a/databases/ruby-oci8/distinfo b/databases/ruby-oci8/distinfo
new file mode 100644
index 000000000000..92a7c17feb75
--- /dev/null
+++ b/databases/ruby-oci8/distinfo
@@ -0,0 +1,3 @@
+MD5 (ruby/ruby-oci8-1.0.0-rc1.tar.gz) = 34fee64959f5c8317c9349050b1a79e8
+SHA256 (ruby/ruby-oci8-1.0.0-rc1.tar.gz) = 69012e2813d1d41d716c78de6bf44af8951838c16c6f670c962d30ebff9f3ad9
+SIZE (ruby/ruby-oci8-1.0.0-rc1.tar.gz) = 92989
diff --git a/databases/ruby-oci8/files/patch-ext_oci8_oraconf.rb b/databases/ruby-oci8/files/patch-ext_oci8_oraconf.rb
new file mode 100644
index 000000000000..249fe9f00acf
--- /dev/null
+++ b/databases/ruby-oci8/files/patch-ext_oci8_oraconf.rb
@@ -0,0 +1,47 @@
+--- ext/oci8/oraconf.rb.orig Fri Jan 19 15:50:28 2007
++++ ext/oci8/oraconf.rb Thu Apr 12 10:58:36 2007
+@@ -197,6 +197,8 @@
+ when /darwin/
+ @@ld_envs = %w[DYLD_LIBRARY_PATH]
+ so_ext = 'dylib'
++ when /freebsd/
++ return "/usr/local/oracle8-client/lib"
+ end
+
+ glob_name = "#{oci_basename}.#{so_ext}#{oci_glob_postfix}"
+@@ -720,7 +722,8 @@
+ @libs = get_libs("#{ic_dir}/sdk")
+ ld_path = nil
+ else
+- @cflags = " -I#{inc_dir}"
++ @cflags = ''
++ @libs = ''
+ # set ld_path and so_ext
+ case RUBY_PLATFORM
+ when /aix/
+@@ -736,10 +739,16 @@
+ when /darwin/
+ ld_path = 'DYLD_LIBRARY_PATH'
+ so_ext = 'dylib'
++ when /freebsd/
++ so_ext = 'a'
++ inc_dir = "#{ic_dir}/../rdbms/demo"
++ @cflags = " -I#{ic_dir}/../rdbms/public"
++ @libs = " -lcompat"
+ else
+ ld_path = 'LD_LIBRARY_PATH'
+ so_ext = 'so'
+ end
++ @cflags += " -I#{inc_dir}"
+ # check Oracle client library.
+ unless File.exists?("#{lib_dir}/libclntsh.#{so_ext}")
+ files = Dir.glob("#{lib_dir}/libclntsh.#{so_ext}.*")
+@@ -761,7 +770,7 @@
+ end
+ raise 'failed'
+ end
+- @libs = " -L#{lib_dir} -lclntsh "
++ @libs += " -L#{lib_dir} -lclntsh "
+ end
+ unless File.exists?("#{inc_dir}/oci.h")
+ raise <<EOS
diff --git a/databases/ruby-oci8/pkg-descr b/databases/ruby-oci8/pkg-descr
new file mode 100644
index 000000000000..4e13567b7a5b
--- /dev/null
+++ b/databases/ruby-oci8/pkg-descr
@@ -0,0 +1 @@
+Ruby/OCI8 is a ruby interface for Oracle using OCI8 API.
diff --git a/databases/ruby-oci8/pkg-plist b/databases/ruby-oci8/pkg-plist
new file mode 100644
index 000000000000..1ca3e6c49e5b
--- /dev/null
+++ b/databases/ruby-oci8/pkg-plist
@@ -0,0 +1,9 @@
+%%RUBY_SITEARCHLIBDIR%%/oci8lib.so
+%%RUBY_SITELIBDIR%%/DBD/OCI8/OCI8.rb
+%%RUBY_SITELIBDIR%%/oci8.rb
+%%PORTDOCS%%%%RUBY_MODDOCDIR%%/ChangeLog
+%%PORTDOCS%%%%RUBY_MODDOCDIR%%/README
+%%PORTDOCS%%@dirrm %%RUBY_MODDOCDIR%%
+@dirrm %%RUBY_SITELIBDIR%%/DBD/OCI8
+@dirrmtry %%RUBY_SITELIBDIR%%/DBD/
+