]> git.rm.cloudns.org Git - xonotic/xonotic.git/commitdiff
Make compile-emscripten only compile sdl target and set exename
authorLock l00p <hakzstudios@gmail.com>
Fri, 29 Sep 2023 16:15:21 +0000 (16:15 +0000)
committerLock l00p <hakzstudios@gmail.com>
Fri, 29 Sep 2023 16:15:21 +0000 (16:15 +0000)
misc/tools/all/xonotic.subr

index 898789430887189a0d93d64888640219db4af234..0040f26668786625832ffde9fec504b7ca2c1777 100755 (executable)
@@ -118,7 +118,8 @@ case "$cmd" in
                                                TARGETS="$TARGETS sdl-$debug"
                                                ;;
                                        dedicated)
-                                               TARGETS="$TARGETS sv-$debug"
+                                               msg "Can't create dedicated server for emscripten. using SDL target"
+                                               TARGETS="$TARGETS sdl-$debug"
                                                ;;
                                        *)
                                                BAD_TARGETS="$BAD_TARGETS $X"
@@ -128,7 +129,7 @@ case "$cmd" in
                        if [ -n "$TARGETS" ]; then # at least a valid client
                                shift
                        else # no valid client, let's assume this option is not meant to be a client then
-                               TARGETS=$TARGETS_SAVE
+                               TARGETS="sdl-$debug"
                                BAD_TARGETS=
                        fi
                fi
@@ -309,7 +310,7 @@ case "$cmd" in
                        verbose emmake make $MAKEFLAGS clean
                fi
                for T in $TARGETS; do
-                       verbose emmake make $MAKEFLAGS EXE_UNIXSDL="darkplaces-emscripten.html" DP_SSE=0 CFLAGS_EXTRA="-I../../../../misc/builddeps/emscripten/d0_blind_id/include -L../../../../misc/builddeps/emscripten/d0_blind_id/lib -Wl,-rpath,../../../../misc/builddeps/emscripten/d0_blind_id/lib -I../../../../misc/builddeps/emscripten/gmp/include -L../../../../misc/builddeps/emscripten/gmp/lib -Wl,-rpath,../../../../misc/builddeps/emscripten/gmp/lib -sUSE_SDL=2 -sUSE_ZLIB=1 -sUSE_LIBJPEG=1 -sALLOW_MEMORY_GROWTH -sINITIAL_MEMORY=100MB" ftype=.o LDFLAGS_EXTRA="-sINITIAL_MEMORY=100MB -sSINGLE_FILE -sFULL_ES2" STRIP=: "$@" "$T"
+                       verbose emmake make $MAKEFLAGS EXE_UNIXSDL="darkplaces-emscripten.html" DP_SSE=0 CFLAGS_EXTRA="-I../../../../misc/builddeps/emscripten/d0_blind_id/include -L../../../../misc/builddeps/emscripten/d0_blind_id/lib -Wl,-rpath,../../../../misc/builddeps/emscripten/d0_blind_id/lib -I../../../../misc/builddeps/emscripten/gmp/include -L../../../../misc/builddeps/emscripten/gmp/lib -Wl,-rpath,../../../../misc/builddeps/emscripten/gmp/lib -sUSE_SDL=2 -sUSE_ZLIB=1 -sUSE_LIBJPEG=1 -sALLOW_MEMORY_GROWTH -sINITIAL_MEMORY=100MB" LDFLAGS_EXTRA="-sINITIAL_MEMORY=100MB -sSINGLE_FILE -sFULL_ES2" STRIP=: "$@" "$T"
                done
                for T in $BAD_TARGETS; do
                        $ECHO "Warning: discarded invalid client $T."
@@ -736,6 +737,7 @@ case "$cmd" in
                ;;
        help)
                $ECHO "  $SELF compile [-c] [-qc] [-d|-p|-r] [-0] [-1] [sdl|dedicated]"
+               $ECHO "  $SELF compile-emscripten sdl [-c] [-qc] [-d|-p|-r] [-0] [-1]"
                $ECHO "  $SELF update-maps"
                $ECHO "  $SELF run [sdl|dedicated] options..."
                $ECHO "  $SELF compile-map mapname1 mapname2... (e.g. \"./all compile-map dance drain fuse\")"