From d341df871d3c7badc4d46c7475fdee98e2c25616 Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Fri, 4 Jun 2010 14:12:18 +0000 Subject: Rebuilt for Slackware 13.1 --- freenx/build/freenx-client.SlackBuild | 46 ++++++++++++++++++++++------------- 1 file changed, 29 insertions(+), 17 deletions(-) diff --git a/freenx/build/freenx-client.SlackBuild b/freenx/build/freenx-client.SlackBuild index ca8e97e0..aa42ee09 100755 --- a/freenx/build/freenx-client.SlackBuild +++ b/freenx/build/freenx-client.SlackBuild @@ -1,6 +1,6 @@ #!/bin/sh # $Id$ -# Copyright (c) 2008 Eric Hameleers +# Copyright (c) 2008,2010 Eric Hameleers, Eindhoven, NL # All rights reserved. # # Permission to use, copy, modify, and distribute this software for @@ -32,6 +32,8 @@ # Changelog: # 0.9-1: 31/Dec/2008 by Eric Hameleers # * Initial build. +# 0.9-2: 04/jun/2010 by Eric Hameleers +# * Rebuilt for Slackware 13.1. # # Run 'sh freenx-client.SlackBuild' to build a Slackware package. # The package (.tgz) and .txt file as well as build logs are created in /tmp . @@ -43,8 +45,7 @@ PRGNAM=freenx-client VERSION=${VERSION:-0.9} -ARCH=${ARCH:-i486} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-alien} NUMJOBS=${NUMJOBS:" -j4 "} @@ -65,31 +66,39 @@ SRCURL="http://download.berlios.de/freenx/${PRGNAM}-${VERSION}.tar.bz2" ## --- with a little luck, you won't have to edit below this point --- ## ## -# Exit the script on errors: -set -e -trap 'echo "$0 FAILED at line ${LINENO}" | tee $OUTPUT/error-${PRGNAM}.log' ERR -# Catch unitialized variables: -set -u -P1=${1:-1} +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac +fi case "$ARCH" in i486) SLKCFLAGS="-O2 -march=i486 -mtune=i686" SLKLDFLAGS=""; LIBDIRSUFFIX="" ;; - s390) SLKCFLAGS="-O2" - SLKLDFLAGS=""; LIBDIRSUFFIX="" - ;; - powerpc) SLKCFLAGS="-O2" - SLKLDFLAGS=""; LIBDIRSUFFIX="" - ;; x86_64) SLKCFLAGS="-O2 -fPIC" SLKLDFLAGS="-L/usr/lib64"; LIBDIRSUFFIX="64" ;; - athlon-xp) SLKCFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer" + *) SLKCFLAGS="-O2" SLKLDFLAGS=""; LIBDIRSUFFIX="" ;; esac +# Exit the script on errors: +set -e +trap 'echo "$0 FAILED at line ${LINENO}" | tee $OUTPUT/error-${PRGNAM}.log' ERR +# Catch unitialized variables: +set -u +P1=${1:-1} + +# Save old umask and set to 0022: +_UMASK_=$(umask) +umask 0022 + # Create working directories: mkdir -p $OUTPUT # place for the package to be saved mkdir -p $TMP/tmp-$PRGNAM # location to build the source @@ -138,7 +147,7 @@ cat $SRCDIR/freenx-client-0.9-fixes.diff | patch -p1 --verbose \ cat $SRCDIR/freenx-client-0.9_idpath.diff | patch -p1 --verbose \ 2>&1 | tee -a $OUTPUT/patch-$PRGNAM.log chown -R root:root . -chmod -R u+w,go+r-w,a-s . +chmod -R u+w,go+r-w,a+X-s . echo Building ... cat <> qtnx/qtnx.pro @@ -231,3 +240,6 @@ cd - cat $PKG/install/slack-desc | grep "^${PRGNAM}" > $OUTPUT/${PRGNAM}-${VERSION}-${ARCH}-${BUILD}${TAG}.txt cat $PKG/install/slack-required > $OUTPUT/${PRGNAM}-${VERSION}-${ARCH}-${BUILD}${TAG}.dep +# Restore the original umask: +umask ${_UMASK_} + -- cgit v1.2.3-79-gdb01