CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
graywood: Fixed maps and added run script to launch. Incomplete game..
[attic/ports/games-cross.git] / graywood / Pkgfile
index 5af4180893740d5448c425db9fbb1c7556065ff1..38941af50df7156690a347234eae44a53cd57397 100644 (file)
@@ -6,13 +6,26 @@
 
 name=graywood
 version=v0.0.2
-release=1
+release=2
 source=(http://dl.sourceforge.net/project/$name/$name/$name-$version/$name-$version.tar)
 
 build() {
   cd $SRC
   tar xvf $name-$version.tar
   cd $version/source/graywood
+  mv ../clearscreenfiles/nix/clearscreen_fcn.h .
+  sed -e 's|pause|read|g' -i *
   $CXX main.cpp -o graywood 
-  install -D -m 0755 graywood $PKG/usr/bin/graywood
+  mkdir -p $PKG/usr/{share/graywood,bin}
+  install -D -m 0755 graywood $PKG/usr/share/graywood/graywood
+  mv *.txt $PKG/usr/share/graywood/
+  cat > $PKG/usr/bin/graywood <<EOF
+#!/bin/bash
+
+cd /usr/share/graywood/
+./graywood \$@
+
+# End of file
+EOF
+  chmod +x $PKG/usr/bin/graywood
 }