gzdoom: only build for 64-bit architectures

Only LP64/LLP64 builds are officially supported. Please do not attempt
to build for other platforms; even if the program succeeds in a MAP01
smoke test, there are e.g. known visual artifacts that lead to a bad
user experience.

Still allow build on 32-bit platforms in case BROKEN is selected, so
users can try if it would work on their system as forum claims a fix
had actually been applied long ago.

Link: https://forum.zdoom.org/viewtopic.php?f=7&t=75673
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This commit is contained in:
Daniel Golle
2024-12-08 20:11:39 +00:00
parent b24439f50b
commit 8add6bc3b6
6 changed files with 38 additions and 1 deletions

View File

@@ -17,6 +17,7 @@ PKG_LICENSE_FILES:=COPYING LICENSE
CMAKE_INSTALL:=1
PKG_BUILD_DEPENDS:=gzdoom/host vulkan-loader
PKG_BUILD_FLAGS:=no-mips16
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/host-build.mk
@@ -32,12 +33,14 @@ CMAKE_OPTIONS += \
-DVULKAN_USE_XLIB=OFF \
-DVULKAN_USE_WAYLAND=ON
TARGET_LDFLAGS += -latomic
define Package/gzdoom
SECTION:=games
CATEGORY:=Games
TITLE:=GZDoom
URL:=https://zdoom.org/
DEPENDS:=+alsa-lib +glib2 +libbz2 +libstdcpp +libzmusic +libvpx +libsdl2 +USE_MUSL:musl-fts
DEPENDS:=+alsa-lib +glib2 +libatomic +libbz2 +libstdcpp +libzmusic +libvpx +libsdl2 +USE_MUSL:musl-fts @(ARCH_64BIT||BROKEN)
endef
define Package/gzdoom/description

View File

@@ -0,0 +1,11 @@
--- a/src/common/platform/posix/sdl/sdlglvideo.cpp
+++ b/src/common/platform/posix/sdl/sdlglvideo.cpp
@@ -400,7 +400,7 @@ DFrameBuffer *SDLVideo::CreateFrameBuffe
builder.RequireExtension(names[i]);
auto instance = builder.Create();
- VkSurfaceKHR surfacehandle = nullptr;
+ VkSurfaceKHR surfacehandle = (VkSurfaceKHR)nullptr;
if (!I_CreateVulkanSurface(instance->Instance, &surfacehandle))
VulkanError("I_CreateVulkanSurface failed");

View File

@@ -0,0 +1,23 @@
--- a/src/common/engine/i_interface.cpp
+++ b/src/common/engine/i_interface.cpp
@@ -6,13 +6,13 @@
#include "gstrings.h"
#include "version.h"
-static_assert(sizeof(void*) == 8,
- "Only LP64/LLP64 builds are officially supported. "
- "Please do not attempt to build for other platforms; "
- "even if the program succeeds in a MAP01 smoke test, "
- "there are e.g. known visual artifacts "
- "<https://forum.zdoom.org/viewtopic.php?f=7&t=75673> "
- "that lead to a bad user experience.");
+//static_assert(sizeof(void*) == 8,
+// "Only LP64/LLP64 builds are officially supported. "
+// "Please do not attempt to build for other platforms; "
+// "even if the program succeeds in a MAP01 smoke test, "
+// "there are e.g. known visual artifacts "
+// "<https://forum.zdoom.org/viewtopic.php?f=7&t=75673> "
+// "that lead to a bad user experience.");
// Some global engine variables taken out of the backend code.
FStartupScreen* StartWindow;