summaryrefslogtreecommitdiff
path: root/libraries
diff options
context:
space:
mode:
authorPhil Warner <pc_warner@yahoo.com>2010-05-11 20:00:40 +0200
committerRobby Workman <rworkman@slackbuilds.org>2010-05-11 20:00:40 +0200
commit4a2b02007af14ee2f060660e939298d5e4c97b47 (patch)
tree9182aae84a96a250f66efdd5d5c66f9e298fff69 /libraries
parent8b2d48c7c35b27c8dfd9facb8af23bd8ea87f625 (diff)
downloadslackbuilds-4a2b02007af14ee2f060660e939298d5e4c97b47.tar.gz
libraries/FreeImage: Added to 12.0 repository
Diffstat (limited to 'libraries')
-rw-r--r--libraries/FreeImage/FreeImage.SlackBuild57
-rw-r--r--libraries/FreeImage/FreeImage.info8
-rw-r--r--libraries/FreeImage/Makefile.fip.DESTDIR.diff44
-rw-r--r--libraries/FreeImage/Makefile.gnu.DESTDIR.diff42
-rw-r--r--libraries/FreeImage/README7
-rw-r--r--libraries/FreeImage/slack-desc19
6 files changed, 177 insertions, 0 deletions
diff --git a/libraries/FreeImage/FreeImage.SlackBuild b/libraries/FreeImage/FreeImage.SlackBuild
new file mode 100644
index 0000000000..46b6b1927d
--- /dev/null
+++ b/libraries/FreeImage/FreeImage.SlackBuild
@@ -0,0 +1,57 @@
+#!/bin/sh
+
+# Slackware build script for FreeImage/FreeImagePlus
+# Written by Phil Warner <pc_warner@yahoo.com>
+
+# Modified by Robby Workman <rworkman@slackbuilds.org>
+# with two patches to fix up DESTDIR support :-)
+
+PRGNAM=FreeImage
+VERSION=3.10.0
+ARCH=${ARCH:-i486}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM
+unzip $CWD/${PRGNAM}$(echo $VERSION | tr -d .)
+cd $PRGNAM
+chown -R root:root .
+chmod -R a-s,u+rw,go-w .
+
+patch -p1 < $CWD/Makefile.gnu.DESTDIR.diff
+patch -p1 < $CWD/Makefile.fip.DESTDIR.diff
+
+CFLAGS="$SLKCFLAGS" CXXFLAGS="$SLKCFLAGS" make
+make install DESTDIR=$PKG
+CFLAGS="$SLKCFLAGS" CXXFLAGS="$SLKCFLAGS" make -f Makefile.fip
+make -f Makefile.fip install DESTDIR=$PKG
+
+( cd $PKG
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+)
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a README.linux license-*.txt Whatsnew.txt $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.tgz
diff --git a/libraries/FreeImage/FreeImage.info b/libraries/FreeImage/FreeImage.info
new file mode 100644
index 0000000000..665dc05654
--- /dev/null
+++ b/libraries/FreeImage/FreeImage.info
@@ -0,0 +1,8 @@
+PRGNAM="FreeImage"
+VERSION="3.10.0"
+HOMEPAGE="http://freeimage.sourceforge.net/"
+DOWNLOAD="http://downloads.sourceforge.net/freeimage/FreeImage3100.zip"
+MD5SUM="2e57135e26bb487cc8e13ee7b7e0a595"
+MAINTAINER="Phil Warner"
+EMAIL="pc_warner@yahoo.com"
+APPROVED="rworkman"
diff --git a/libraries/FreeImage/Makefile.fip.DESTDIR.diff b/libraries/FreeImage/Makefile.fip.DESTDIR.diff
new file mode 100644
index 0000000000..acb9af1a4a
--- /dev/null
+++ b/libraries/FreeImage/Makefile.fip.DESTDIR.diff
@@ -0,0 +1,44 @@
+Patch generated 20071214 by Robby Workman <rworkman@slackbuilds.org>
+Permission granted to use this patch as you see fit.
+
+--- FreeImage/Makefile.fip.orig 2007-12-14 13:53:23.424826247 -0600
++++ FreeImage/Makefile.fip 2007-12-14 14:21:10.427625070 -0600
+@@ -14,13 +14,13 @@
+ # Converts cr/lf to just lf
+ DOS2UNIX = dos2unix
+
+-COMPILERFLAGS = -O3 -fexceptions -fvisibility=hidden
++COMPILERFLAGS = -fexceptions -fvisibility=hidden
+ LIBRARIES = -lstdc++
+
+ MODULES = $(SRCS:.c=.o)
+ MODULES := $(MODULES:.cpp=.o)
+-CFLAGS = $(COMPILERFLAGS) $(INCLUDE)
+-CXXFLAGS = $(COMPILERFLAGS) -Wno-ctor-dtor-privacy $(INCLUDE)
++CFLAGS += $(COMPILERFLAGS) $(INCLUDE)
++CXXFLAGS += $(COMPILERFLAGS) -Wno-ctor-dtor-privacy $(INCLUDE)
+
+ TARGET = freeimageplus
+ STATICLIB = lib$(TARGET).a
+@@ -59,13 +59,14 @@
+ $(CC) -s -shared -Wl,-soname,$(VERLIBNAME) -o $@ $(MODULES) $(LIBRARIES)
+
+ install:
+- install -m 644 -o root -g root $(HEADER) $(INCDIR)
+- install -m 644 -o root -g root $(HEADERFIP) $(INCDIR)
+- install -m 644 -o root -g root $(STATICLIB) $(INSTALLDIR)
+- install -m 755 -o root -g root $(SHAREDLIB) $(INSTALLDIR)
+- ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(VERLIBNAME)
+- ln -sf $(VERLIBNAME) $(INSTALLDIR)/$(LIBNAME)
+- ldconfig
++ install -d 755 $(DESTDIR)/$(INCDIR)
++ install -m 644 $(HEADER) $(DESTDIR)/$(INCDIR)
++ install -m 644 $(HEADERFIP) $(DESTDIR)/$(INCDIR)
++ install -d 755 $(DESTDIR)/$(INSTALLDIR)
++ install -m 644 $(STATICLIB) $(DESTDIR)/$(INSTALLDIR)
++ install -m 755 $(SHAREDLIB) $(DESTDIR)/$(INSTALLDIR)
++ cd $(DESTDIR)/$(INSTALLDIR) ; ln -sf $(SHAREDLIB) $(VERLIBNAME)
++ cd $(DESTDIR)/$(INSTALLDIR) ; ln -sf $(VERLIBNAME) $(LIBNAME)
+
+ clean:
+ rm -f core Dist/*.* u2dtmp* $(MODULES) $(STATICLIB) $(SHAREDLIB) $(LIBNAME)
diff --git a/libraries/FreeImage/Makefile.gnu.DESTDIR.diff b/libraries/FreeImage/Makefile.gnu.DESTDIR.diff
new file mode 100644
index 0000000000..d9e94b4483
--- /dev/null
+++ b/libraries/FreeImage/Makefile.gnu.DESTDIR.diff
@@ -0,0 +1,42 @@
+Patch generated 20071214 by Robby Workman <rworkman@slackbuilds.org>
+Permission granted to use this patch as you see fit.
+
+--- FreeImage/Makefile.gnu.orig 2007-12-14 13:34:39.717234989 -0600
++++ FreeImage/Makefile.gnu 2007-12-14 13:52:18.417121669 -0600
+@@ -14,13 +14,13 @@
+ # Converts cr/lf to just lf
+ DOS2UNIX = dos2unix
+
+-COMPILERFLAGS = -O3 -fPIC -fexceptions -fvisibility=hidden
++COMPILERFLAGS = -fPIC -fexceptions -fvisibility=hidden
+ LIBRARIES = -lstdc++
+
+ MODULES = $(SRCS:.c=.o)
+ MODULES := $(MODULES:.cpp=.o)
+-CFLAGS = $(COMPILERFLAGS) $(INCLUDE)
+-CXXFLAGS = $(COMPILERFLAGS) -Wno-ctor-dtor-privacy $(INCLUDE)
++CFLAGS += $(COMPILERFLAGS) $(INCLUDE)
++CXXFLAGS += $(COMPILERFLAGS) -Wno-ctor-dtor-privacy $(INCLUDE)
+
+ TARGET = freeimage
+ STATICLIB = lib$(TARGET).a
+@@ -58,12 +58,13 @@
+ $(CC) -s -shared -Wl,-soname,$(VERLIBNAME) -o $@ $(MODULES) $(LIBRARIES)
+
+ install:
+- install -m 644 -o root -g root $(HEADER) $(INCDIR)
+- install -m 644 -o root -g root $(STATICLIB) $(INSTALLDIR)
+- install -m 755 -o root -g root $(SHAREDLIB) $(INSTALLDIR)
+- ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(VERLIBNAME)
+- ln -sf $(VERLIBNAME) $(INSTALLDIR)/$(LIBNAME)
+- ldconfig
++ install -d 755 $(DESTDIR)/$(INCDIR)
++ install -m 644 $(HEADER) $(DESTDIR)/$(INCDIR)
++ install -d 755 $(DESTDIR)/$(INSTALLDIR)
++ install -m 644 $(STATICLIB) $(DESTDIR)/$(INSTALLDIR)
++ install -m 755 $(SHAREDLIB) $(DESTDIR)/$(INSTALLDIR)
++ cd $(DESTDIR)/$(INSTALLDIR) ; ln -sf $(SHAREDLIB) $(VERLIBNAME)
++ cd $(DESTDIR)/$(INSTALLDIR) ; ln -sf $(VERLIBNAME) $(LIBNAME)
+
+ clean:
+ rm -f core Dist/*.* u2dtmp* $(MODULES) $(STATICLIB) $(SHAREDLIB) $(LIBNAME)
diff --git a/libraries/FreeImage/README b/libraries/FreeImage/README
new file mode 100644
index 0000000000..1ff183df5c
--- /dev/null
+++ b/libraries/FreeImage/README
@@ -0,0 +1,7 @@
+FreeImage - image library
+
+FreeImage is an Open Source library project for developers who would like
+to support popular graphics image formats like PNG, BMP, JPEG, TIFF and
+others as needed by today's multimedia applications. FreeImage is easy to
+use, fast, and multithreading safe.
+This script compiles the FreeImage library and the FreeImagePlus C++ wrapper.
diff --git a/libraries/FreeImage/slack-desc b/libraries/FreeImage/slack-desc
new file mode 100644
index 0000000000..922a9bb49f
--- /dev/null
+++ b/libraries/FreeImage/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 ':'.
+
+ |-----handy-ruler--------------------------------------------------|
+FreeImage: FreeImage (image library)
+FreeImage:
+FreeImage: FreeImage is an Open Source library project for developers who
+FreeImage: want to support popular graphics image formats like PNG, BMP,
+FreeImage: JPEG, TIFF and others needed by today's multimedia applications.
+FreeImage: FreeImage is easy to use, fast, and multithreading safe.
+FreeImage: FreeImagePlus is a C++ wrapper for FreeImage.
+FreeImage:
+FreeImage: http://freeimage.sourceforge.net/
+FreeImage:
+FreeImage: