summaryrefslogtreecommitdiff
path: root/games/fgrun/fgrun.SlackBuild
diff options
context:
space:
mode:
authorMatteo Bernardini <ponce@slackbuilds.org>2013-11-18 18:29:01 +0100
committerRobby Workman <rworkman@slackbuilds.org>2013-11-19 01:10:58 -0600
commit83940e056e4dc987a0f61cf79bbc3316e0e5e3d7 (patch)
treed1327d6e5427cda4db246505c4b5afae0f1af8e7 /games/fgrun/fgrun.SlackBuild
parentbcdc93d0d4cb91d7418c5c6c9654c733fc616c6f (diff)
downloadslackbuilds-83940e056e4dc987a0f61cf79bbc3316e0e5e3d7.tar.gz
games/fgrun: Updated for version 20131117_973f772.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'games/fgrun/fgrun.SlackBuild')
-rw-r--r--games/fgrun/fgrun.SlackBuild44
1 files changed, 27 insertions, 17 deletions
diff --git a/games/fgrun/fgrun.SlackBuild b/games/fgrun/fgrun.SlackBuild
index e0b2e1523d..d9774ece8a 100644
--- a/games/fgrun/fgrun.SlackBuild
+++ b/games/fgrun/fgrun.SlackBuild
@@ -3,8 +3,8 @@
# Written by Diego Pantano <poplin.dp@gmail.com>
PRGNAM=fgrun
-VERSION=${VERSION:-1.6.2}
-BUILD=${BUILD:-2}
+VERSION=${VERSION:-20131117_973f772}
+BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -40,18 +40,30 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
+tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
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 {} \;
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
# Fix a few bugs.
-patch -p1 < $CWD/fgrun-1.6.1-fix-crash-when-setting-defaults.patch
-patch -p1 < $CWD/fgrun-1.6.2-fix-reloadpath-logic.patch
+patch -p1 < $CWD/patches/fgrun-1.6.1-fix-crash-when-setting-defaults.patch
+patch -p1 < $CWD/patches/fgrun-1.6.2-fix-reloadpath-logic.patch
+patch -p1 < $CWD/patches/fgrun-1.7.0-update-required-SimGear-version.patch
+
+sed \
+ -e "s|fltk-config|fltk13-config|" \
+ -e "s|fluid|fluid13|" \
+ -e "s|\${CMAKE_CURRENT_LIST_DIR}|/usr/share/cmake-2.8/Modules|" \
+ /usr/share/cmake-2.8/Modules/FindFLTK.cmake \
+ > CMakeModules/FindFLTK13.cmake
+sed -i \
+ -e "s|FLTK\ REQUIRED|FLTK13\ REQUIRED|" \
+ -e "s|FLTK_FOUND|FLTK13_FOUND|" \
+ CMakeLists.txt
mkdir -p build
cd build
@@ -59,19 +71,17 @@ cd build
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
+ -DSIMGEAR_SHARED=ON \
-DCMAKE_BUILD_TYPE=Release ..
make
make install DESTDIR=$PKG
cd ..
-mkdir -p $PKG/etc/fltk/flightgear.org
-install -m 0644 $CWD/fgrun.prefs $PKG/etc/fltk/flightgear.org/fgrun.prefs.new
-
-mkdir -p $PKG/usr/share/{applications,pixmaps}
-install -m 0644 $CWD/fgrun.desktop $PKG/usr/share/applications/
-install -m 0644 $CWD/fgrun.png $PKG/usr/share/pixmaps/
+install -m 0644 -D $CWD/fgrun.prefs $PKG/etc/fltk/flightgear.org/fgrun.prefs.new
+install -m 0644 -D $CWD/fgrun.desktop $PKG/usr/share/applications/fgrun.desktop
+install -m 0644 -D $CWD/fgrun.png $PKG/usr/share/pixmaps/fgrun.png
-find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+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