Add postgresql-plruby, PL/Ruby procedural language for the PostgreSQL

database system.
This commit is contained in:
Akinori MUSHA 2001-06-28 08:52:19 +00:00
parent f76ae5c8f6
commit 7d38e9af5b
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=44519
7 changed files with 119 additions and 0 deletions

View file

@ -64,6 +64,7 @@
SUBDIR += p5-hp200lx-db
SUBDIR += phpmyadmin
SUBDIR += phppgadmin
SUBDIR += postgresql-plruby
SUBDIR += postgresql7
SUBDIR += pxtools
SUBDIR += py-MySQL

View file

@ -0,0 +1,66 @@
# New ports collection makefile for: PL/Ruby
# Date created: 28 June 2001
# Whom: Akinori MUSHA aka knu <knu@idaemons.org>
#
# $FreeBSD$
#
PORTNAME= plruby
PORTVERSION= 0.2.3
CATEGORIES= databases ruby
MASTER_SITES= ftp://moulon.inra.fr/pub/ruby/
PKGNAMEPREFIX= postgresql-
DIST_SUBDIR= ruby
MAINTAINER= knu@FreeBSD.org
LIB_DEPENDS= pq.2:${PGSQL_PORTDIR}
USE_RUBY= yes
USE_RUBY_EXTCONF= yes
PGSQL_VERSION?= 71
PGSQL_PORTDIR?= ${PORTSDIR}/databases/postgresql7
PGSQL_WRKSRC_CMD= cd ${PGSQL_PORTDIR} && ${MAKE} -V WRKSRC
CONFIGURE_ARGS= --with-pgsql-version="${PGSQL_VERSION}" \
--with-pgsql-srcinc-dir="`${PGSQL_WRKSRC_CMD}`/src/include"
.if defined(WITH_OLD_LAYOUT)
CONFIGURE_ARGS+=
--with-pgsql-include-dir="${LOCALBASE}/pgsql/include" \
--with-pgsql-lib-dir="${LOCALBASE}/pgsql/lib"
.else
CONFIGURE_ARGS+= --with-pgsql-include-dir="${LOCALBASE}/include/pgsql" \
--with-pgsql-lib="${LOCALBASE}/lib"
.endif
INSTALL_TARGET= site-install
DOCS= README.en plruby.html plruby.rd
PKGMESSAGE= ${WRKDIR}/createlang.sql
post-patch:
${RUBY} -i -pe 'gsub /test_mklang\.sql/, "../createlang.sql"' \
${WRKSRC}/test/*/runtest
pre-configure:
cd ${PGSQL_PORTDIR} && ${MAKE} -DBATCH patch
post-build:
${SED} 's,!!PLRUBY_SO!!,${RUBY_SITEARCHLIBDIR}/plruby.so,' \
${FILESDIR}/createlang.sql > ${WRKDIR}/createlang.sql
post-install:
.if !defined(NOPORTDOCS)
${MKDIR} ${RUBY_EXAMPLESDIR}/${PORTNAME}/
${CP} -R ${WRKSRC}/test/* ${RUBY_EXAMPLESDIR}/${PORTNAME}/
${INSTALL_DATA} ${WRKDIR}/createlang.sql ${RUBY_EXAMPLESDIR}/${PORTNAME}/
${MKDIR} ${RUBY_DOCDIR}/${PORTNAME}
.for f in ${DOCS}
${INSTALL_DATA} ${WRKSRC}/${f} ${RUBY_DOCDIR}/${PORTNAME}/
.endfor
.endif
@${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>

View file

@ -0,0 +1 @@
MD5 (ruby/plruby-0.2.3.tar.gz) = f958ecde8de88bb083d04c38d4084b46

View file

@ -0,0 +1,15 @@
--
-- Execute the following SQL statements to enable PL/Ruby.
--
-- $FreeBSD$
--
CREATE FUNCTION plruby_call_handler() RETURNS OPAQUE
AS '!!PLRUBY_SO!!'
LANGUAGE 'C';
CREATE TRUSTED PROCEDURAL LANGUAGE 'plruby'
HANDLER plruby_call_handler
LANCOMPILER 'PL/Ruby';
--

View file

@ -0,0 +1 @@
PL/Ruby procedural language for the PostgreSQL database system

View file

@ -0,0 +1,6 @@
PL/Ruby is a loadable procedural language for the PostgreSQL database
system (7.0 or later) that enables to write functions and trigger
procedures in Ruby.
Author: Guy Decoux <ts@moulon.inra.fr>
WWW: http://moulon.inra.fr/ruby/plruby.html

View file

@ -0,0 +1,29 @@
%%RUBY_SITEARCHLIBDIR%%/plruby.so
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/createlang.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/b.rb
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/runtest
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test.expected.65
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test.expected.70
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test.expected.71
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test.out
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test_mklang.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test_queries.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plp/test_setup.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/b.rb
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/runtest
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test.expected.65
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test.expected.70
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test.expected.71
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test.out
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test_mklang.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test_queries.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test_setup.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test_setup_new.sql
%%PORTDOCS%%%%RUBY_EXAMPLESDIR%%/plruby/plt/test_setup_old.sql
%%PORTDOCS%%@dirrm %%RUBY_EXAMPLESDIR%%/plruby/plp
%%PORTDOCS%%@dirrm %%RUBY_EXAMPLESDIR%%/plruby/plt
%%PORTDOCS%%@dirrm %%RUBY_EXAMPLESDIR%%/plruby
%%PORTDOCS%%%%RUBY_DOCDIR%%/plruby/README.en
%%PORTDOCS%%%%RUBY_DOCDIR%%/plruby/plruby.html
%%PORTDOCS%%%%RUBY_DOCDIR%%/plruby/plruby.rd
%%PORTDOCS%%@dirrm %%RUBY_DOCDIR%%/plruby