summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2005-08-07 13:23:17 +0000
committerFabian Groffen <grobian@gentoo.org>2005-08-07 13:23:17 +0000
commit882e9b1ec42a795ee4aa091b361ce9f119c69ffe (patch)
tree68acfc22f397ec08e378af792280591057382b21 /dev-db/monetdb/files
parentStable on ppc. (diff)
downloadgentoo-2-882e9b1ec42a795ee4aa091b361ce9f119c69ffe.tar.gz
gentoo-2-882e9b1ec42a795ee4aa091b361ce9f119c69ffe.tar.bz2
gentoo-2-882e9b1ec42a795ee4aa091b361ce9f119c69ffe.zip
Initial import of monetdb ebuild
(Portage version: 2.0.51.22-r2)
Diffstat (limited to 'dev-db/monetdb/files')
-rw-r--r--dev-db/monetdb/files/digest-monetdb-4.8.24
-rw-r--r--dev-db/monetdb/files/monetdb-4.8.2-gentoo-MapiClient.patch11
-rw-r--r--dev-db/monetdb/files/monetdb-4.8.2-gentoo-conf.patch32
-rw-r--r--dev-db/monetdb/files/monetdb-4.8.2-startup.mil28
-rw-r--r--dev-db/monetdb/files/monetdb-start.sh16
-rw-r--r--dev-db/monetdb/files/monetdb-stop.sh26
-rw-r--r--dev-db/monetdb/files/monetdb.conf-4.8.215
-rw-r--r--dev-db/monetdb/files/monetdb.init-4.8.217
-rw-r--r--dev-db/monetdb/files/monetdb_config.sh21
9 files changed, 170 insertions, 0 deletions
diff --git a/dev-db/monetdb/files/digest-monetdb-4.8.2 b/dev-db/monetdb/files/digest-monetdb-4.8.2
new file mode 100644
index 000000000000..ce79c605363a
--- /dev/null
+++ b/dev-db/monetdb/files/digest-monetdb-4.8.2
@@ -0,0 +1,4 @@
+MD5 5504707be924ec2c283d2285f72444d5 MonetDB-4.8.2.tar.gz 21260095
+MD5 76d4d4005675b7ed18cf98579124dbfe MonetDB-SQL-2.8.2.tar.gz 1063441
+MD5 5dec7614cd1835e6c1898eb8bb337ac4 MonetDB-XQuery-0.8.2.tar.gz 873414
+MD5 436151071d03a7256a419b779d0c834c monetdb-pathfinder-bison-sources-0.8.2.tar.bz2 79380
diff --git a/dev-db/monetdb/files/monetdb-4.8.2-gentoo-MapiClient.patch b/dev-db/monetdb/files/monetdb-4.8.2-gentoo-MapiClient.patch
new file mode 100644
index 000000000000..e7e25ac4e751
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb-4.8.2-gentoo-MapiClient.patch
@@ -0,0 +1,11 @@
+--- MonetDB-4.8.2/src/mapi/clients/C/MapiClient.mx 2005-01-21 17:25:11.000000000 +0100
++++ MapiClient.mx 2005-02-09 13:34:51.251310750 +0100
+@@ -1285,7 +1285,7 @@
+ {
+ opt *set = NULL;
+ int setlen;
+- char *language = "mil";
++ char *language = "sql";
+ int port = 0;
+ char *user = NULL;
+ char *passwd = NULL;
diff --git a/dev-db/monetdb/files/monetdb-4.8.2-gentoo-conf.patch b/dev-db/monetdb/files/monetdb-4.8.2-gentoo-conf.patch
new file mode 100644
index 000000000000..7f7a83e0b9e6
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb-4.8.2-gentoo-conf.patch
@@ -0,0 +1,32 @@
+--- MonetDB-4.8.2/conf/MonetDB.conf.in 2004-10-26 02:02:16.000000000 +0200
++++ MonetDB.conf.in 2004-10-28 21:04:52.958269189 +0200
+@@ -20,7 +20,7 @@
+ # the name of the database to use below. Note that you can use
+ # multiple databases, but that you have to edit the database name
+ # and restart MonetDB.
+-gdk_dbname=demo
++gdk_dbname=default
+
+ # The options below deal with various aspects of memory usage behaviour.
+ # If you don't know what these values mean, you should leave them alone.
+@@ -64,11 +64,6 @@
+ #
+ #gdk_version <ver> create BATs in old formats[out of date?]
+
+-
+-# General client Section
+-#=======================
+-#host=localhost #the host the server runs on
+-
+ # MonetDB Section
+ #================
+ # Administrator user name
+@@ -81,7 +76,7 @@
+ # Where do the MonetDB modules reside?
+ monet_mod_path=@libdir@@DIRSEP@@PACKAGE@
+ # Start Mserver in daemon mode, or start with MIL interactive interface?
+-monet_daemon=no
++monet_daemon=yes
+
+ # Monet Application Interface Section
+ #====================================
diff --git a/dev-db/monetdb/files/monetdb-4.8.2-startup.mil b/dev-db/monetdb/files/monetdb-4.8.2-startup.mil
new file mode 100644
index 000000000000..4698229c174d
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb-4.8.2-startup.mil
@@ -0,0 +1,28 @@
+# Gentoo MonetDB startup.mil script -- Fabian Groffen grobian@gentoo.org
+#
+# This script starts the SQL, XQuery and Mapi modules and activates a
+# listening socket for all of them on their default port. This results
+# in three ports of your system being occupied. By default the ports
+# are as follows:
+# SQL server: 45123
+# XQuery server: 45789
+# Mapi server: 50000
+
+# should connections be bound to localhost or 0.0.0.0? Set to true here
+# to allow foreign connections. Defaults to false (only local).
+var allow_foreign_connections := false;
+
+#
+# If were only looking for whatever you could change, you can stop
+# reading at this point and save your changes. Don't change anything
+# below if you don't know what you're doing.
+#
+
+module(sql_server);
+sql_server_start(allow_foreign_connections);
+
+module(pathfinder);
+xquery_server_start(allow_foreign_connections);
+
+module(mapi);
+mapi_start(allow_foreign_connections);
diff --git a/dev-db/monetdb/files/monetdb-start.sh b/dev-db/monetdb/files/monetdb-start.sh
new file mode 100644
index 000000000000..b43f4d924e3b
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb-start.sh
@@ -0,0 +1,16 @@
+#! /bin/sh
+
+LOG=/var/log/monetdb/Mserver.log
+echo `date` Starting MonetDB >> $LOG
+/usr/bin/Mserver $@ >> $LOG 2>&1 &
+MPID=$!
+echo `date` Mserver started, PID: $MPID >> $LOG
+rm -f ~monetdb/Mserver.pid > /dev/null
+sleep 2
+ALIVE=`ps --no-heading --format pid -p $MPID`
+if [ $ALIVE -eq $MPID ]; then
+ echo $MPID > ~monetdb/Mserver.pid
+else
+ echo Mserver died immediately
+ exit -1
+fi
diff --git a/dev-db/monetdb/files/monetdb-stop.sh b/dev-db/monetdb/files/monetdb-stop.sh
new file mode 100644
index 000000000000..aa562e814f98
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb-stop.sh
@@ -0,0 +1,26 @@
+#! /bin/sh
+
+LOG=/var/log/monetdb/Mserver.log
+if [ -f ~monetdb/Mserver.pid ]; then
+ MPID=`cat ~monetdb/Mserver.pid`
+else
+ echo "No Mserver PID found"
+ exit -1
+fi
+
+echo `date` Stopping MonetDB \(PID: $MPID\) >> $LOG
+kill -TERM $MPID || exit -1
+sleep 1
+ALIVE=`ps --no-heading --format pid -p $MPID`
+if [ "$ALIVE" = "$MPID" ]; then
+ echo Mserver still alive after TERM, trying KILL... >> $LOG
+ kill -KILL $MPID
+ sleep 2
+ ALIVE=`ps --no-heading --format pid -p $MPID`
+ if [ "$ALIVE" = "$MPID" ]; then
+ echo "Failed to stop process $MPID"
+ exit -1
+ fi
+fi
+echo `date` Mserver stopped >> $LOG
+rm -f ~monetdb/Mserver.pid > /dev/null
diff --git a/dev-db/monetdb/files/monetdb.conf-4.8.2 b/dev-db/monetdb/files/monetdb.conf-4.8.2
new file mode 100644
index 000000000000..cfc4abd12099
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb.conf-4.8.2
@@ -0,0 +1,15 @@
+# The user to run the MonetDB database as. It is recommended to
+# leave this as is, portage created this user during installation
+MDB_USER=monetdb
+MDB_GROUP=monetdb
+
+# MonetDB must be started with a startup script which tells it what
+# to do. Most users will not want to change this startup script
+# as it loads the SQL, XQuery (pathfinder) and Mapi modules which
+# allow for SQL, XQuery and MIL connections.
+# If you have special demands, point this variable to your own script
+# which contains the desired commands.
+# Note: for security reasons by default all listening connections are
+# bound to 127.0.0.1. If you need connections to be bound at 0.0.0.0
+# have a look at the default startup script to enable this.
+MDB_STARTUPSCRIPTS=~monetdb/monetdb-startup.mil
diff --git a/dev-db/monetdb/files/monetdb.init-4.8.2 b/dev-db/monetdb/files/monetdb.init-4.8.2
new file mode 100644
index 000000000000..5b58a8bcc4e5
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb.init-4.8.2
@@ -0,0 +1,17 @@
+#!/sbin/runscript
+
+depend() {
+ use net
+}
+
+start() {
+ ebegin "Starting MonetDB"
+ start-stop-daemon -c $MDB_USER:$MDB_GROUP --start --exec ~monetdb/monetdb-start.sh -- $MDB_STARTUPSCRIPTS
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping MonetDB"
+ start-stop-daemon -c $MDB_USER:$MDB_GROUP --start --exec ~monetdb/monetdb-stop.sh
+ eend $?
+}
diff --git a/dev-db/monetdb/files/monetdb_config.sh b/dev-db/monetdb/files/monetdb_config.sh
new file mode 100644
index 000000000000..eab7f36cc5f5
--- /dev/null
+++ b/dev-db/monetdb/files/monetdb_config.sh
@@ -0,0 +1,21 @@
+#! /bin/sh
+
+MYINCLUDES="-I$_MONETDB_INCLUDEDIR \
+ -I$_MONETDB_INCLUDEDIR/common \
+ -I$_MONETDB_INCLUDEDIR/gdk \
+ -I$_MONETDB_INCLUDEDIR/monet \
+ -I$_MONETDB_INCLUDEDIR/plain \
+ -I$_MONETDB_INCLUDEDIR/contrib \
+ -I$_MONETDB_INCLUDEDIR/mapi \
+ -I$_MONETDB_INCLUDEDIR/C"
+
+case $1 in
+ --version ) echo $_MONETDB_VERSION; break;;
+ --cflags ) echo $MYINCLUDES; break;;
+ --includes ) echo $MYINCLUDES; break;;
+ --pkgincludedir ) echo $_MONETDB_INCLUDEDIR; break;;
+ --libs ) echo $_MONETDB_LIBS; break;;
+ --modpath ) echo $_MONETDB_MOD_PATH; break;;
+ --prefix ) echo $_MONETDB_PREFIX; break;;
+ --classpath ) echo $_MONETDB_CLASSPATH; break;;
+esac