From 4e9e18df827fbc80fd25e34f87fd9f2f45cd8674 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 19:54:07 -0400 Subject: [PATCH 01/18] Clear unused-but-set-variable warnings --- src/blua/liolib.c | 2 -- src/d_netfil.c | 3 --- src/hardware/hw_model.c | 3 +++ 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/blua/liolib.c b/src/blua/liolib.c index d1d6f469..2d69f45c 100644 --- a/src/blua/liolib.c +++ b/src/blua/liolib.c @@ -445,7 +445,6 @@ static int io_readline (lua_State *L) { static int g_write (lua_State *L, FILE *f, int arg) { int nargs = lua_gettop(L) - 1; int status = 1; - size_t count; for (; nargs--; arg++) { if (lua_type(L, arg) == LUA_TNUMBER) { /* optimization: could be done exactly as for strings */ @@ -455,7 +454,6 @@ static int g_write (lua_State *L, FILE *f, int arg) { else { size_t l; const char *s = luaL_checklstring(L, arg, &l); - count += l; if (ftell(f) + l > FILELIMIT) { luaL_error(L,"write limit bypassed in file. Changes have been discarded."); diff --git a/src/d_netfil.c b/src/d_netfil.c index 881b7b5b..292fd026 100644 --- a/src/d_netfil.c +++ b/src/d_netfil.c @@ -489,7 +489,6 @@ INT32 CL_CheckFiles(void) { INT32 i, j; char wadfilename[MAX_WADPATH]; - size_t packetsize = 0; size_t filestoload = 0; boolean downloadrequired = false; @@ -561,8 +560,6 @@ INT32 CL_CheckFiles(void) } } - packetsize += nameonlylength(fileneeded[i].filename) + 22; - fileneeded[i].status = findfile(fileneeded[i].filename, fileneeded[i].md5sum, true); CONS_Debug(DBG_NETPLAY, "found %d\n", fileneeded[i].status); return 4; diff --git a/src/hardware/hw_model.c b/src/hardware/hw_model.c index 2c36f974..e77cf43e 100644 --- a/src/hardware/hw_model.c +++ b/src/hardware/hw_model.c @@ -519,6 +519,9 @@ void GeneratePolygonNormals(model_t *model, int ztag) for (k = 0; k < mesh->numTriangles; k++) { + /// TODO: normalize vectors + (void)vertices; + (void)polyNormals; // Vector::Normal(vertices, polyNormals); vertices += 3 * 3; polyNormals++; From 1b82918384ad60025a79a4c2e84b5dbbb980c29a Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 19:56:27 -0400 Subject: [PATCH 02/18] Clear misleading-indentation warnings --- src/m_menu.c | 2 ++ src/p_user.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/m_menu.c b/src/m_menu.c index 9d44ff03..2fd5e929 100644 --- a/src/m_menu.c +++ b/src/m_menu.c @@ -8312,7 +8312,9 @@ static void M_EraseGuest(INT32 choice) /*if (currentMenu == &SP_NightsGuestReplayDef) M_SetupNextMenu(&SP_NightsAttackDef); else*/ + { M_SetupNextMenu(&SP_TimeAttackDef); + } CV_AddValue(&cv_nextmap, -1); CV_AddValue(&cv_nextmap, 1); M_StartMessage(M_GetText("Guest replay data erased.\n"),NULL,MM_NOTHING); diff --git a/src/p_user.c b/src/p_user.c index 94169754..c2165abf 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -2305,7 +2305,9 @@ static void P_CheckInvincibilityTimer(player_t *player) return; //if (mariomode && !player->powers[pw_super]) // SRB2kart + { player->mo->color = (UINT8)(1 + (leveltime % (MAXSKINCOLORS-1))); + } /*if (leveltime % (TICRATE/7) == 0) { mobj_t *sparkle = P_SpawnMobj(player->mo->x, player->mo->y, player->mo->z, MT_IVSP); From 79e2596ce6fcb68a0ff1fc64471744b13c35610d Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 19:57:56 -0400 Subject: [PATCH 03/18] Clear missing-noreturn warnings --- src/sdl/i_system.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sdl/i_system.c b/src/sdl/i_system.c index 50204f3f..9131dc9c 100644 --- a/src/sdl/i_system.c +++ b/src/sdl/i_system.c @@ -3031,7 +3031,7 @@ void I_Sleep(UINT32 ms) } #ifdef NEWSIGNALHANDLER -static void newsignalhandler_Warn(const char *pr) +FUNCNORETURN static ATTRNORETURN void newsignalhandler_Warn(const char *pr) { char text[128]; From a5b99199fcd776856424261bbb5acb9b91ea0bb2 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 20:05:48 -0400 Subject: [PATCH 04/18] Clear implicit-const-int-float-conversion warnings --- src/m_random.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/m_random.c b/src/m_random.c index 3d46f76b..197f3723 100644 --- a/src/m_random.c +++ b/src/m_random.c @@ -60,7 +60,7 @@ UINT8 M_RandomByte(void) */ INT32 M_RandomKey(INT32 a) { - return (INT32)((rand()/((unsigned)RAND_MAX+1.0f))*a); + return (INT32)((rand()/((float)(RAND_MAX)+1.0f))*a); } /** Provides a random integer in a given range. @@ -73,7 +73,7 @@ INT32 M_RandomKey(INT32 a) */ INT32 M_RandomRange(INT32 a, INT32 b) { - return (INT32)((rand()/((unsigned)RAND_MAX+1.0f))*(b-a+1))+a; + return (INT32)((rand()/((float)(RAND_MAX)+1.0f))*(b-a+1))+a; } From 7fea4894a2fcb9d9d3d29ac693ad7829b8143a23 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 20:55:26 -0400 Subject: [PATCH 05/18] Add support for GCC 13.2 --- src/Makefile.cfg | 131 ++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 123 insertions(+), 8 deletions(-) diff --git a/src/Makefile.cfg b/src/Makefile.cfg index e45265ca..c5794b8d 100644 --- a/src/Makefile.cfg +++ b/src/Makefile.cfg @@ -12,15 +12,18 @@ # to avoid a false positive with the version detection... SUPPORTED_GCC_VERSIONS:=\ - 101 102\ - 91 92 93\ - 81 82 83 84\ - 71 72 73 74 75\ - 61 62 63 64\ - 51 52 53 54 55\ - 40 41 42 43 44 45 46 47 48 49 + 132 131 130\ + 123 122 121 120\ + 114 113 112 111 110\ + 105 104 103 102 101 100 10\ + 95 94 93 92 91 90\ + 85 84 83 82 81 80\ + 75 74 73 72 71 70\ + 64 63 62 61 60\ + 55 54 53 52 51 50\ + 49 48 47 46 45 44 43 42 41 40 -LATEST_GCC_VERSION=10.2 +LATEST_GCC_VERSION=13.2 # gcc or g++ ifdef PREFIX @@ -71,11 +74,99 @@ ifeq (,$(filter GCC%,$(.VARIABLES))) endif endif +ifdef GCC132 +GCC131=1 +endif + +ifdef GCC131 +GCC130=1 +endif + +ifdef GCC13 +GCC130=1 +endif + +ifdef GCC130 +GCC123=1 +endif + +ifdef GCC123 +GCC122=1 +endif + +ifdef GCC122 +GCC121=1 +endif + +ifdef GCC121 +GCC120=1 +endif + +ifdef GCC12 +GCC120=1 +endif + +ifdef GCC120 +GCC114=1 +endif + +ifdef GCC114 +GCC113=1 +endif + +ifdef GCC113 +GCC112=1 +endif + +ifdef GCC112 +GCC111=1 +endif + +ifdef GCC111 +GCC110=1 +endif + +ifdef GCC11 +GCC110=1 +endif + +ifdef GCC110 +GCC105=1 +endif + +ifdef GCC105 +GCC104=1 +endif + +ifdef GCC104 +GCC103=1 +endif + +ifdef GCC103 +GCC102=1 +endif + ifdef GCC102 GCC101=1 endif ifdef GCC101 +GCC100=1 +endif + +ifdef GCC10 +GCC100=1 +endif + +ifdef GCC100 +GCC93=1 +endif + +ifdef GCC95 +GCC94=1 +endif + +ifdef GCC94 GCC93=1 endif @@ -88,6 +179,14 @@ GCC91=1 endif ifdef GCC91 +GCC90=1 +endif + +ifdef GCC90 +GCC85=1 +endif + +ifdef GCC85 GCC84=1 endif @@ -104,6 +203,10 @@ GCC81=1 endif ifdef GCC81 +GCC80=1 +endif + +ifdef GCC80 GCC75=1 endif @@ -124,6 +227,10 @@ GCC71=1 endif ifdef GCC71 +GCC70=1 +endif + +ifdef GCC70 GCC64=1 endif @@ -140,6 +247,10 @@ GCC61=1 endif ifdef GCC61 +GCC60=1 +endif + +ifdef GCC60 GCC55=1 endif @@ -160,6 +271,10 @@ GCC51=1 endif ifdef GCC51 +GCC50=1 +endif + +ifdef GCC50 GCC49=1 endif From 94e7430dd93b026d017be2829adba71891a92057 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 20:57:14 -0400 Subject: [PATCH 06/18] copy gitlib-ci config from SRB2's next --- .gitlab-ci.yml | 436 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 436 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 00000000..f13dac2f --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,436 @@ +default: + image: debian:stable-slim + +stages: # List of stages for jobs, and their order of execution + - build + +variables: + GIT_STRATEGY: clone + GIT_CLONE_PATH: $CI_BUILDS_DIR/$CI_CONCURRENT_ID/$CI_PROJECT_PATH + +.job_template: &job_build # This job runs in the build stage, which runs first. + + stage: build + + cache: + - key: ccache-$CI_PROJECT_PATH_SLUG-$CI_JOB_NAME_SLUG + fallback_keys: + - cache-$CI_PROJECT_PATH_SLUG-$CI_DEFAULT_BRANCH + - cache-$CI_PROJECT_PATH_SLUG-default + paths: + - ccache + - ccache_statslog + + - key: apt-$CI_JOB_IMAGE + paths: + - apt-cache + unprotect: true + + before_script: + - - | + # debconf + echo -e "\e[0Ksection_start:`date +%s`:debconf[collapsed=true]\r\e[0KSetup debconf's environment" + - export DEBIAN_FRONTEND="noninteractive" + - export DEBIAN_PRIORITY="low" + - export DEBCONF_NONINTERACTIVE_SEEN="true" + - | + # debconf + echo -e "\e[0Ksection_end:`date +%s`:debconf\r\e[0K" + - - | + # dpkg_aa + echo -e "\e[0Ksection_start:`date +%s`:dpkg_aa[collapsed=true]\r\e[0KAdding architectures to dpkg" + - dpkg --add-architecture i386 + - dpkg --add-architecture amd64 + - dpkg --add-architecture arm64 + - | + # dpkg_aa + echo -e "\e[0Ksection_end:`date +%s`:dpkg_aa\r\e[0K" + - - | + # apt_conf + echo -e "\e[0Ksection_start:`date +%s`:apt_conf[collapsed=true]\r\e[0KSetting up APT conf" + - export APT_CACHE_DIR=`pwd`/apt-cache + - mkdir --parents --verbose $APT_CACHE_DIR/partial/ + - touch /etc/apt/apt.conf.d/99build + - | + # apt.conf + echo Adding options to apt.conf':' + - | + # APT::Install-Recommends + echo APT::Install-Recommends "false"\; | tee --append /etc/apt/apt.conf.d/99build + - | + # quit + echo quiet "1"\; | tee --append /etc/apt/apt.conf.d/99build + - | + # APT::Get::Assume-Yes + echo APT::Get::Assume-Yes "true"\; | tee --append /etc/apt/apt.conf.d/99build + - | + # Dir::Cache::Archives + echo Dir::Cache::Archives "$APT_CACHE_DIR"\; | tee --append /etc/apt/apt.conf.d/99build + - | + # apt_conf + echo -e "\e[0Ksection_end:`date +%s`:apt_conf\r\e[0K" + - - | + # apt_update + echo -e "\e[0Ksection_start:`date +%s`:apt_update[collapsed=true]\r\e[0KUpdating APT listing" + - apt-get update + - | + # apt_update + echo -e "\e[0Ksection_end:`date +%s`:apt_update\r\e[0K" + + - - | + # apt_pre + echo -e "\e[0Ksection_start:`date +%s`:apt_pre[collapsed=true]\r\e[0KInstalling pre packages" + - apt-get install apt-utils + - | + # apt_pre + echo -e "\e[0Ksection_end:`date +%s`:apt_pre\r\e[0K" + + - - | + # apt_upgrade + echo -e "\e[0Ksection_start:`date +%s`:apt_upgrade[collapsed=true]\r\e[0KUpdating existing packages" + - apt-get upgrade + - | + # apt_update + echo -e "\e[0Ksection_end:`date +%s`:apt_upgrade\r\e[0K" + + - - | + # apt_common + echo -e "\e[0Ksection_start:`date +%s`:apt_common[collapsed=true]\r\e[0KInstalling common packages" + - apt-get install make git ccache + - | + # apt_common + echo -e "\e[0Ksection_end:`date +%s`:apt_common\r\e[0K" + + - - | + # ccache_config + echo -e "\e[0Ksection_start:`date +%s`:ccache_config[collapsed=true]\r\e[0KSetting up ccache config" + - mkdir --parents --verbose ~/.ccache/ + - touch ~/.ccache/ccache.conf + - | + # cache.conf + echo Adding ccache configution option + - | + # base_dir + echo base_dir = $PWD | tee --append ~/.ccache/ccache.conf + - | + # cache_dir + echo cache_dir = $PWD/ccache | tee --append ~/.ccache/ccache.conf + - | + # compiler_check + echo compiler_check = content | tee --append ~/.ccache/ccache.conf + - | + # stats_log + echo stats_log = $PWD/ccache_statslog | tee --append ~/.ccache/ccache.conf + - | + # max_size + echo max_size = 50M | tee --append ~/.ccache/ccache.conf + - | + # ccache_config + echo -e "\e[0Ksection_end:`date +%s`:ccache_config\r\e[0K" + + - - | + # cache_reset + echo -e "\e[0Ksection_start:`date +%s`:ccache_reset[collapsed=true]\r\e[0KResetting ccache statistics" + - ccache --zero-stats + - ccache --show-stats + - | + # ccache_reset + echo -e "\e[0Ksection_end:`date +%s`:ccache_reset\r\e[0K" + + after_script: + - - | + # apt_clean + echo -e "\e[0Ksection_start:`date +%s`:apt_clean[collapsed=true]\r\e[0KCleaning of unneeded APT packages" + - apt-get autoclean + - | + # apt_clean + echo -e "\e[0Ksection_end:`date +%s`:apt_clean\r\e[0K" + + - - | + # ccache_stats + echo -e "\e[0Ksection_start:`date +%s`:ccache_stats[collapsed=true]\r\e[0Kccache statistics:" + - ccache --show-stats --verbose + - ccache --show-log-stats --verbose + - | + # ccahe_stats + echo -e "\e[0Ksection_end:`date +%s`:ccache_stats\r\e[0K" + +Debian testing GCC: + <<: *job_build + image: debian:testing-slim + + allow_failure: true + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debian GCC testing" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-testing-gcc" + + variables: + CC: gcc + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install libsdl2-mixer-dev libpng-dev libcurl4-openssl-dev libgme-dev libopenmpt-dev + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Windows x86: + <<: *job_build + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-Win32" + + variables: + PREFIX: i686-w64-mingw32 + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc-mingw-w64-i686-win32 + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Debian stable:amd64: + <<: *job_build + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debian amd64" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-x86-64" + + variables: + CC: x86_64-linux-gnu-gcc + OBJCOPY: x86_64-linux-gnu-objcopy + OBJDUMP: x86_64-linux-gnu-objdump + PKG_CONFIG_PATH: /usr/lib/x86_64-linux-gnu/pkgconfig + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc-x86-64-linux-gnu || apt-get install gcc + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install libsdl2-mixer-dev:amd64 libpng-dev:amd64 libcurl4-openssl-dev:amd64 libgme-dev:amd64 libopenmpt-dev:amd64 + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Debian stable:i386: + <<: *job_build + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debian i386" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-i686" + + variables: + CC: i686-linux-gnu-gcc + OBJCOPY: i686-linux-gnu-objcopy + OBJDUMP: i686-linux-gnu-objdump + PKG_CONFIG_PATH: /usr/lib/i386-linux-gnu/pkgconfig + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc-i686-linux-gnu || apt-get install gcc + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install libsdl2-mixer-dev:i386 libpng-dev:i386 libcurl4-openssl-dev:i386 libgme-dev:i386 libopenmpt-dev:i386 + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Debian stable:arm64: + <<: *job_build + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debian arm64" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-aarch64" + + variables: + CC: aarch64-linux-gnu-gcc + OBJCOPY: aarch64-linux-gnu-objcopy + OBJDUMP: aarch64-linux-gnu-objdump + PKG_CONFIG_PATH: /usr/lib/aarch64-linux-gnu/pkgconfig + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc-aarch64-linux-gnu || apt-get install gcc + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install libsdl2-mixer-dev:arm64 libpng-dev:arm64 libcurl4-openssl-dev:arm64 libgme-dev:arm64 libopenmpt-dev:arm64 + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 ERRORMODE=1 NONX86=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 NONX86=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Windows x64: + <<: *job_build + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Win64" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-Win64" + + variables: + PREFIX: x86_64-w64-mingw32 + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc-mingw-w64-x86-64-win32 + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Debian stable Clang: + <<: *job_build + + allow_failure: true + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debian Clang" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-clang" + + variables: + CC: clang + CFLAGS: -Wno-cast-align + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install clang + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install libsdl2-mixer-dev libpng-dev libcurl4-openssl-dev libgme-dev libopenmpt-dev + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + +Debian testing Clang: + extends: Debian stable Clang + + image: debian:testing-slim + + artifacts: + paths: + - "bin/" + - "src/comptime.h" + expose_as: "Debina Clang testing" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-testing-clang" + + variables: + CC: clang + CFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype From 579c5ab05235c1b46d7d5b21f3cfd2ed121bbb86 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 21:09:51 -0400 Subject: [PATCH 07/18] Makefile: Support GCC version 11, 12 and 13 --- src/Makefile.cfg | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Makefile.cfg b/src/Makefile.cfg index c5794b8d..2532a6b2 100644 --- a/src/Makefile.cfg +++ b/src/Makefile.cfg @@ -12,9 +12,9 @@ # to avoid a false positive with the version detection... SUPPORTED_GCC_VERSIONS:=\ - 132 131 130\ - 123 122 121 120\ - 114 113 112 111 110\ + 132 131 130 13\ + 123 122 121 120 12\ + 114 113 112 111 110 11\ 105 104 103 102 101 100 10\ 95 94 93 92 91 90\ 85 84 83 82 81 80\ From 46f0385566cc50a1bbf7c6f698f66ceb6098a860 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 21:36:27 -0400 Subject: [PATCH 08/18] d_netfile.c: Update libcurl support to 7.88 --- src/d_netfil.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/src/d_netfil.c b/src/d_netfil.c index 292fd026..7d4e2406 100644 --- a/src/d_netfil.c +++ b/src/d_netfil.c @@ -72,8 +72,13 @@ static boolean SV_SendFile(INT32 node, const char *filename, UINT8 fileid); #ifdef HAVE_CURL size_t curlwrite_data(void *ptr, size_t size, size_t nmemb, FILE *stream); +#if defined(CURL_AT_LEAST_VERSION) && CURL_AT_LEAST_VERSION(7, 35, 0) +int curlprogress_callbackx(void *clientp, curl_off_t dltotal, curl_off_t dlnow, curl_off_t ultotal, curl_off_t ulnow); +#define XFERINFOFUNCTION +#else int curlprogress_callback(void *clientp, double dltotal, double dlnow, double ultotal, double ulnow); #endif +#endif // Sender structure typedef struct filetx_s @@ -1217,6 +1222,18 @@ size_t curlwrite_data(void *ptr, size_t size, size_t nmemb, FILE *stream) return written; } +#ifdef XFERINFOFUNCTION +int curlprogress_callbackx(void *clientp, curl_off_t dltotal, curl_off_t dlnow, curl_off_t ultotal, curl_off_t ulnow) +{ + (void)clientp; + (void)ultotal; + (void)ulnow; // Function prototype requires these but we won't use, so just discard + curl_dlnow = dlnow; + curl_dltotal = dltotal; + getbytes = curl_dlnow / (time(NULL) - curl_starttime); // To-do: Make this more accurate??? + return 0; +} +#else int curlprogress_callback(void *clientp, double dltotal, double dlnow, double ultotal, double ulnow) { (void)clientp; @@ -1227,6 +1244,7 @@ int curlprogress_callback(void *clientp, double dltotal, double dlnow, double ul getbytes = curl_dlnow / (time(NULL) - curl_starttime); // To-do: Make this more accurate??? return 0; } +#endif void CURLPrepareFile(const char* url, int dfilenum) { @@ -1256,7 +1274,11 @@ void CURLPrepareFile(const char* url, int dfilenum) curl_easy_setopt(http_handle, CURLOPT_URL, va("%s/%s", url, curl_realname)); // Only allow HTTP and HTTPS +#if defined(CURL_AT_LEAST_VERSION) && CURL_AT_LEAST_VERSION(7, 85, 0) + curl_easy_setopt(http_handle, CURLOPT_PROTOCOLS_STR, "http,https"); +#else curl_easy_setopt(http_handle, CURLOPT_PROTOCOLS, CURLPROTO_HTTP|CURLPROTO_HTTPS); +#endif curl_easy_setopt(http_handle, CURLOPT_USERAGENT, va("SRB2Kart/v%d.%d", VERSION, SUBVERSION)); // Set user agent as some servers won't accept invalid user agents. @@ -1280,7 +1302,11 @@ void CURLPrepareFile(const char* url, int dfilenum) curl_easy_setopt(http_handle, CURLOPT_WRITEDATA, curl_curfile->file); curl_easy_setopt(http_handle, CURLOPT_WRITEFUNCTION, curlwrite_data); curl_easy_setopt(http_handle, CURLOPT_NOPROGRESS, 0L); +#ifdef XFERINFOFUNCTION + curl_easy_setopt(http_handle, CURLOPT_XFERINFOFUNCTION, curlprogress_callbackx); +#else curl_easy_setopt(http_handle, CURLOPT_PROGRESSFUNCTION, curlprogress_callback); +#endif curl_curfile->status = FS_DOWNLOADING; lastfilenum = dfilenum; From 16c70e7b29d1dd1fab11f0b2c7206c95fab9bcd5 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 21:38:51 -0400 Subject: [PATCH 09/18] GitLab CI: Compile the SDL version of Win32 builds --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f13dac2f..9114cc17 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -220,7 +220,7 @@ Windows x86: - - | # make echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" - - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 SDL=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW=1 SDL=1 - | # make echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" @@ -373,7 +373,7 @@ Windows x64: - - | # make echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" - - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 SDL=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 MINGW64=1 SDL=1 - | # make echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" From 2365ee9cb0be4ee37e08b32fd8dfa3b14a0cf33e Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 21:42:07 -0400 Subject: [PATCH 10/18] GitLab CI: SRB2 2.1 wants nasm --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9114cc17..874c76aa 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -96,7 +96,7 @@ variables: - - | # apt_common echo -e "\e[0Ksection_start:`date +%s`:apt_common[collapsed=true]\r\e[0KInstalling common packages" - - apt-get install make git ccache + - apt-get install make git ccache nasm - | # apt_common echo -e "\e[0Ksection_end:`date +%s`:apt_common\r\e[0K" From bf6be522ea7b8fcd83d3c301bb68dc25024cf767 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 21:44:39 -0400 Subject: [PATCH 11/18] GitLib CI: SRB2 2.1 codebase use WFLAGS to control warning flags --- .gitlab-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 874c76aa..3185a669 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -392,7 +392,7 @@ Debian stable Clang: variables: CC: clang - CFLAGS: -Wno-cast-align + WFLAGS: -Wno-cast-align script: - - | @@ -433,4 +433,4 @@ Debian testing Clang: variables: CC: clang - CFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype + WFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype From 98f8b49e4531062b1cc96fdbd6f40930b7606929 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 22:36:17 -0400 Subject: [PATCH 12/18] Makefile: support toolchain envs --- src/Makefile.cfg | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Makefile.cfg b/src/Makefile.cfg index 2532a6b2..9d5b879c 100644 --- a/src/Makefile.cfg +++ b/src/Makefile.cfg @@ -27,17 +27,17 @@ LATEST_GCC_VERSION=13.2 # gcc or g++ ifdef PREFIX - CC=$(PREFIX)-gcc - CXX=$(PREFIX)-g++ - OBJCOPY=$(PREFIX)-objcopy - OBJDUMP=$(PREFIX)-objdump - STRIP=$(PREFIX)-strip - WINDRES=$(PREFIX)-windres + CC?=$(PREFIX)-gcc + CXX?=$(PREFIX)-g++ + OBJCOPY?=$(PREFIX)-objcopy + OBJDUMP?=$(PREFIX)-objdump + STRIP?=$(PREFIX)-strip + WINDRES?=$(PREFIX)-windres else - OBJCOPY=objcopy - OBJDUMP=objdump - STRIP=strip - WINDRES=windres + OBJCOPY?=objcopy + OBJDUMP?=objdump + STRIP?=strip + WINDRES?=windres endif # because Apple screws with us on this From cb4ffe6f60c10f11f5fc5a298ab829e9d44e0ac4 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 23:12:14 -0400 Subject: [PATCH 13/18] no Dr. Mingw support for Win x64 build --- src/sdl/i_main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/sdl/i_main.c b/src/sdl/i_main.c index e6644ec5..4ac45aa1 100644 --- a/src/sdl/i_main.c +++ b/src/sdl/i_main.c @@ -58,8 +58,11 @@ char logfilename[1024]; #endif #endif -#if defined (_WIN32) +#ifdef _WIN32 +#ifndef _AMD64_ #include "exchndl.h" +#define DRMINGW +#endif #endif #if defined (_WIN32) @@ -174,7 +177,9 @@ int main(int argc, char **argv) ) #endif { +#ifdef DRMINGW ExcHndlInit(); +#endif } } #ifndef __MINGW32__ From 37c65ca7e4f8b1b258e54d189fcfe456bfdfa27b Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 23:14:09 -0400 Subject: [PATCH 14/18] Makefile: PREFIX overwrite make's default CC and CXX --- src/Makefile.cfg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Makefile.cfg b/src/Makefile.cfg index 9d5b879c..5248dbdf 100644 --- a/src/Makefile.cfg +++ b/src/Makefile.cfg @@ -27,8 +27,8 @@ LATEST_GCC_VERSION=13.2 # gcc or g++ ifdef PREFIX - CC?=$(PREFIX)-gcc - CXX?=$(PREFIX)-g++ + CC:=$(PREFIX)-gcc + CXX:=$(PREFIX)-g++ OBJCOPY?=$(PREFIX)-objcopy OBJDUMP?=$(PREFIX)-objdump STRIP?=$(PREFIX)-strip From 01911e4d3703371da1a9f086a52e5b7ef4f9bd26 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 23:19:38 -0400 Subject: [PATCH 15/18] Clear unused-but-set-variable warnings --- src/p_saveg.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/p_saveg.c b/src/p_saveg.c index f553ddf6..c938c3dc 100644 --- a/src/p_saveg.c +++ b/src/p_saveg.c @@ -494,7 +494,6 @@ static void P_NetUnArchivePlayers(void) static void P_NetArchiveWorld(void) { size_t i; - INT32 statsec = 0, statline = 0; const line_t *li = lines; const side_t *si; UINT8 *put; @@ -587,8 +586,6 @@ static void P_NetArchiveWorld(void) if (diff) { - statsec++; - WRITEUINT16(put, i); WRITEUINT8(put, diff); if (diff & SD_DIFF2) @@ -705,7 +702,6 @@ static void P_NetArchiveWorld(void) if (diff) { - statline++; WRITEINT16(put, i); WRITEUINT8(put, diff); if (diff & LD_DIFF2) From 3c3c59928da42faa360d56ec0652343f24b0f0b8 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Tue, 17 Oct 2023 23:44:30 -0400 Subject: [PATCH 16/18] Makefile: support for Mingw64 toolchain --- src/Makefile.cfg | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Makefile.cfg b/src/Makefile.cfg index 5248dbdf..b839b5ea 100644 --- a/src/Makefile.cfg +++ b/src/Makefile.cfg @@ -54,7 +54,10 @@ ifeq (,$(filter GCC%,$(.VARIABLES))) version:=$(shell $(CC) --version) # check if this is in fact GCC ifneq (,$(or $(findstring gcc,$(version)),$(findstring GCC,$(version)))) - version:=$(shell $(CC) -dumpversion) + shellversion:=$(shell $(CC) -dumpversion) + + # Try to remove "-win32" + version:=$(subst -win32,.0,$(shellversion)) # Turn version into words of major, minor v:=$(subst ., ,$(version)) From 0a60b7486c88ac918ac54665f22cac68708f1127 Mon Sep 17 00:00:00 2001 From: Alam Ed Arias Date: Fri, 20 Oct 2023 09:10:21 -0400 Subject: [PATCH 17/18] GitLib CI: update from 2.2 codebase --- .gitlab-ci.yml | 54 ++++++++++++++++++++++++-------------------------- 1 file changed, 26 insertions(+), 28 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3185a669..b292bfc0 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,16 +1,9 @@ -default: - image: debian:stable-slim - -stages: # List of stages for jobs, and their order of execution - - build - variables: GIT_STRATEGY: clone GIT_CLONE_PATH: $CI_BUILDS_DIR/$CI_CONCURRENT_ID/$CI_PROJECT_PATH -.job_template: &job_build # This job runs in the build stage, which runs first. - - stage: build +default: + image: debian:stable-slim cache: - key: ccache-$CI_PROJECT_PATH_SLUG-$CI_JOB_NAME_SLUG @@ -137,6 +130,12 @@ variables: # ccache_reset echo -e "\e[0Ksection_end:`date +%s`:ccache_reset\r\e[0K" + artifacts: + paths: + - "bin/" + - "src/comptime.h" + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-$CI_JOB_NAME_SLUG" + after_script: - - | # apt_clean @@ -155,21 +154,21 @@ variables: # ccahe_stats echo -e "\e[0Ksection_end:`date +%s`:ccache_stats\r\e[0K" +stages: + - build + Debian testing GCC: - <<: *job_build + stage: build image: debian:testing-slim allow_failure: true artifacts: - paths: - - "bin/" - - "src/comptime.h" - expose_as: "Debian GCC testing" name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-testing-gcc" variables: CC: gcc + LDFLAGS: -Wl,-fuse-ld=gold script: - - | @@ -197,12 +196,13 @@ Debian testing GCC: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Windows x86: - <<: *job_build + stage: build artifacts: paths: - "bin/" - "src/comptime.h" + expose_as: "Win32" name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-Win32" variables: @@ -226,7 +226,7 @@ Windows x86: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Debian stable:amd64: - <<: *job_build + stage: build artifacts: paths: @@ -237,6 +237,7 @@ Debian stable:amd64: variables: CC: x86_64-linux-gnu-gcc + LDFLAGS: -Wl,-fuse-ld=gold OBJCOPY: x86_64-linux-gnu-objcopy OBJDUMP: x86_64-linux-gnu-objdump PKG_CONFIG_PATH: /usr/lib/x86_64-linux-gnu/pkgconfig @@ -267,7 +268,7 @@ Debian stable:amd64: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Debian stable:i386: - <<: *job_build + stage: build artifacts: paths: @@ -308,7 +309,7 @@ Debian stable:i386: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Debian stable:arm64: - <<: *job_build + stage: build artifacts: paths: @@ -319,6 +320,7 @@ Debian stable:arm64: variables: CC: aarch64-linux-gnu-gcc + LDFLAGS: -Wl,-fuse-ld=gold OBJCOPY: aarch64-linux-gnu-objcopy OBJDUMP: aarch64-linux-gnu-objdump PKG_CONFIG_PATH: /usr/lib/aarch64-linux-gnu/pkgconfig @@ -349,7 +351,7 @@ Debian stable:arm64: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Windows x64: - <<: *job_build + stage: build artifacts: paths: @@ -379,20 +381,18 @@ Windows x64: echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" Debian stable Clang: - <<: *job_build + stage: build allow_failure: true artifacts: - paths: - - "bin/" - - "src/comptime.h" - expose_as: "Debian Clang" name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-clang" variables: CC: clang WFLAGS: -Wno-cast-align + CFLAGS: -Wno-cast-align + LDFLAGS: -Wl,-fuse-ld=gold script: - - | @@ -425,12 +425,10 @@ Debian testing Clang: image: debian:testing-slim artifacts: - paths: - - "bin/" - - "src/comptime.h" - expose_as: "Debina Clang testing" name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-testing-clang" variables: CC: clang WFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype + CFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype + LDFLAGS: -Wl,-fuse-ld=gold From c4bd5f7e8ad23ec1435c11718234ee5a76a07c3e Mon Sep 17 00:00:00 2001 From: Alam Ed Aria Date: Tue, 21 Nov 2023 11:39:20 -0500 Subject: [PATCH 18/18] GitLab CI: update with SRB2's master --- .gitlab-ci.yml | 73 +++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 72 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b292bfc0..4e284ce6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -159,6 +159,9 @@ stages: Debian testing GCC: stage: build + + when: manual + image: debian:testing-slim allow_failure: true @@ -198,6 +201,8 @@ Debian testing GCC: Windows x86: stage: build + when: on_success + artifacts: paths: - "bin/" @@ -228,6 +233,8 @@ Windows x86: Debian stable:amd64: stage: build + when: on_success + artifacts: paths: - "bin/" @@ -270,6 +277,8 @@ Debian stable:amd64: Debian stable:i386: stage: build + when: manual + artifacts: paths: - "bin/" @@ -311,6 +320,8 @@ Debian stable:i386: Debian stable:arm64: stage: build + when: manual + artifacts: paths: - "bin/" @@ -345,7 +356,7 @@ Debian stable:arm64: - - | # make echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" - - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 ERRORMODE=1 NONX86=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 NONX86=1 + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 ERRORMODE=1 NONX86=1 ARM64=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 LINUX64=1 NONX86=1 ARM64=1 - | # make echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" @@ -353,6 +364,8 @@ Debian stable:arm64: Windows x64: stage: build + when: manual + artifacts: paths: - "bin/" @@ -383,6 +396,8 @@ Windows x64: Debian stable Clang: stage: build + when: manual + allow_failure: true artifacts: @@ -419,9 +434,50 @@ Debian stable Clang: # make echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" +Debian stable musl: + stage: build + + when: manual + + allow_failure: true + + artifacts: + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-musl" + + variables: + CC: musl-gcc + LDD: musl-ldd + + script: + - - | + # apt_toolchain + echo -e "\e[0Ksection_start:`date +%s`:apt_toolchain[collapsed=true]\r\e[0KInstalling toolchain packages" + - apt-get install gcc + - | + # apt_toolchain + echo -e "\e[0Ksection_end:`date +%s`:apt_toolchain\r\e[0K" + + - - | + # apt_development + echo -e "\e[0Ksection_start:`date +%s`:apt_development[collapsed=true]\r\e[0KInstalling development packages" + - apt-get install musl-tools + - | + # apt_development + echo -e "\e[0Ksection_end:`date +%s`:apt_development\r\e[0K" + + - - | + # make + echo -e "\e[0Ksection_start:`date +%s`:make[collapsed=false]\r\e[0KCompiling SRB2" + - make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 SDL=0 NOHW=1 NOZLIB=1 NOCURL=1 NOGME=1 NOOPENMPT=1 || make --directory=src --keep-going CCACHE=1 ERRORMODE=1 NONX86=1 SDL=0 NOHW=1 NOZLIB=1 NOCURL=1 NOGME=1 NOOPENMPT=1 + - | + # make + echo -e "\e[0Ksection_end:`date +%s`:make\r\e[0K" + Debian testing Clang: extends: Debian stable Clang + when: manual + image: debian:testing-slim artifacts: @@ -432,3 +488,18 @@ Debian testing Clang: WFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype CFLAGS: -Wno-cast-align -Wno-deprecated-non-prototype LDFLAGS: -Wl,-fuse-ld=gold + +Debian testing musl: + extends: Debian stable musl + + when: manual + + image: debian:testing-slim + + artifacts: + name: "$CI_PROJECT_PATH_SLUG-$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA-testing-musl" + + variables: + CC: musl-gcc + LDD: musl-ldd + LDFLAGS: -Wl,-fuse-ld=gold