diff --git a/tools/linux-installer/README b/tools/linux-installer/README new file mode 100644 index 00000000..b814ebf8 --- /dev/null +++ b/tools/linux-installer/README @@ -0,0 +1,10 @@ +In order to use Magic Set Editor, you need to have libraries for wxGTK version 2.8. This can be acquired from the Ubuntu package libwxgtk2.8-0. + +To install Magic Set Editor, please extract this tarball if you haven't already, and then run the install script as root. +Unfortunately, Magic Set Editor currently requires that it be installed to /usr/local/share/magicseteditor. +If, after Magic Set Editor is installed, it complains about being unable to find data in a certain path, then your system +is slightly different, and should be installed to that directory, minus the "/data". This can be done by modifying the install script. +After the install script is run and loading is confirmed, you may delete all the contents of this tarball if you wish. + +Magic Set Editor stores data only in the primary installation directory and in ~/.magicseteditor. +If you need to uninstall, removing these directories should completely purge your system. \ No newline at end of file diff --git a/tools/linux-installer/install b/tools/linux-installer/install new file mode 100755 index 00000000..c88d1515 --- /dev/null +++ b/tools/linux-installer/install @@ -0,0 +1,44 @@ +#!/bin/bash + +# Magic Set Editor 2 beta. +# This script and this program are licensed under the GNU General Public License Version 2 +# The full text of this license is in the file COPYING + +# This script installs Magic Set Editor onto your system. +# If executed as root (including via sudo), it is installed to /usr/local/share/magicseteditor. (with an executable symlink in /usr/local/bin) +# If executed as any other user, it will fail. + +$VERSION=0.3.3 + +case `id -un` in + root) + INSTALL_DIR='/usr/local/share/magicseteditor/'; + EXEC_SYMLINK='/usr/local/bin/magicseteditor';; + *) + echo "Unfortunately, our installer system currently does not support installation except as root. +This is because the program currently requires a specific data directory. +Our apologies." && exit;; +esac + +echo "Magic Set Editor version $VERSION Installer Script. + +Magic Set Editor will be installed to $INSTALL_DIR. +A symbolic link to the executable will be put at $EXEC_SYMLINK. + +Is this correct [y/N]? "; + +read -n 1 CONFIRM; + +case $CONFIRM in + [yY]) + :;; + *) + exit;; +esac; + +echo "Installing..."; + +mkdir "$INSTALL_DIR"; +cp -r program/* "$INSTALL_DIR"; + +ln -s "$INSTALL_DIR/magicseteditor" "$EXEC_SYMLINK" diff --git a/tools/linux-installer/tarball b/tools/linux-installer/tarball new file mode 100755 index 00000000..e9ff8fd7 --- /dev/null +++ b/tools/linux-installer/tarball @@ -0,0 +1,10 @@ +#!/bin/bash +# Magic Set Editor installer tarball generator. + +mkdir program + +cp -rP ../../data ../../src/resource ../../magicseteditor program; + +tar -cf magicseteditor.tar.gz --owner root --exclude=.* --exclude=*~ --exclude=.svn program install README; + +rm -rf program; \ No newline at end of file