diff options
Diffstat (limited to 'distribute.sh')
-rwxr-xr-x | distribute.sh | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/distribute.sh b/distribute.sh index 71bee81..5cf21e0 100755 --- a/distribute.sh +++ b/distribute.sh @@ -12,11 +12,17 @@ else fi set -u -mkdir -p "$CONFIG_INSTALL_PREFIX/libs" case "$(uname -s)" in - + MINGW*) + for i in $(ldd "$CONFIG_BUILD_DIR"/bin/Pong* | awk '/mingw*/ {print $3}'); + do + cp "$i" "$CONFIG_INSTALL_PREFIX/libs/" + done + WINDOWS="true" + ;; *) + mkdir -p "$CONFIG_INSTALL_PREFIX/libs" # This is a catch all, above are specific loops for specific platforms. for i in $(ldd "$CONFIG_BUILD_DIR"/bin/Pong* | awk '/usr/ {print $3}'); do @@ -24,8 +30,15 @@ case "$(uname -s)" in done ;; esac + cd "$CONFIG_INSTALL_PREFIX" -rm libs/libGL* # Remove OpenGL as it conflicts with graphics drivers. # Tarball the finish result! -bsdtar -caf ../Pong_"$(uname)-$(uname -r)-$(uname -m)".txz -- * +if [ "$WINDOWS" = "true" ]; +then + zip Pong_"$(uname)-$(uname -r)-$(uname -m)".zip -- * + exit 0 +else + rm libs/libGL* # Remove OpenGL as it conflicts with graphics drivers. + bsdtar -caf ../Pong_"$(uname -s)-$(uname -r)-$(uname -m)".txz -- * +fi |