mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
development/swig: Initial import
This commit is contained in:
parent
529ccd9e1f
commit
a1ee41f337
4 changed files with 105 additions and 0 deletions
17
development/swig/README
Normal file
17
development/swig/README
Normal file
|
@ -0,0 +1,17 @@
|
|||
SWIG is a software development tool that connects programs written
|
||||
in C and C++ with a variety of high-level programming languages.
|
||||
|
||||
SWIG is used with different types of languages including common scripting
|
||||
languages such as Perl, PHP, Python, Tcl, Ruby and PHP. The list of supported
|
||||
languages also includes non-scripting languages such as C#, Common Lisp
|
||||
(CLISP, Allegro CL, CFFI, UFFI), Java, Modula-3 and OCAML. Also several
|
||||
interpreted and compiled Scheme implementations (Guile, MzScheme, Chicken) are
|
||||
supported. SWIG is most commonly used to create high-level interpreted or
|
||||
compiled programming environments, user interfaces, and as a tool for testing
|
||||
and prototyping C/C++ software. SWIG can also export its parse tree in the
|
||||
form of XML and Lisp s-expressions.
|
||||
|
||||
swig may build with support for the following:
|
||||
Tcl, Python, Perl, Java, GCJ, Guile, MzScheme, Ruby, PHP4, ocaml, Pike
|
||||
Chicken (csc/csi), C#, Lua, Allegro CL, clisp, R
|
||||
|
11
development/swig/slack-desc
Normal file
11
development/swig/slack-desc
Normal file
|
@ -0,0 +1,11 @@
|
|||
swig: swig (interface compiler to connect C/C++ with scripting languages)
|
||||
swig:
|
||||
swig: SWIG is an interface compiler that connects programs written in C and
|
||||
swig: C++ with scripting languages such as Perl, Python, Ruby, and Tcl. It
|
||||
swig: works by taking the declarations found in C/C++ header files and using
|
||||
swig: them to generate the wrapper code that scripting languages need to
|
||||
swig: access the underlying C/C++ code. In addition, SWIG provides a variety
|
||||
swig: of customization features that let you tailor the wrapping process to
|
||||
swig: suit your application.
|
||||
swig:
|
||||
swig:
|
69
development/swig/swig.SlackBuild
Normal file
69
development/swig/swig.SlackBuild
Normal file
|
@ -0,0 +1,69 @@
|
|||
#!/bin/sh
|
||||
|
||||
## Written by hollywoodb (hollywoodb@fastmail.fm)
|
||||
|
||||
## Feel free to use, modify, redistribute this script.
|
||||
## If you make changes please modify the "Written by"
|
||||
## so that I don't recieve emails about a script I
|
||||
## did not write. Thanks.
|
||||
|
||||
# Modified by the SlackBuilds.org project
|
||||
|
||||
if [ "$(id -u)" != "0" ]; then
|
||||
echo "This script must be run as root!"
|
||||
exit
|
||||
fi
|
||||
|
||||
NAME=swig
|
||||
VERSION=1.3.31
|
||||
ARCH=${ARCH:-i486}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
CWD=`pwd`
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
PKG=${PKG:-$TMP/package-$NAME}
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
rm -rf $PKG $TMP/$NAME-$VERSION
|
||||
mkdir -p $TMP $PKG $OUTPUT
|
||||
cd $TMP || exit 1
|
||||
tar -zxvf $CWD/$NAME-$VERSION.tar.gz || exit 1
|
||||
cd $NAME-$VERSION || exit 1
|
||||
|
||||
chown -R root:root .
|
||||
chmod -R u+w,go+r-w,a-s .
|
||||
|
||||
if [ "$ARCH" = "i486" ]; then
|
||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||
fi
|
||||
|
||||
CFLAGS="$SLKCFLAGS" \
|
||||
CXXFLAGS="$SLKCFLAGS" \
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--exec-prefix=/usr \
|
||||
--sysconfdir=/etc \
|
||||
--localstatedir=/var \
|
||||
|| exit 1
|
||||
|
||||
make || exit 1
|
||||
make install DESTDIR=$PKG || exit 1
|
||||
|
||||
find $PKG | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
|
||||
find $PKG | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
|
||||
|
||||
mkdir -p $PKG/usr/doc/$NAME-$VERSION
|
||||
cp -a ANNOUNCE CHANGES* FUTURE INSTALL LICENSE NEW README TODO Examples/ \
|
||||
Doc/Manual Doc/Devel $PKG/usr/doc/$NAME-$VERSION
|
||||
cat $CWD/$NAME.SlackBuild > $PKG/usr/doc/$NAME-$VERSION/$NAME.SlackBuild
|
||||
# Fix permissions and wipe the pdf bloat
|
||||
find $PKG/usr/doc/$NAME-$VERSION -type f -exec chmod 0644 {} \;
|
||||
find $PKG/usr/doc/$NAME-$VERSION -name "*.pdf" -exec rm {} \;
|
||||
|
||||
mkdir -p $PKG/install
|
||||
cat $CWD/slack-desc > $PKG/install/slack-desc
|
||||
|
||||
cd $PKG
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$NAME-$VERSION-$ARCH-$BUILD$TAG.tgz
|
8
development/swig/swig.info
Normal file
8
development/swig/swig.info
Normal file
|
@ -0,0 +1,8 @@
|
|||
PRGNAM="swig"
|
||||
VERSION="1.3.31"
|
||||
HOMEPAGE="http://www.swig.org/"
|
||||
DOWNLOAD="http://dl.sourceforge.net/swig/swig-1.3.31.tar.gz"
|
||||
MD5SUM="4a0bae63e3713e89b26db7209b6a7e05"
|
||||
MAINTAINER="hollywoodb"
|
||||
EMAIL="hollywoodb@fastmail.fm"
|
||||
APPROVED="robw810,BP{k}"
|
Loading…
Reference in a new issue