os2: Added a script for the buildbot.
authorRyan C. Gordon <icculus@icculus.org>
Sun, 04 Nov 2018 20:47:17 -0500
changeset 12395c1443b4dea7f
parent 12394 80f861112154
child 12396 50b071ef40ab
os2: Added a script for the buildbot.
build-scripts/os2-buildbot.sh
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/build-scripts/os2-buildbot.sh	Sun Nov 04 20:47:17 2018 -0500
     1.3 @@ -0,0 +1,42 @@
     1.4 +#!/bin/bash
     1.5 +
     1.6 +# This is the script buildbot.libsdl.org uses to cross-compile SDL2 from
     1.7 +#  x86 Linux to OS/2, using OpenWatcom.
     1.8 +
     1.9 +# The final zipfile can be unpacked on any machine that supports OpenWatcom
    1.10 +#  (Windows, Linux, OS/2, etc). Point the compiler at the include directory
    1.11 +#  and link against the SDL2.lib file. Ship the SDL2.dll with your app.
    1.12 +
    1.13 +if [ -z "$WATCOM" ]; then
    1.14 +    echo "This script expects \$WATCOM to be set to the OpenWatcom install dir." 1>&2
    1.15 +    echo "This is often something like '/usr/local/share/watcom'" 1>&2
    1.16 +    exit 1
    1.17 +fi
    1.18 +
    1.19 +export PATH="$WATCOM/binl:$PATH"
    1.20 +
    1.21 +ZIPFILE="$1"
    1.22 +if [ -z $1 ]; then
    1.23 +    ZIPFILE=sdl-os2.zip
    1.24 +fi
    1.25 +ZIPDIR=SDL2-os2
    1.26 +
    1.27 +set -e
    1.28 +set -x
    1.29 +
    1.30 +cd `dirname "$0"`
    1.31 +cd ..
    1.32 +
    1.33 +rm -f $ZIPFILE
    1.34 +wmake -f Makefile.os2
    1.35 +rm -rf $ZIPDIR
    1.36 +mkdir $ZIPDIR
    1.37 +chmod a+r SDL2.lib SDL2.dll
    1.38 +mv SDL2.lib SDL2.dll $ZIPDIR/
    1.39 +cp -R include $ZIPDIR/
    1.40 +zip -9r "$ZIPFILE" $ZIPDIR
    1.41 +
    1.42 +rm -f *.obj SDL2.exp SDL2.map SDL2.lnk
    1.43 +
    1.44 +set +x
    1.45 +echo "All done. Final installable is in $ZIPFILE ...";