mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 09:47:35 +00:00
Ports: Update dosbox-staging to 0.77.1
This version of 'dosbox-staging' uses the meson build system. Previous versions of dosbox-staging started in windowed mode with a resolution of 320x200. This version starts in windowed mode with a resolution of 640x480. Audio was stuttering a bit in previous versions, but it sounds like it might have become a bit worse. This is probably because of higher CPU usage and the audio server/client not able to keep up. Added a post_install() section to package script which outputs a link to dosbox-staging's release notes.
This commit is contained in:
parent
9541f23376
commit
03ca560b2d
10 changed files with 166 additions and 87 deletions
|
@ -47,7 +47,7 @@ This list is also available at [ports.serenityos.net](https://ports.serenityos.n
|
||||||
| [`dmidecode`](dmidecode/) | dmidecode | 3.5 | https://github.com/mirror/dmidecode |
|
| [`dmidecode`](dmidecode/) | dmidecode | 3.5 | https://github.com/mirror/dmidecode |
|
||||||
| [`doom`](doom/) | DOOM | | https://github.com/SerenityOS/SerenityDOOM |
|
| [`doom`](doom/) | DOOM | | https://github.com/SerenityOS/SerenityDOOM |
|
||||||
| [`dos2unix`](dos2unix/) | dos2unix | 7.4.4 | https://waterlan.home.xs4all.nl/dos2unix.html |
|
| [`dos2unix`](dos2unix/) | dos2unix | 7.4.4 | https://waterlan.home.xs4all.nl/dos2unix.html |
|
||||||
| [`dosbox-staging`](dosbox-staging/) | DOSBox Staging | 0.76.0 | https://dosbox-staging.github.io/ |
|
| [`dosbox-staging`](dosbox-staging/) | DOSBox Staging | 0.77.1 | https://dosbox-staging.github.io/ |
|
||||||
| [`dosfstools`](dosfstools/) | dosfstools utility suite | 4.2 | https://github.com/dosfstools/dosfstools/ |
|
| [`dosfstools`](dosfstools/) | dosfstools utility suite | 4.2 | https://github.com/dosfstools/dosfstools/ |
|
||||||
| [`double-conversion`](double-conversion/) | double-conversion | 3.2.1 | https://github.com/google/double-conversion |
|
| [`double-conversion`](double-conversion/) | double-conversion | 3.2.1 | https://github.com/google/double-conversion |
|
||||||
| [`drascula`](drascula/) | Dráscula: The Vampire Strikes Back | 1.0 | https://www.scummvm.org/games/#games-drascula |
|
| [`drascula`](drascula/) | Dráscula: The Vampire Strikes Back | 1.0 | https://www.scummvm.org/games/#games-drascula |
|
||||||
|
|
|
@ -1,27 +1,48 @@
|
||||||
#!/usr/bin/env -S bash ../.port_include.sh
|
#!/usr/bin/env -S bash ../.port_include.sh
|
||||||
port='dosbox-staging'
|
port='dosbox-staging'
|
||||||
version='0.76.0'
|
version='0.77.1'
|
||||||
useconfigure='true'
|
useconfigure='true'
|
||||||
configopts=(
|
configopts=(
|
||||||
'--disable-fluidsynth'
|
"--cross-file" "${SERENITY_BUILD_DIR}/meson-cross-file.txt"
|
||||||
'--disable-dynamic-core'
|
'-Ddynamic_core=none'
|
||||||
'--disable-opus-cdda'
|
'-Dtry_static_libs=opusfile'
|
||||||
|
'-Dunit_tests=disabled'
|
||||||
|
'-Duse_fluidsynth=false'
|
||||||
|
'-Duse_mt32emu=false'
|
||||||
|
'-Duse_opengl=false'
|
||||||
|
'-Duse_png=false'
|
||||||
)
|
)
|
||||||
files="https://github.com/dosbox-staging/dosbox-staging/archive/refs/tags/v${version}.tar.gz v${version}.tar.gz 7df53c22f7ce78c70afb60b26b06742b90193b56c510219979bf12e0bb2dc6c7"
|
files="https://github.com/dosbox-staging/dosbox-staging/archive/refs/tags/v${version}.tar.gz v${version}.tar.gz 85359efb7cd5c5c0336d88bdf023b7b462a8233490e00274fef0b85cca2f5f3c"
|
||||||
auth_type='sha256'
|
auth_type='sha256'
|
||||||
depends=(
|
depends=(
|
||||||
|
'libslirp'
|
||||||
'libpng'
|
'libpng'
|
||||||
|
'opusfile'
|
||||||
'SDL2'
|
'SDL2'
|
||||||
|
'SDL2_net'
|
||||||
)
|
)
|
||||||
launcher_name='DOSBox'
|
launcher_name='DOSBox'
|
||||||
launcher_category='Games'
|
launcher_category='Games'
|
||||||
launcher_command='/usr/local/bin/dosbox'
|
launcher_command='/usr/local/bin/dosbox'
|
||||||
icon_file='contrib/icons/dosbox-staging.ico'
|
icon_file='contrib/icons/dosbox-staging.ico'
|
||||||
use_fresh_config_sub='true'
|
|
||||||
|
|
||||||
export CFLAGS="-I${SERENITY_INSTALL_ROOT}/usr/local/include/SDL2"
|
configure() {
|
||||||
export CPPFLAGS="-I${SERENITY_INSTALL_ROOT}/usr/local/include/SDL2"
|
run meson setup build/release "${configopts[@]}"
|
||||||
|
}
|
||||||
pre_patch() {
|
|
||||||
run ./autogen.sh
|
build() {
|
||||||
|
run ninja -C build/release
|
||||||
|
}
|
||||||
|
|
||||||
|
install() {
|
||||||
|
export DESTDIR="${SERENITY_INSTALL_ROOT}"
|
||||||
|
run meson install -C build/release
|
||||||
|
}
|
||||||
|
|
||||||
|
post_install() {
|
||||||
|
echo
|
||||||
|
echo "DOSBox Staging ${version} is installed!"
|
||||||
|
echo
|
||||||
|
echo "Release notes: https://dosbox-staging.github.io/downloads/release-notes/${version}/"
|
||||||
|
echo
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,7 @@ We don't have that yet.
|
||||||
1 file changed, 6 insertions(+)
|
1 file changed, 6 insertions(+)
|
||||||
|
|
||||||
diff --git a/src/misc/fs_utils_posix.cpp b/src/misc/fs_utils_posix.cpp
|
diff --git a/src/misc/fs_utils_posix.cpp b/src/misc/fs_utils_posix.cpp
|
||||||
index fa09872..96002ac 100644
|
index bd90201ba2913f72c26beb88f9bc1f06f491754c..c9a7fc59c8b87e8e4cbd14679e89f5d79a49459f 100644
|
||||||
--- a/src/misc/fs_utils_posix.cpp
|
--- a/src/misc/fs_utils_posix.cpp
|
||||||
+++ b/src/misc/fs_utils_posix.cpp
|
+++ b/src/misc/fs_utils_posix.cpp
|
||||||
@@ -24,7 +24,9 @@
|
@@ -24,7 +24,9 @@
|
||||||
|
|
|
@ -8,10 +8,10 @@ Subject: [PATCH] Disable SDL's accelerated rendering
|
||||||
1 file changed, 1 deletion(-)
|
1 file changed, 1 deletion(-)
|
||||||
|
|
||||||
diff --git a/src/gui/sdlmain.cpp b/src/gui/sdlmain.cpp
|
diff --git a/src/gui/sdlmain.cpp b/src/gui/sdlmain.cpp
|
||||||
index 7039f27..d445ebd 100644
|
index c85a9f53cefe09821bb73a154ef7c663b90c3bc9..d0e32221716761d459f537cef5c0e8afe4b75e72 100644
|
||||||
--- a/src/gui/sdlmain.cpp
|
--- a/src/gui/sdlmain.cpp
|
||||||
+++ b/src/gui/sdlmain.cpp
|
+++ b/src/gui/sdlmain.cpp
|
||||||
@@ -1048,7 +1048,6 @@ dosurface:
|
@@ -1078,7 +1078,6 @@ dosurface:
|
||||||
if (sdl.render_driver != "auto")
|
if (sdl.render_driver != "auto")
|
||||||
SDL_SetHint(SDL_HINT_RENDER_DRIVER, sdl.render_driver.c_str());
|
SDL_SetHint(SDL_HINT_RENDER_DRIVER, sdl.render_driver.c_str());
|
||||||
sdl.renderer = SDL_CreateRenderer(sdl.window, -1,
|
sdl.renderer = SDL_CreateRenderer(sdl.window, -1,
|
|
@ -1,33 +0,0 @@
|
||||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Gunnar Beutner <gbeutner@serenityos.org>
|
|
||||||
Date: Fri, 18 Jun 2021 15:06:37 +0200
|
|
||||||
Subject: [PATCH] Replace some size_t => Bitu
|
|
||||||
|
|
||||||
FIXME: No information as to why this is a thing exists as of yet, fill
|
|
||||||
them in when that stuff is known.
|
|
||||||
---
|
|
||||||
src/hardware/gus.cpp | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/hardware/gus.cpp b/src/hardware/gus.cpp
|
|
||||||
index 355a082..6c20b5c 100644
|
|
||||||
--- a/src/hardware/gus.cpp
|
|
||||||
+++ b/src/hardware/gus.cpp
|
|
||||||
@@ -245,7 +245,7 @@ private:
|
|
||||||
void PopulatePanScalars() noexcept;
|
|
||||||
void PopulateVolScalars() noexcept;
|
|
||||||
void PrepareForPlayback() noexcept;
|
|
||||||
- size_t ReadFromPort(const size_t port, const size_t iolen);
|
|
||||||
+ Bitu ReadFromPort(const Bitu port, const Bitu iolen);
|
|
||||||
void RegisterIoHandlers();
|
|
||||||
void Reset(uint8_t state);
|
|
||||||
void SetLevelCallback(const AudioFrame &level);
|
|
||||||
@@ -253,7 +253,7 @@ private:
|
|
||||||
void UpdateDmaAddress(uint8_t new_address);
|
|
||||||
void UpdateWaveMsw(int32_t &addr) const noexcept;
|
|
||||||
void UpdateWaveLsw(int32_t &addr) const noexcept;
|
|
||||||
- void WriteToPort(size_t port, size_t val, size_t iolen);
|
|
||||||
+ void WriteToPort(Bitu port, Bitu val, Bitu iolen);
|
|
||||||
void WriteToRegister();
|
|
||||||
|
|
||||||
// Collections
|
|
|
@ -1,26 +0,0 @@
|
||||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Gunnar Beutner <gbeutner@serenityos.org>
|
|
||||||
Date: Fri, 18 Jun 2021 15:06:37 +0200
|
|
||||||
Subject: [PATCH] Manually hardcode SDL2 library name
|
|
||||||
|
|
||||||
---
|
|
||||||
configure.ac | 6 ++----
|
|
||||||
1 file changed, 2 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/configure.ac b/configure.ac
|
|
||||||
index 28e9281..1cc3691 100644
|
|
||||||
--- a/configure.ac
|
|
||||||
+++ b/configure.ac
|
|
||||||
@@ -45,10 +45,8 @@ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
|
|
||||||
|
|
||||||
dnl Check for SDL
|
|
||||||
SDL_VERSION=2.0.2
|
|
||||||
-AM_PATH_SDL($SDL_VERSION,
|
|
||||||
- :,
|
|
||||||
- AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!])
|
|
||||||
-)
|
|
||||||
+SDL_LIBS="-lSDL2"
|
|
||||||
+SDL_CFLAGS=""
|
|
||||||
PRESDL_LIBS="$LIBS"
|
|
||||||
LIBS="$LIBS $SDL_LIBS"
|
|
||||||
CPPFLAGS="$CPPFLAGS $SDL_CFLAGS"
|
|
|
@ -0,0 +1,31 @@
|
||||||
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Kenneth Myhra <kennethmyhra@gmail.com>
|
||||||
|
Date: Thu, 4 May 2023 22:35:56 +0200
|
||||||
|
Subject: [PATCH] [bios.cpp] Serenity has time.h
|
||||||
|
|
||||||
|
---
|
||||||
|
src/ints/bios.cpp | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/ints/bios.cpp b/src/ints/bios.cpp
|
||||||
|
index 4ccbe1609ba11d5d69f59ed15735e5a88cbb162a..257f8ce10bf5d5b8c9f145647764d8542e55fc51 100644
|
||||||
|
--- a/src/ints/bios.cpp
|
||||||
|
+++ b/src/ints/bios.cpp
|
||||||
|
@@ -33,7 +33,7 @@
|
||||||
|
#include "serialport.h"
|
||||||
|
#include <time.h>
|
||||||
|
|
||||||
|
-#if defined(HAVE_CLOCK_GETTIME) && !defined(WIN32)
|
||||||
|
+#if defined(HAVE_CLOCK_GETTIME) || defined(__serenity__) && !defined(WIN32)
|
||||||
|
//time.h is already included
|
||||||
|
#else
|
||||||
|
#include <sys/timeb.h>
|
||||||
|
@@ -496,7 +496,7 @@ static void BIOS_HostTimeSync() {
|
||||||
|
Bit32u milli = 0;
|
||||||
|
// TODO investigate if clock_gettime and ftime can be replaced
|
||||||
|
// by using C++11 chrono
|
||||||
|
-#if defined(HAVE_CLOCK_GETTIME) && !defined(WIN32)
|
||||||
|
+#if defined(HAVE_CLOCK_GETTIME) || defined(__serenity__) && !defined(WIN32)
|
||||||
|
struct timespec tp;
|
||||||
|
clock_gettime(CLOCK_REALTIME,&tp);
|
||||||
|
|
|
@ -0,0 +1,21 @@
|
||||||
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Kenneth Myhra <kennethmyhra@gmail.com>
|
||||||
|
Date: Fri, 5 May 2023 07:36:53 +0200
|
||||||
|
Subject: [PATCH] [meson.build] Add 'serenity' to list of os families
|
||||||
|
|
||||||
|
---
|
||||||
|
meson.build | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/meson.build b/meson.build
|
||||||
|
index d0794072239b7b48597cf299d9297fbc1a59d983..75b3c752c34e892e4215065d8bf32cafad9952c2 100644
|
||||||
|
--- a/meson.build
|
||||||
|
+++ b/meson.build
|
||||||
|
@@ -50,6 +50,7 @@ os_family_name = {
|
||||||
|
'netbsd' : 'BSD',
|
||||||
|
'openbsd' : 'BSD',
|
||||||
|
'dragonfly' : 'BSD',
|
||||||
|
+ 'serenity' : 'LINUX',
|
||||||
|
}.get(host_machine.system(), 'UNKNOWN_OS')
|
||||||
|
conf_data.set(os_family_name, 1)
|
||||||
|
|
|
@ -0,0 +1,62 @@
|
||||||
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Kenneth Myhra <kennethmyhra@gmail.com>
|
||||||
|
Date: Fri, 5 May 2023 07:45:29 +0200
|
||||||
|
Subject: [PATCH] [libserial.cpp] Patch out ioctl flags we currently do not
|
||||||
|
support
|
||||||
|
|
||||||
|
---
|
||||||
|
src/hardware/serialport/libserial.cpp | 16 ++++++++++++++++
|
||||||
|
1 file changed, 16 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/src/hardware/serialport/libserial.cpp b/src/hardware/serialport/libserial.cpp
|
||||||
|
index a3dad0980308089a0869001cac31b5c7661dd5df..7899e9cf9bfed065831a23d45aaeac907eee7b97 100644
|
||||||
|
--- a/src/hardware/serialport/libserial.cpp
|
||||||
|
+++ b/src/hardware/serialport/libserial.cpp
|
||||||
|
@@ -360,6 +360,7 @@ void SERIAL_getErrorString(char* buffer, size_t length) {
|
||||||
|
}
|
||||||
|
|
||||||
|
int SERIAL_getmodemstatus(COMPORT port) {
|
||||||
|
+#ifndef __serenity__
|
||||||
|
long flags = 0;
|
||||||
|
ioctl (port->porthandle, TIOCMGET, &flags);
|
||||||
|
int retval = 0;
|
||||||
|
@@ -368,6 +369,9 @@ int SERIAL_getmodemstatus(COMPORT port) {
|
||||||
|
if (flags & TIOCM_RI) retval |= SERIAL_RI;
|
||||||
|
if (flags & TIOCM_CD) retval |= SERIAL_CD;
|
||||||
|
return retval;
|
||||||
|
+#else
|
||||||
|
+ return 0;
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
bool SERIAL_sendchar(COMPORT port, char data) {
|
||||||
|
@@ -463,17 +467,29 @@ bool SERIAL_setCommParameters(COMPORT port,
|
||||||
|
}
|
||||||
|
|
||||||
|
void SERIAL_setBREAK(COMPORT port, bool value) {
|
||||||
|
+#ifdef __serenity__
|
||||||
|
+ // Do nothing.
|
||||||
|
+#else
|
||||||
|
ioctl(port->porthandle, value?TIOCSBRK:TIOCCBRK);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void SERIAL_setDTR(COMPORT port, bool value) {
|
||||||
|
+#ifdef __serenity__
|
||||||
|
+ // Do nothing.
|
||||||
|
+#else
|
||||||
|
long flag = TIOCM_DTR;
|
||||||
|
ioctl(port->porthandle, value?TIOCMBIS:TIOCMBIC, &flag);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void SERIAL_setRTS(COMPORT port, bool value) {
|
||||||
|
+#ifdef __serenity__
|
||||||
|
+ // Do nothing.
|
||||||
|
+#else
|
||||||
|
long flag = TIOCM_RTS;
|
||||||
|
ioctl(port->porthandle, value?TIOCMBIS:TIOCMBIC, &flag);
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
|
@ -6,20 +6,23 @@ Skip use of glob() in serenity
|
||||||
|
|
||||||
We don't have that yet.
|
We don't have that yet.
|
||||||
|
|
||||||
## `0002-Replace-some-size_t-Bitu.patch`
|
## `0002-Disable-SDL-s-accelerated-rendering.patch`
|
||||||
|
|
||||||
Replace some size_t => Bitu
|
|
||||||
|
|
||||||
FIXME: No information as to why this is a thing exists as of yet, fill
|
|
||||||
them in when that stuff is known.
|
|
||||||
|
|
||||||
## `0003-Manually-hardcode-SDL2-library-name.patch`
|
|
||||||
|
|
||||||
Manually hardcode SDL2 library name
|
|
||||||
|
|
||||||
|
|
||||||
## `0004-Disable-SDL-s-accelerated-rendering.patch`
|
|
||||||
|
|
||||||
Disable SDL's accelerated rendering
|
Disable SDL's accelerated rendering
|
||||||
|
|
||||||
|
|
||||||
|
## `0003-bios.cpp-Serenity-has-time.h.patch`
|
||||||
|
|
||||||
|
Serenity has time.h
|
||||||
|
|
||||||
|
|
||||||
|
## `0004-meson.build-Add-serenity-to-list-of-os-families.patch`
|
||||||
|
|
||||||
|
Add 'serenity' to list of os families
|
||||||
|
|
||||||
|
|
||||||
|
## `0005-libserial.cpp-Patch-out-ioctl-flags-we-currently-do-.patch`
|
||||||
|
|
||||||
|
Patch out ioctl flags we currently do not support
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue