allegro: add some hacks to make this build with llvm 19

Still builds on current i386, sparc64 and amd64 and unlocks half a dozen
more ports.

"i think this is fine" landry
This commit is contained in:
tb
2025-01-31 08:18:03 +00:00
parent c4f33286b8
commit 5da1894d42
2 changed files with 19 additions and 5 deletions
+7 -3
View File
@@ -4,7 +4,7 @@ COMMENT = game programming library for C/C++ developers
V = 4.2.3
DISTNAME = allegro-$V
REVISION = 8
REVISION = 9
CATEGORIES = games devel multimedia
SHARED_LIBS = alleg 1.0 # 4.2
@@ -25,9 +25,11 @@ AUTOCONF_VERSION = 2.63
SUBST_VARS = V
WANTLIB = X11 Xcursor Xext Xpm Xxf86dga Xxf86vm c m \
WANTLIB = ${COMPILER_LIBCXX} X11 Xcursor Xext Xpm Xxf86dga Xxf86vm c m \
sndio pthread
LDFLAGS += ${COMPILER_LIBCXX:S/^/-l/}
CONFIGURE_ARGS = --enable-artsdigi=no \
--enable-esddigi=no \
--enable-jackdigi=no \
@@ -38,8 +40,10 @@ CONFIGURE_ARGS = --enable-artsdigi=no \
# XXX work around bogus configure entry with clang
CONFIGURE_ENV = allegro_cv_support_include_prefix=yes
CONFIGURE_ENV += LDFLAGS="${LDFLAGS}"
.if ${MACHINE_ARCH} == "i386"
CONFIGURE_ENV += LDFLAGS="-Wl,-znotext"
LDFLAGS += -Wl,-znotext
.endif
MAKE_ENV += shared_major_minor=${LIBalleg_VERSION}
+12 -2
View File
@@ -1,5 +1,6 @@
--- configure.in.orig Sat Jul 14 21:46:22 2007
+++ configure.in Wed Jan 13 01:30:01 2010
Index: configure.in
--- configure.in.orig
+++ configure.in
@@ -28,26 +28,26 @@ allegro_enable_asm=yes)
dnl Enable 8-bpp color depth (default).
AC_ARG_ENABLE(color8,
@@ -177,3 +178,12 @@
fi
ALLEGRO_SFLAGS="-x assembler-with-cpp"
ALLEGRO_SHAREDLIB_CFLAGS="-fPIC -DALLEGRO_SHARED"
@@ -858,7 +873,7 @@ AC_SUBST(ALLEGRO_SHAREDLIB_CFLAGS)
dnl How to compile C++ files.
if test "X$allegro_cv_support_cplusplus" = "Xyes"; then
- CXX="$CC"
+ CXX="${CXX}"
CXXFLAGS="-fno-exceptions $CFLAGS"
ALLEGRO_DEBUG_CXXFLAGS="-fno-exceptions $ALLEGRO_DEBUG_CFLAGS"
ALLEGRO_PROFILE_CXXFLAGS="-fno-exceptions $ALLEGRO_PROFILE_CFLAGS"