Ports: Update emu2

This allows us to drop a patch and doesn't force us to explicitely
specify CC anymore.
This commit is contained in:
Lucas Chollet authored and Sönke Holz committed 2026-02-27 11:31:05 +01:00
1 parent 835be1085d
commit 38439f4cc8
8 files changed
+37 -82

No files matched your search

+1 -1
View File
@@ -70,7 +70,7 @@ This list is also available at [ports.serenityos.net](https://ports.serenityos.n
| [`ed`](ed/) | GNU ed | 1.22 | https://www.gnu.org/software/ed/ |
| [`edid-decode`](edid-decode/) | edid-decode | 20220315.cb74358c2896 | https://git.linuxtv.org/edid-decode |
| [`editline`](editline/) | editline | 1.17.1 | https://github.com/troglobit/editline |
| [`emu2`](emu2/) | emu2 DOS emulator | 2021.01 | https://github.com/dmsc/emu2 |
| [`emu2`](emu2/) | emu2 DOS emulator | 4948d1e | https://github.com/dmsc/emu2 |
| [`epsilon`](epsilon/) | graphical calculator simulator | 15.5.0 | https://github.com/numworks/epsilon |
| [`expat`](expat/) | Expat XML parser | 2.5.0 | https://libexpat.github.io/ |
| [`FAudio`](FAudio/) | FAudio | 26.01 | https://fna-xna.github.io/ |
+3 -4
View File
@@ -1,11 +1,10 @@
#!/usr/bin/env -S bash ../.port_include.sh
port=emu2
version="2021.01"
version="4948d1e12b952f0a30c7e4aa8fa380b51c0c84a7"
files=(
"https://github.com/dmsc/emu2/archive/refs/tags/v${version}.tar.gz#32ea656ad9b034d2c91a20f1a9ac1779cb6905a019c5bdeda9338cfd673bbd72"
"https://github.com/dmsc/emu2/archive/${version}.zip#407b0a1bbd4ea561ef8b547a74d811fb705d7e0f5c72b6d7d5db5900708c5f19"
)
build() {
export CC="${SERENITY_SOURCE_DIR}/Toolchain/Local/${SERENITY_ARCH}/bin/${SERENITY_ARCH}-pc-serenity-gcc"
run make DESTDIR="${SERENITY_INSTALL_ROOT}" CC="${CC}" "${installopts[@]}"
run make "${installopts[@]}"
}
@@ -8,7 +8,7 @@ Subject: [PATCH] Include <strings.h>
1 file changed, 1 insertion(+)
diff --git a/src/codepage.c b/src/codepage.c
index 3916b61..9df0bd8 100644
index a67e230dde65783a88a2ef26c493e2352f43ba5b..26fdb1ae591d9dc58e2c34a60bd04cfa2621bcc3 100644
--- a/src/codepage.c
+++ b/src/codepage.c
@@ -3,6 +3,7 @@
@@ -0,0 +1,22 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Gunnar Beutner <[email protected]>
Date: Thu, 26 Feb 2026 20:36:30 +0100
Subject: [PATCH] Install into /usr/local
---
GNUmakefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/GNUmakefile b/GNUmakefile
index 290e5b074c9b59123aee50e7bdbb526b0130d5fd..27ee92fdebe94da589288a763da73146162456a0 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -2,7 +2,7 @@ SHELL=/bin/sh
CFLAGS?=-O3
LDLIBS?=-lm
INSTALL?=install
-PREFIX?=/usr
+PREFIX?=/usr/local
include platform.mk
@@ -1,31 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Brendan Coles <[email protected]>
Date: Thu, 23 Dec 2021 10:26:29 +0100
Subject: [PATCH] Replace a use of rindex() with strrchr()
Co-Authored-By: Daniel Bertalan <[email protected]>
---
src/dosnames.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/dosnames.c b/src/dosnames.c
index b6122a9..582a0e2 100644
--- a/src/dosnames.c
+++ b/src/dosnames.c
@@ -9,6 +9,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <strings.h>
#include <sys/stat.h>
// DOS directory entries.
@@ -589,7 +590,7 @@ char *dos_unix_path_fcb(int addr, int force)
static struct dos_file_list *find_first_file(char *fspec)
{
// Now, separate the path to the spec
- char *glob, *unixpath, *p = rindex(fspec, '/');
+ char *glob, *unixpath, *p = strrchr(fspec, '/');
if(!p)
{
glob = fspec;
@@ -5,25 +5,17 @@ Subject: [PATCH] Don't use setitimer()
Co-Authored-By: Tim Schumacher <[email protected]>
---
src/main.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
src/main.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/src/main.c b/src/main.c
index d0c0d2f..7e313a0 100644
index 7d9c9f59d915cbb09c8b973417b053e2ab277602..baa4fde91fdfee4bc97dc4b2ba3ff1d59c6bc246 100644
--- a/src/main.c
+++ b/src/main.c
@@ -12,6 +12,7 @@
#include <errno.h>
#include <fcntl.h>
#include <math.h>
+#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -304,12 +305,6 @@ int main(int argc, char **argv)
signal(SIGQUIT, exit_handler);
signal(SIGPIPE, exit_handler);
signal(SIGTERM, exit_handler);
@@ -336,12 +336,6 @@ int main(int argc, char **argv)
sigaction(SIGQUIT, &exit_action, NULL);
sigaction(SIGPIPE, &exit_action, NULL);
sigaction(SIGTERM, &exit_action, NULL);
- struct itimerval itv;
- itv.it_interval.tv_sec = 0;
- itv.it_interval.tv_usec = 54925;
@@ -31,5 +23,5 @@ index d0c0d2f..7e313a0 100644
- itv.it_value.tv_usec = 54925;
- setitimer(ITIMER_REAL, &itv, 0);
init_bios_mem();
video_init_mem();
while(1)
{
@@ -1,22 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Gunnar Beutner <[email protected]>
Date: Thu, 15 Apr 2021 15:43:18 +0200
Subject: [PATCH] Install into /usr/local
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index 80dd6ec..7026600 100644
--- a/Makefile
+++ b/Makefile
@@ -2,7 +2,7 @@ CC=gcc
CFLAGS=-O3 -flto -Wall -g -Werror=implicit-function-declaration -Werror=int-conversion
LDLIBS=-lm
INSTALL=install
-PREFIX=/usr
+PREFIX=/usr/local
OBJS=\
cpu.o\
+2 -7
View File
@@ -5,17 +5,12 @@
Include <strings.h>
## `0002-Replace-a-use-of-rindex-with-strrchr.patch`
Replace a use of rindex() with strrchr()
## `0003-Install-into-usr-local.patch`
## `0002-Install-into-usr-local.patch`
Install into /usr/local
## `0004-Don-t-use-setitimer.patch`
## `0003-Don-t-use-setitimer.patch`
Don't use setitimer()