From 291235e992df09c0980305a93d14c102b8b86066 Mon Sep 17 00:00:00 2001 From: Cameron Reikes Date: Thu, 22 Dec 2022 14:00:46 -0800 Subject: [PATCH] Initial build elf objects for whitebox --- .gitignore | 2 ++ build_elf_objects.bat | 29 +++++++++++++++++++++++++++++ flight.rdbg | Bin 1847 -> 1847 bytes gamestate.c | 2 +- 4 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 build_elf_objects.bat diff --git a/.gitignore b/.gitignore index 5d1da0b..b6acba7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +# elf objects +elf_objects/ # profiling results *.spall # logs diff --git a/build_elf_objects.bat b/build_elf_objects.bat new file mode 100644 index 0000000..f216728 --- /dev/null +++ b/build_elf_objects.bat @@ -0,0 +1,29 @@ +@echo off + +@REM what all the compile flags mean: https://learn.microsoft.com/en-us/cpp/build/reference/compiler-options-listed-by-category?view=msvc-170 + + +set OPUSLIB=%~dp0thirdparty\opus\win32\VS2015\x64\Release\opus.lib + +if not exist %OPUSLIB% ( + ECHO ERROR Couldn't find %OPUSLIB% compile opus by opening the visual studio project in win32\VS2015 and building the release setting +) + +setlocal enabledelayedexpansion enableextensions +pushd thirdparty\Chipmunk2D\src + set MUNKSRC= + for %%x in (*.c) do set MUNKSRC=!MUNKSRC! thirdparty\Chipmunk2D\src\%%x +popd + +@REM /DENET_DEBUG=1^ +gcc -c^ + -I"thirdparty" -I"thirdparty\minilzo" -I"thirdparty\enet\include" -I"thirdparty\Chipmunk2D\include\chipmunk" -I"thirdparty\Chipmunk2D\include" -I"thirdparty\opus\include" -I"thirdparty\opus\src"^ + %MUNKSRC% + +mkdir elf_objects +move *.o elf_objects + + @REM main.c gamestate.c server.c debugdraw.c^ + @REM thirdparty\minilzo\minilzo.c^ + @REM %OPUSLIB% + @REM thirdparty\enet\callbacks.c thirdparty\enet\compress.c thirdparty\enet\host.c thirdparty\enet\list.c thirdparty\enet\packet.c thirdparty\enet\peer.c thirdparty\enet\protocol.c thirdparty\enet\win32.c Ws2_32.lib winmm.lib^ diff --git a/flight.rdbg b/flight.rdbg index 8a56a64e08ec1e9f7aaa53ade52d05ba34d7030e..de8dda0b7d09771ce1d6c3f7a63bd6861332a059 100644 GIT binary patch delta 152 zcmdnax1DdoQl8@c?EIYg#DW6749m%hOa_y8GV@HfVfJCvow!kzCp|GYwYVg)Bvmgt z5-4ju`4yAmnDvr9LGd6|i&DVh13|1(=K0|4(gF?Ij| delta 144 zcmdnax1DdoQl8w*yv)SXl+1j+49$rf)h6#}W@FTvxKVZT1ZECK4IqOhH!(AB@_QzK zM%RfO4JJ=u5@Ih%OitBHhH@ns-5}zEoK8+5MX5j;FQ~%FTuj`Ikq{2|