try to unbreak games/godot,-main on gcc arches

platform/x11/detect.py tries to create export templates when building
with GNU ld and tools=no.  GNU ld in base is too old for that and it's
not straightforward to enable them using llvm (upstream says it doesn't
work) so just disable them; they're not that useful for us anyway.

bumping is just a pro-forma in this case: on llvm arches there are no
changes and on gcc-arches the previous version didn't built.

(while here reformat the comment at the top of patch-platform_x11_detect_py)
This commit is contained in:
op 2022-05-06 22:02:47 +00:00
parent f5b0ff8bb9
commit c6cf218d91
2 changed files with 22 additions and 7 deletions

View File

@ -7,7 +7,8 @@ V = 3.4.4
GODOTSTEAM_V = g34-s152-gs311
DISTNAME = godot-${V}-stable
PKGNAME = godot-${V}
REVISION-main = 1
REVISION-main = 2
REVISION-tools = 0
CATEGORIES = games

View File

@ -1,5 +1,7 @@
remove hardcoded -O2, found by bcallah@. Add sndio
enable joydev
- remove hardcoded -O2, found by bcallah@
- add sndio
- enable joydev
- disable template binaries (requires GNU ld but is broken on GCC-arches)
Index: platform/x11/detect.py
--- platform/x11/detect.py.orig
@ -45,13 +47,25 @@ Index: platform/x11/detect.py
if env["pulseaudio"]:
if os.system("pkg-config --exists libpulse") == 0: # 0 means found
env.Append(CPPDEFINES=["PULSEAUDIO_ENABLED"])
@@ -347,6 +328,9 @@ def configure(env):
print("Warning: libudev development libraries not found. Disabling controller hotplugging support.")
@@ -348,6 +329,9 @@ def configure(env):
else:
env["udev"] = False # Linux specific
+
+ if platform.system() == "OpenBSD":
+ env.Append(CPPDEFINES=["JOYDEV_ENABLED"])
+
# Linkflags below this line should typically stay the last ones
if not env["builtin_zlib"]:
env.ParseConfig("pkg-config zlib --cflags --libs")
@@ -375,11 +359,6 @@ def configure(env):
print(
"Warning: Creating template binaries enabled for PCK embedding is currently only supported with GNU ld, not gold or LLD."
)
- else:
- if float(gnu_ld_version.group(1)) >= 2.30:
- env.Append(LINKFLAGS=["-T", "platform/x11/pck_embed.ld"])
- else:
- env.Append(LINKFLAGS=["-T", "platform/x11/pck_embed.legacy.ld"])
## Cross-compilation