Permalink
Browse files

Desura compatibility

- create launch scripts for Desura
- that access local installation launch scripts
- clean up /usr/* launch scripts created during make install
  • Loading branch information...
1 parent aa6f12f commit 28d740dfc3efb3be2e3e08be7b17f2e69b460682 @Mailaender Mailaender committed Mar 21, 2013
Showing with 58 additions and 0 deletions.
  1. +3 −0 Makefile
  2. +24 −0 desura_launch_Editor.sh
  3. +24 −0 desura_launch_Play.sh
  4. +2 −0 launch-editor.sh
  5. +2 −0 launch-game.sh
  6. +3 −0 packaging/linux/buildpackage.sh
View
@@ -270,6 +270,9 @@ install: all
@$(INSTALL_PROGRAM) -m +rx openra $(BIN_INSTALL_DIR)
@$(INSTALL_PROGRAM) -m +rx openra-editor $(BIN_INSTALL_DIR)
+ @-rm openra
+ @-rm openra-editor
+
uninstall:
@-rm -r $(INSTALL_DIR)
@-rm $(DESTDIR)$(bindir)/openra
View
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+cd "`dirname "$(readlink -f "$0")"`"
+
+if [ -e "desura_prelaunch.sh" ]; then
+ source desura_prelaunch.sh
+fi
+
+BIN_PATH="$HOME/.desura/games/openra/launch-editor.sh"
+ARGS=
+# TODO: This is crap.
+libSDL_Path="$HOME/.desura/tools/63/"
+libopenal_Path="$HOME/.desura/tools/73/"
+libCgGL_PATH="$HOME/.desura/tools/78/"
+libCg_PATH="$HOME/.desura/tools/79/"
+libfreetype_Path="$HOME/.desura/tools/92/"
+libGLU_Path="$HOME/.desura/tools/93/"
+libalut_Path="$HOME/.desura/tools/195/"
+
+if [ -n $ARGS ]; then
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$libSDL_Path:$libopenal_Path:$libCgGL_PATH:$libCg_PATH:$libfreetype_Path:$libGLU_Path:$libalut_Path $BIN_PATH $ARGS $@
+else
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$libSDL_Path:$libopenal_Path:$libCgGL_PATH:$libCg_PATH:$libfreetype_Path:$libGLU_Path:$libalut_Path $BIN_PATH $@
+fi
View
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+cd "`dirname "$(readlink -f "$0")"`"
+
+if [ -e "desura_prelaunch.sh" ]; then
+ source desura_prelaunch.sh
+fi
+
+BIN_PATH="$HOME/.desura/games/openra/launch-game.sh"
+ARGS=
+# TODO: This is crap.
+libSDL_Path="$HOME/.desura/tools/63/"
+libopenal_Path="$HOME/.desura/tools/73/"
+libCgGL_PATH="$HOME/.desura/tools/78/"
+libCg_PATH="$HOME/.desura/tools/79/"
+libfreetype_Path="$HOME/.desura/tools/92/"
+libGLU_Path="$HOME/.desura/tools/93/"
+libalut_Path="$HOME/.desura/tools/195/"
+
+if [ -n $ARGS ]; then
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$libSDL_Path:$libopenal_Path:$libCgGL_PATH:$libCg_PATH:$libfreetype_Path:$libGLU_Path:$libalut_Path $BIN_PATH $ARGS $@
+else
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$libSDL_Path:$libopenal_Path:$libCgGL_PATH:$libCg_PATH:$libfreetype_Path:$libGLU_Path:$libalut_Path $BIN_PATH $@
+fi
View
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec mono OpenRA.Editor.exe "$@"
View
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec mono OpenRA.Game.exe "$@"
@@ -21,6 +21,9 @@ cp -T openra-bin $ROOTDIR/usr/bin/openra
mkdir -p $ROOTDIR/usr/share/openra/
cp -R $BUILTDIR/* "$ROOTDIR/usr/share/openra/" || exit 3
+# Desura launch scripts
+cp ../../*.sh "$ROOTDIR/usr/share/openra/" || exit 3
+
# Desktop Icons
mkdir -p $ROOTDIR/usr/share/applications/
cp openra.desktop "$ROOTDIR/usr/share/applications/"

0 comments on commit 28d740d

Please sign in to comment.