summaryrefslogtreecommitdiff
path: root/system/multicorn
diff options
context:
space:
mode:
authorAudrius Kažukauskas <audrius@neutrino.lt>2013-04-26 20:59:19 -0300
committerNiels Horn <niels.horn@slackbuilds.org>2013-04-26 20:59:19 -0300
commitf5d3d93becc75ddf9fa5f8607fc1a36d9df57bd0 (patch)
tree5828b9844cbb31a02dfb8fe4ca5462b35627a16e /system/multicorn
parentba43e158ce4260dd338d8796e23aac059d1cedcb (diff)
downloadslackbuilds-f5d3d93becc75ddf9fa5f8607fc1a36d9df57bd0.tar.gz
system/multicorn: Added (PostgreSQL Foreign Data Wrappers)
Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
Diffstat (limited to 'system/multicorn')
-rw-r--r--system/multicorn/README9
-rw-r--r--system/multicorn/multicorn.SlackBuild89
-rw-r--r--system/multicorn/multicorn.info10
-rw-r--r--system/multicorn/slack-desc19
4 files changed, 127 insertions, 0 deletions
diff --git a/system/multicorn/README b/system/multicorn/README
new file mode 100644
index 0000000000..10cb398545
--- /dev/null
+++ b/system/multicorn/README
@@ -0,0 +1,9 @@
+Multicorn is a PostgreSQL 9.1+ extension meant to make Foreign Data
+Wrapper development easy, by allowing the programmer to use the Python
+programming language.
+
+- Multicorn allows you to access any data source in your PostgreSQL
+ database.
+- You can leverage the full power of SQL to query your data sources.
+- Every tool you use for SQL can be reused with those datasources (think
+ about an ORM, BI tool...).
diff --git a/system/multicorn/multicorn.SlackBuild b/system/multicorn/multicorn.SlackBuild
new file mode 100644
index 0000000000..e804aae773
--- /dev/null
+++ b/system/multicorn/multicorn.SlackBuild
@@ -0,0 +1,89 @@
+#!/bin/sh
+
+# Slackware build script for multicorn
+
+# Copyright 2013 Audrius Kažukauskas <audrius@neutrino.lt>
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+PRGNAM=multicorn
+VERSION=${VERSION:-1.0.0beta1}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -eu
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+unzip $CWD/$PRGNAM-$VERSION.zip
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+# Set Python code installation path.
+sed -i "s|install$|install --root=$PKG|" Makefile
+
+CFLAGS="$SLKCFLAGS" make
+make install DESTDIR=$PKG
+
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a CHANGELOG README.md $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/system/multicorn/multicorn.info b/system/multicorn/multicorn.info
new file mode 100644
index 0000000000..f224ddf2d2
--- /dev/null
+++ b/system/multicorn/multicorn.info
@@ -0,0 +1,10 @@
+PRGNAM="multicorn"
+VERSION="1.0.0beta1"
+HOMEPAGE="http://multicorn.org/"
+DOWNLOAD="http://api.pgxn.org/dist/multicorn/1.0.0beta1/multicorn-1.0.0beta1.zip"
+MD5SUM="157206021c3ff5dbc2eb97d55ad1f4f2"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES="distribute postgresql"
+MAINTAINER="Audrius Kažukauskas"
+EMAIL="audrius@neutrino.lt"
diff --git a/system/multicorn/slack-desc b/system/multicorn/slack-desc
new file mode 100644
index 0000000000..3f5276f75b
--- /dev/null
+++ b/system/multicorn/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+multicorn: multicorn (PostgreSQL extension to build Foreign Data Wrappers)
+multicorn:
+multicorn: Multicorn is a PostgreSQL 9.1+ extension meant to make Foreign Data
+multicorn: Wrapper development easy, by allowing the programmer to use the Python
+multicorn: programming language.
+multicorn:
+multicorn: Homepage: http://multicorn.org/
+multicorn:
+multicorn:
+multicorn:
+multicorn: