mirror of
https://anongit.gentoo.org/git/repo/gentoo.git
synced 2025-12-16 15:14:38 +00:00
- Build system changed to cmake - Some USE flags were removed due to build options being removed upstream. - Dropped ~x86 keywords due to the above. Vulkan support was also added upstream but I could not get the game to run with it (segfault at launch). This ebuild needs to pull both the "unified" zip from upstream releases as well as the source tarball because the former contains the game assets which are unfortunately stored in Git LFS and are not present in the latter. Should that be worked around, this ebuild can be easily adapted to pack the game assets into the required .pk3 files. Signed-off-by: Kenton Groombridge <concord@gentoo.org> Part-of: https://github.com/gentoo/gentoo/pull/42805 Closes: https://github.com/gentoo/gentoo/pull/42805 Signed-off-by: Kenton Groombridge <concord@gentoo.org>
75 lines
2.4 KiB
Diff
75 lines
2.4 KiB
Diff
From 5604ddf69b47e314150191c56a04b7009d885160 Mon Sep 17 00:00:00 2001
|
|
From: Tim Angus <tim@ngus.net>
|
|
Date: Sat, 8 Mar 2025 13:00:48 +0000
|
|
Subject: [PATCH] Rename LCC constexpr function to constantexpr, avoiding C23
|
|
keyword clash
|
|
|
|
fixes #349
|
|
---
|
|
code/tools/lcc/src/c.h | 2 +-
|
|
code/tools/lcc/src/init.c | 2 +-
|
|
code/tools/lcc/src/simp.c | 4 ++--
|
|
code/tools/lcc/src/stmt.c | 2 +-
|
|
4 files changed, 5 insertions(+), 5 deletions(-)
|
|
|
|
diff --git a/code/tools/lcc/src/c.h b/code/tools/lcc/src/c.h
|
|
index d8560a020..2260141e3 100644
|
|
--- a/code/tools/lcc/src/c.h
|
|
+++ b/code/tools/lcc/src/c.h
|
|
@@ -529,7 +529,7 @@ extern int process(char *);
|
|
extern int findfunc(char *, char *);
|
|
extern int findcount(char *, int, int);
|
|
|
|
-extern Tree constexpr(int);
|
|
+extern Tree constantexpr(int);
|
|
extern int intexpr(int, int);
|
|
extern Tree simplify(int, Type, Tree, Tree);
|
|
extern int ispow2(unsigned long u);
|
|
diff --git a/code/tools/lcc/src/init.c b/code/tools/lcc/src/init.c
|
|
index 64d73d319..972abf530 100644
|
|
--- a/code/tools/lcc/src/init.c
|
|
+++ b/code/tools/lcc/src/init.c
|
|
@@ -190,7 +190,7 @@ static int initstruct(int len, Type ty, int lev) {
|
|
return n;
|
|
}
|
|
|
|
-/* initializer - constexpr | { constexpr ( , constexpr )* [ , ] } */
|
|
+/* initializer - constantexpr | { constantexpr ( , constantexpr )* [ , ] } */
|
|
Type initializer(Type ty, int lev) {
|
|
int n = 0;
|
|
Tree e;
|
|
diff --git a/code/tools/lcc/src/simp.c b/code/tools/lcc/src/simp.c
|
|
index 9f4e3ecc3..50e83e484 100644
|
|
--- a/code/tools/lcc/src/simp.c
|
|
+++ b/code/tools/lcc/src/simp.c
|
|
@@ -167,7 +167,7 @@ static int subi(long x, long y, long min, long max, int needconst) {
|
|
static int subd(double x, double y, double min, double max, int needconst) {
|
|
return addd(x, -y, min, max, needconst);
|
|
}
|
|
-Tree constexpr(int tok) {
|
|
+Tree constantexpr(int tok) {
|
|
Tree p;
|
|
|
|
needconst++;
|
|
@@ -177,7 +177,7 @@ Tree constexpr(int tok) {
|
|
}
|
|
|
|
int intexpr(int tok, int n) {
|
|
- Tree p = constexpr(tok);
|
|
+ Tree p = constantexpr(tok);
|
|
|
|
needconst++;
|
|
if (p->op == CNST + I || p->op == CNST + U)
|
|
diff --git a/code/tools/lcc/src/stmt.c b/code/tools/lcc/src/stmt.c
|
|
index fe83e21f8..a65efc0ec 100644
|
|
--- a/code/tools/lcc/src/stmt.c
|
|
+++ b/code/tools/lcc/src/stmt.c
|
|
@@ -128,7 +128,7 @@
|
|
static char stop[] = {IF, ID, 0};
|
|
Tree p;
|
|
t = gettok();
|
|
- p = constexpr(0);
|
|
+ p = constantexpr(0);
|
|
if (generic(p->op) == CNST && isint(p->type)) {
|
|
if (swp) {
|
|
needconst++;
|