|
|
|
@ -1,6 +1,6 @@
|
|
|
|
|
#!/bin/bash |
|
|
|
|
# Build script for Slackware |
|
|
|
|
# Copyright (C) 2009 Damien Goutte-Gattat |
|
|
|
|
# Copyright (C) 2009,2011 Damien Goutte-Gattat |
|
|
|
|
# |
|
|
|
|
# Redistribution and use of this script, with or without modifications, |
|
|
|
|
# is permitted provided that the following conditions are met: |
|
|
|
@ -27,14 +27,14 @@
|
|
|
|
|
|
|
|
|
|
# Source package infos |
|
|
|
|
NAMESRC=${NAMESRC:-libproxy} |
|
|
|
|
VERSION=${VERSION:-0.3.1} |
|
|
|
|
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.bz2} |
|
|
|
|
VERSION=${VERSION:-0.4.6} |
|
|
|
|
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz} |
|
|
|
|
WGET=${WGET:-http://libproxy.googlecode.com/files/$ARCHIVE} |
|
|
|
|
|
|
|
|
|
# Build infos |
|
|
|
|
NAMEPKG=${NAMEPKG:-libproxy} |
|
|
|
|
BUILD=${BUILD:-1GGD} |
|
|
|
|
ARCH=${ARCH:-i486} |
|
|
|
|
ARCH=${ARCH:-$(uname -m | sed 's/^i.86$/i486/;s/^arm.*/arm/')} |
|
|
|
|
JOBS=${JOBS:-1} |
|
|
|
|
EXT=${EXT:-txz} |
|
|
|
|
|
|
|
|
@ -84,18 +84,23 @@ cd $TMP
|
|
|
|
|
echo "Building $ARCHIVE..." |
|
|
|
|
tar xf $CWD/$ARCHIVE |
|
|
|
|
cd $NAME |
|
|
|
|
CFLAGS=$CPUOPT \ |
|
|
|
|
CXXFLAGS=$CPUOPT \ |
|
|
|
|
./configure \ |
|
|
|
|
--prefix=/usr \ |
|
|
|
|
--libdir=/usr/lib$LIBDIRSUFFIX \ |
|
|
|
|
--disable-static \ |
|
|
|
|
--without-gnome |
|
|
|
|
mkdir build && cd build |
|
|
|
|
cmake .. \ |
|
|
|
|
-DCMAKE_INSTALL_PREFIX=/usr \ |
|
|
|
|
-DLIB_SUFFIX=$LIBDIRSUFFIX \ |
|
|
|
|
-DPERL_VENDORINSTALL=yes \ |
|
|
|
|
-DCMAKE_CXX_FLAGS="$CPUOPT" \ |
|
|
|
|
-DCMAKE_C_FLAGS="$CPUOPT" |
|
|
|
|
make -j $JOBS |
|
|
|
|
make install-strip DESTDIR=$PKG |
|
|
|
|
make install DESTDIR=$PKG |
|
|
|
|
|
|
|
|
|
# Strip binaries |
|
|
|
|
find $PKG | xargs file | grep "ELF \(32\|64\)-bit LSB" | cut -d : -f 1 | \ |
|
|
|
|
xargs strip --strip-unneeded 2> /dev/null |
|
|
|
|
|
|
|
|
|
# Install the documentation |
|
|
|
|
mkdir -p $PKG/usr/doc/$NAME |
|
|
|
|
cd .. |
|
|
|
|
install -m 644 AUTHORS COPYING ChangeLog NEWS README $PKG/usr/doc/$NAME |
|
|
|
|
|
|
|
|
|
# Copy slack-desc file |
|
|
|
|