This commit is contained in:
OBattler
2022-04-04 18:20:42 +02:00
20 changed files with 269 additions and 80 deletions

View File

@@ -18,9 +18,9 @@ version: 1
AppDir:
path: ./archive_tmp
app_info:
id: !ENV 'net.${project_lower}.${project_lower}'
id: !ENV 'net.${project_lower}.${project}'
name: !ENV '${project}'
icon: !ENV '${project_lower}'
icon: !ENV '${project_icon}'
version: !ENV '${project_version}'
exec: !ENV 'usr/local/bin/${project}'
exec_args: $@

38
.ci/Jenkinsfile vendored
View File

@@ -15,9 +15,12 @@
* Copyright 2021-2022 RichardG.
*/
def repository = 'https://github.com/86Box/86Box.git'
def commitBrowser = 'https://github.com/86Box/86Box/commit/%s'
def branch = 'master'
/* ['main builds', 'branch builds'] */
def repository = ['https://github.com/86Box/86Box.git', 'https://github.com/richardg867/86Box.git']
def commitBrowser = ['https://github.com/86Box/86Box/commit/%s', null]
def branch = ['master', 'cleanup30']
def buildType = ['beta', 'alpha']
def buildBranch = env.JOB_BASE_NAME.contains('-') ? 1 : 0
def osArchs = [
'Windows': ['32', '64'],
@@ -152,8 +155,8 @@ pipeline {
parameters {
string(name: 'BUILD_TYPE',
defaultValue: 'beta', /* !!! CHANGE HERE !!! for build type */
description: "Build type to pass on to CMake. Should only be changed for one-off builds, otherwise change the default on .ci/Jenkinsfile")
defaultValue: buildType[buildBranch],
description: "Build type to pass on to CMake (on main builds) or feature branch identifier (on branch builds).")
}
stages {
@@ -186,24 +189,33 @@ pipeline {
retry(10) {
node('citadel && !Windows') {
/* Run git clone. */
gitClone(repository, branch)
gitClone(repository[buildBranch], branch[buildBranch])
/* Clean workspace, in case this is running in a non-build node. */
cleanWs()
}
}
/* Determine build metadata. */
def buildFlags = "-D \"BUILD_TYPE=$BUILD_TYPE\" -D \"EMU_BUILD=build ${env.BUILD_NUMBER}\" -D \"EMU_BUILD_NUM=${env.BUILD_NUMBER}\""
def buildSuffix = "-b${env.BUILD_NUMBER}"
if (buildBranch > 0) {
def date = new Date().format("yyyyMMdd")
buildFlags = "-D \"BUILD_TYPE=${buildType[buildBranch]}\" -D \"EMU_BUILD=${env.JOB_BASE_NAME.split('-')[1]} build $date.$BUILD_TYPE\""
buildSuffix = "-$date-$BUILD_TYPE"
}
/* Create source tarball. */
try {
retry(10) {
node('Linux') {
/* Run git clone. */
gitClone(repository, branch)
gitClone(repository[buildBranch], branch[buildBranch])
/* Switch to temp directory. */
dir("${env.WORKSPACE_TMP}/output") {
/* Run source tarball creation process. */
def packageName = "${env.JOB_BASE_NAME}-Source-b${env.BUILD_NUMBER}"
def packageName = "${env.JOB_BASE_NAME}-Source$buildSuffix"
if (runBuild("-s \"$packageName\"") == 0) {
/* Archive resulting artifacts. */
archiveArtifacts artifacts: "$packageName*"
@@ -238,15 +250,15 @@ pipeline {
node(os) {
stage(combination) {
/* Run git clone. */
gitClone(repository, branch)
gitClone(repository[buildBranch], branch[buildBranch])
/* Switch to output directory. */
dir("${env.WORKSPACE_TMP}/output") {
/* Run build process. */
def packageName = "${env.JOB_BASE_NAME}${dynarecSlugs[dynarec]}${presetSlugs[preset]}-$os-$arch-b${env.BUILD_NUMBER}"
def packageName = "${env.JOB_BASE_NAME}${dynarecSlugs[dynarec]}${presetSlugs[preset]}-$os-$arch$buildSuffix"
def ret = -1
dir("${dynarecNames[dynarec]}/$os - ${archNames[arch]}") {
ret = runBuild("-b \"$packageName\" \"$arch\" ${presetFlags[preset]} ${dynarecFlags[dynarec]} ${osFlags[os]} -D \"BUILD_TYPE=$BUILD_TYPE\" -D \"EMU_BUILD=build ${env.BUILD_NUMBER}\" -D \"EMU_BUILD_NUM=${env.BUILD_NUMBER}\"")
ret = runBuild("-b \"$packageName\" \"$arch\" ${presetFlags[preset]} ${dynarecFlags[dynarec]} ${osFlags[os]} $buildFlags")
}
if (ret == 0) {
@@ -279,7 +291,7 @@ pipeline {
always {
script {
/* Send out build notifications. */
if (!env.JOB_BASE_NAME.contains('TestBuildPleaseIgnore')) {
if (commitBrowser[buildBranch]) {
try {
/* Notify Discord. */
def result = currentBuild.currentResult.toLowerCase()
@@ -290,7 +302,7 @@ pipeline {
description: "**Status:** ${result}\n\u2060", /* word joiner character forces a blank line */
enableArtifactsList: false,
showChangeset: true,
scmWebUrl: commitBrowser
scmWebUrl: commitBrowser[buildBranch]
/* Notify IRC, which needs a node for whatever reason. */
node('citadel') {

View File

@@ -295,7 +295,7 @@ then
fi
# Install the latest versions for any missing packages (if the specified version couldn't be installed).
pkgs="make git"
pkgs="git"
while IFS=" " read pkg version
do
prefixed_pkg="$MINGW_PACKAGE_PREFIX-$pkg"
@@ -328,7 +328,7 @@ else
esac
# Establish general dependencies.
pkgs="cmake pkg-config git imagemagick wget p7zip-full wayland-protocols tar gzip file"
pkgs="cmake ninja-build pkg-config git wget p7zip-full wayland-protocols tar gzip file"
if [ "$(dpkg --print-architecture)" = "$arch_deb" ]
then
pkgs="$pkgs build-essential"
@@ -405,7 +405,7 @@ fi
echo [-] Cleaning workspace
if [ -d "build" ]
then
MAKEFLAGS=-j$(nproc) cmake --build build --target clean 2> /dev/null
cmake --build build -j$(nproc) --target clean 2> /dev/null
rm -rf build
fi
find . \( -name Makefile -o -name CMakeCache.txt -o -name CMakeFiles \) -exec rm -rf "{}" \; 2> /dev/null
@@ -438,7 +438,7 @@ year=$(date +%Y)
# Run CMake.
echo [-] Running CMake with flags [$cmake_flags $cmake_flags_extra]
eval cmake -G \"Unix Makefiles\" -B build $cmake_flags $cmake_flags_extra .
eval cmake -G Ninja $cmake_flags $cmake_flags_extra -S . -B build
status=$?
if [ $status -ne 0 ]
then
@@ -447,13 +447,12 @@ then
fi
# Run actual build.
make_flags=-j$(nproc)
echo [-] Running build with make flags [$make_flags]
MAKEFLAGS=$make_flags cmake --build build
echo [-] Running build
cmake --build build -j$(nproc)
status=$?
if [ $status -ne 0 ]
then
echo [!] Make failed with status [$status]
echo [!] Build failed with status [$status]
exit 4
fi
@@ -536,15 +535,13 @@ else
# workaround until a newer version of openal-soft trickles down to Debian repos.
if [ -d "openal-soft-1.21.1" ]
then
rm -rf openal-soft-1.21.1/build/*
rm -rf openal-soft-1.21.1/build
else
wget -qO - https://github.com/kcat/openal-soft/archive/refs/tags/1.21.1.tar.gz | tar zxf -
fi
cd openal-soft-1.21.1/build
[ -e Makefile ] && make clean
cmake -G "Unix Makefiles" -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" ..
make -j$(nproc) install || exit 99
cd "$cwd_root"
cmake -G Ninja -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" -S openal-soft-1.21.1 -B openal-soft-1.21.1/build || exit 99
cmake --build openal-soft-1.21.1/build -j$(nproc) || exit 99
cmake --install openal-soft-1.21.1/build || exit 99
# Build SDL2 without sound systems.
sdl_ss=OFF
@@ -557,11 +554,9 @@ else
else
wget -qO - https://github.com/FNA-XNA/FAudio/archive/refs/tags/22.03.tar.gz | tar zxf -
fi
mkdir FAudio-22.03/build
cd FAudio-22.03/build
cmake -G "Unix Makefiles" -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" ..
make -j$(nproc) install || exit 99
cd "$cwd_root"
cmake -G Ninja -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" -S FAudio-22.03 -B FAudio-22.03/build || exit 99
cmake --build FAudio-22.03/build -j$(nproc) || exit 99
cmake --install FAudio-22.03/build || exit 99
# Build SDL2 with sound systems.
sdl_ss=ON
@@ -570,35 +565,33 @@ else
# Build rtmidi without JACK support to remove the dependency on libjack.
if [ -d "rtmidi-4.0.0" ]
then
rm -rf rtmidi-4.0.0/CMakeCache.txt rtmidi-4.0.0/CMakeFiles
rm -rf rtmidi-4.0.0/build
else
wget -qO - http://www.music.mcgill.ca/~gary/rtmidi/release/rtmidi-4.0.0.tar.gz | tar zxf -
fi
cwd_root=$(pwd)
cd rtmidi-4.0.0
[ -e Makefile ] && make clean
cmake -G "Unix Makefiles" -D RTMIDI_API_JACK=OFF -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" .
make -j$(nproc) install || exit 99
cd "$cwd_root"
cmake -G Ninja -D RTMIDI_API_JACK=OFF -D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" -S rtmidi-4.0.0 -B rtmidi-4.0.0/build || exit 99
cmake --build rtmidi-4.0.0/build -j$(nproc) || exit 99
cmake --install rtmidi-4.0.0/build || exit 99
# Build SDL2 for joystick support with most components disabled to remove the dependencies on PulseAudio and libdrm.
# Build SDL2 for joystick and FAudio support, with most components
# disabled to remove the dependencies on PulseAudio and libdrm.
if [ ! -d "SDL2-2.0.20" ]
then
wget -qO - https://www.libsdl.org/release/SDL2-2.0.20.tar.gz | tar zxf -
fi
rm -rf sdlbuild
mkdir sdlbuild
cd sdlbuild
cmake -G "Unix Makefiles" -D SDL_DISKAUDIO=OFF -D SDL_DIRECTFB_SHARED=OFF -D SDL_OPENGL=OFF -D SDL_OPENGLES=OFF -D SDL_OSS=OFF -D SDL_ALSA=$sdl_ss \
-D SDL_ALSA_SHARED=$sdl_ss -D SDL_JACK=$sdl_ss -D SDL_JACK_SHARED=$sdl_ss -D SDL_ESD=OFF -D SDL_ESD_SHARED=OFF -D SDL_PIPEWIRE=$sdl_ss -D SDL_PIPEWIRE_SHARED=$sdl_ss \
-D SDL_PULSEAUDIO=$sdl_ss -D SDL_PULSEAUDIO_SHARED=$sdl_ss -D SDL_ARTS=OFF -D SDL_ARTS_SHARED=OFF -D SDL_NAS=$sdl_ss -D SDL_NAS_SHARED=$sdl_ss -D SDL_SNDIO=$sdl_ss \
-D SDL_SNDIO_SHARED=$sdl_ss -D SDL_FUSIONSOUND=OFF -D SDL_FUSIONSOUND_SHARED=OFF -D SDL_LIBSAMPLERATE=$sdl_ss -D SDL_LIBSAMPLERATE_SHARED=$sdl_ss -D SDL_X11=OFF \
-D SDL_X11_SHARED=OFF -D SDL_WAYLAND=OFF -D SDL_WAYLAND_SHARED=OFF -D SDL_WAYLAND_LIBDECOR=OFF -D SDL_WAYLAND_LIBDECOR_SHARED=OFF \
-D SDL_WAYLAND_QT_TOUCH=OFF -D SDL_RPI=OFF -D SDL_VIVANTE=OFF -D SDL_VULKAN=OFF -D SDL_KMSDRM=OFF -D SDL_KMSDRM_SHARED=OFF -D SDL_OFFSCREEN=OFF \
-D SDL_HIDAPI_JOYSTICK=ON -D SDL_VIRTUAL_JOYSTICK=ON -D SDL_SHARED=ON -D SDL_STATIC=OFF -S "$cwd_root/SDL2-2.0.20" \
-D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr"
make -j$(nproc) install || exit 99
cd "$cwd_root"
cmake -G Ninja -D SDL_DISKAUDIO=OFF -D SDL_DIRECTFB_SHARED=OFF -D SDL_OPENGL=OFF -D SDL_OPENGLES=OFF -D SDL_OSS=OFF -D SDL_ALSA=$sdl_ss \
-D SDL_ALSA_SHARED=$sdl_ss -D SDL_JACK=$sdl_ss -D SDL_JACK_SHARED=$sdl_ss -D SDL_ESD=OFF -D SDL_ESD_SHARED=OFF -D SDL_PIPEWIRE=$sdl_ss \
-D SDL_PIPEWIRE_SHARED=$sdl_ss -D SDL_PULSEAUDIO=$sdl_ss -D SDL_PULSEAUDIO_SHARED=$sdl_ss -D SDL_ARTS=OFF -D SDL_ARTS_SHARED=OFF \
-D SDL_NAS=$sdl_ss -D SDL_NAS_SHARED=$sdl_ss -D SDL_SNDIO=$sdl_ss -D SDL_SNDIO_SHARED=$sdl_ss -D SDL_FUSIONSOUND=OFF \
-D SDL_FUSIONSOUND_SHARED=OFF -D SDL_LIBSAMPLERATE=$sdl_ss -D SDL_LIBSAMPLERATE_SHARED=$sdl_ss -D SDL_X11=OFF -D SDL_X11_SHARED=OFF \
-D SDL_WAYLAND=OFF -D SDL_WAYLAND_SHARED=OFF -D SDL_WAYLAND_LIBDECOR=OFF -D SDL_WAYLAND_LIBDECOR_SHARED=OFF -D SDL_WAYLAND_QT_TOUCH=OFF \
-D SDL_RPI=OFF -D SDL_VIVANTE=OFF -D SDL_VULKAN=OFF -D SDL_KMSDRM=OFF -D SDL_KMSDRM_SHARED=OFF -D SDL_OFFSCREEN=OFF \
-D SDL_HIDAPI_JOYSTICK=ON -D SDL_VIRTUAL_JOYSTICK=ON -D SDL_SHARED=ON -D SDL_STATIC=OFF -S SDL2-2.0.20 -B sdlbuild \
-D "CMAKE_TOOLCHAIN_FILE=$cwd_root/toolchain.cmake" -D "CMAKE_INSTALL_PREFIX=$cwd_root/archive_tmp/usr" || exit 99
cmake --build sdlbuild -j$(nproc) || exit 99
cmake --install sdlbuild || exit 99
# Archive Discord Game SDK library.
7z e -y -o"archive_tmp/usr/lib" discord_game_sdk.zip "lib/$arch_discord/discord_game_sdk.so"
@@ -615,11 +608,11 @@ else
echo $pkg $version >> archive_tmp/README
done
# Archive icon, while also shrinking it to 512x512 if necessary.
convert src/win/assets/$project_lower.png -resize '512x512>' icon.png
icon_base="$(identify -format 'archive_tmp/usr/share/icons/%wx%h' icon.png)"
# Archive icons.
icon_base=archive_tmp/usr/share/icons
mkdir -p "$icon_base"
mv icon.png "$icon_base/$project_lower.png"
cp -rp src/unix/assets/[0-9]*x[0-9]* "$icon_base/"
icon_name=$(ls "$icon_base/"[0-9]*x[0-9]*/* | head -1 | grep -oP '/\K([^/]+)(?=\.[^\.]+$)')
# Archive executable, while also stripping it if requested.
mkdir -p archive_tmp/usr/local/bin
@@ -676,8 +669,8 @@ else
rm -rf "$project-"*".AppImage"
# Run appimage-builder in extract-and-run mode for Docker compatibility.
project="$project" project_lower="$project_lower" project_version="$project_version" arch_deb="$arch_deb" arch_appimage="$arch_appimage" \
APPIMAGE_EXTRACT_AND_RUN=1 ./appimage-builder.AppImage --recipe .ci/AppImageBuilder.yml
project="$project" project_lower="$project_lower" project_version="$project_version" project_icon="$icon_name" arch_deb="$arch_deb" \
arch_appimage="$arch_appimage" APPIMAGE_EXTRACT_AND_RUN=1 ./appimage-builder.AppImage --recipe .ci/AppImageBuilder.yml
status=$?
# Rename AppImage to the final name if the build succeeded.

View File

@@ -13,7 +13,7 @@ gcc-objc 11.2.0-4
gcc 11.2.0-4
libgccjit 11.2.0-4
tools-git 9.0.0.6357.eac8c38c1-1
make 4.3-1
ninja 1.10.2-3
pkgconf 1.8.0-2
openal 1.21.1-3
libpng 1.6.37-6

View File

@@ -252,7 +252,7 @@ static MVHDGeom create_drive_vhd_dynamic(const QString& fileName, uint16_t cyl,
static MVHDGeom create_drive_vhd_diff(const QString& fileName, const QString& parentFileName, int blocksize) {
int vhd_error = 0;
QByteArray filenameBytes = fileName.toUtf8();
QByteArray parentFilenameBytes = fileName.toUtf8();
QByteArray parentFilenameBytes = parentFileName.toUtf8();
MVHDCreationOptions options;
options.block_size_in_sectors = blocksize;
options.path = filenameBytes.data();

View File

@@ -221,9 +221,9 @@ MainWindow::MainWindow(QWidget *parent) :
connect(this, &MainWindow::resizeContents, this, [this](int w, int h) {
if (!QApplication::platformName().contains("eglfs") && vid_resize == 0) {
w = qRound(w / (!dpi_scale ? util::screenOfWidget(this)->devicePixelRatio() : 1.));
w = (w / (!dpi_scale ? util::screenOfWidget(this)->devicePixelRatio() : 1.));
int modifiedHeight = qRound(h / (!dpi_scale ? util::screenOfWidget(this)->devicePixelRatio() : 1.))
int modifiedHeight = (h / (!dpi_scale ? util::screenOfWidget(this)->devicePixelRatio() : 1.))
+ menuBar()->height()
+ (statusBar()->height() * !hide_status_bar)
+ (ui->toolBar->height() * !hide_tool_bar);
@@ -1313,7 +1313,14 @@ void MainWindow::getTitle(wchar_t *title)
bool MainWindow::eventFilter(QObject* receiver, QEvent* event)
{
if (this->keyboardGrabber() == this) {
if (!dopause && (mouse_capture || !kbd_req_capture)) {
if (event->type() == QEvent::Shortcut) {
auto shortcutEvent = (QShortcutEvent*)event;
if (shortcutEvent->key() == ui->actionExit->shortcut()) {
event->accept();
return true;
}
}
if (event->type() == QEvent::KeyPress) {
event->accept();
this->keyPressEvent((QKeyEvent *) event);

View File

@@ -5,6 +5,9 @@
# include <stdlib.h>
# include <string.h>
# include <wchar.h>
# ifdef __unix__
# include <unistd.h>
# endif
# include <86box/86box.h>
# include <86box/config.h>
@@ -248,7 +251,12 @@ fluidsynth_init(const device_t *info)
data->synth = f_new_fluid_synth(data->settings);
char *sound_font = (char *) device_get_config_string("sound_font");
const char *sound_font = (char *) device_get_config_string("sound_font");
# ifdef __unix__
if (!sound_font || sound_font[0] == 0)
sound_font = (access("/usr/share/sounds/sf2/FluidR3_GM.sf2", F_OK) == 0 ? "/usr/share/sounds/sf2/FluidR3_GM.sf2" :
(access("/usr/share/soundfonts/default.sf2", F_OK) == 0 ? "/usr/share/soundfonts/default.sf2" : ""));
# endif
data->sound_font = f_fluid_synth_sfload(data->synth, sound_font, 1);
if (device_get_config_int("chorus")) {

View File

@@ -560,12 +560,12 @@ cmi8x38_start_playback(cmi8x38_t *dev)
i = !(val & 0x01);
if (!dev->dma[0].playback_enabled && i)
timer_advance_u64(&dev->dma[0].poll_timer, dev->dma[0].timer_latch);
timer_set_delay_u64(&dev->dma[0].poll_timer, dev->dma[0].timer_latch);
dev->dma[0].playback_enabled = i;
i = !(val & 0x02);
if (!dev->dma[1].playback_enabled && i)
timer_advance_u64(&dev->dma[1].poll_timer, dev->dma[1].timer_latch);
timer_set_delay_u64(&dev->dma[1].poll_timer, dev->dma[1].timer_latch);
dev->dma[1].playback_enabled = i;
}
@@ -722,10 +722,9 @@ cmi8x38_write(uint16_t addr, uint8_t val, void *priv)
break;
case 0x09:
#if 0 /* actual CMI8338 behavior unconfirmed; this register is required for the Windows XP driver which outputs 96K */
if (dev->type == CMEDIA_CMI8338)
return;
#endif
if (dev->type == CMEDIA_CMI8338)
return;
/* Update sample rate. */
dev->io_regs[addr] = val;
cmi8x38_speed_changed(dev);
@@ -1043,22 +1042,28 @@ cmi8x38_dma_process(void *priv)
/* Check if the fragment size was reached. */
if (--dma->frame_count_fragment <= 0) {
cmi8x38_log("CMI8x38: DMA %d fragment size reached at %04X frames left", dma->id, dma->frame_count_dma - 1);
/* Reset fragment counter. */
dma->frame_count_fragment = *((uint16_t *) &dev->io_regs[dma->reg | 0x6]) + 1;
#ifdef ENABLE_CMI8X38_LOG
if (dma->frame_count_fragment > 1) /* avoid log spam if fragment counting is unused, like on the newer WDM drivers (cmudax3) */
cmi8x38_log("CMI8x38: DMA %d fragment size reached at %04X frames left", dma->id, dma->frame_count_dma - 1);
#endif
/* Fire interrupt if requested. */
if (dev->io_regs[0x0e] & dma_bit) {
cmi8x38_log(", firing interrupt\n");
#ifdef ENABLE_CMI8X38_LOG
if (dma->frame_count_fragment > 1)
cmi8x38_log(", firing interrupt\n");
#endif
/* Set channel interrupt flag. */
dev->io_regs[0x10] |= dma_bit;
/* Fire interrupt. */
cmi8x38_update_irqs(dev);
} else {
cmi8x38_log("\n");
#ifdef ENABLE_CMI8X38_LOG
if (dma->frame_count_fragment > 1)
cmi8x38_log("\n");
#endif
}
}
@@ -1129,8 +1134,8 @@ cmi8x38_poll(void *priv)
}
break;
case 0x03: /* Stereo, 16-bit PCM */
switch (dma->channels) { /* multi-channel requires this data format */
case 0x03: /* Stereo, 16-bit PCM, with multi-channel capability */
switch (dma->channels) {
case 2:
if ((dma->fifo_end - dma->fifo_pos) >= 4) {
*out_l = *((uint16_t *) &dma->fifo[dma->fifo_pos & (sizeof(dma->fifo) - 1)]);

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

123
src/unix/assets/86Box.spec Normal file
View File

@@ -0,0 +1,123 @@
# Fedora RPM spec file for 86Box including roms
#
# To create RPM files from this spec file, run the following commands:
# sudo dnf install rpm-build
# mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
#
# copy this 86Box.spec file to ~/rpmbuild/SPECS and run the following commands:
# cd ~/rpmbuild
# sudo dnf builddep SPECS/86Box.spec
# rpmbuild --undefine=_disable_source_fetch -ba SPECS/86Box.spec
#
# After a successful build, you can install the RPMs as follows:
# sudo dnf install RPMS/$(uname -m)/86Box-3* RPMS/noarch/86Box-roms*
%global romver 20220319
Name: 86Box
Version: 3.3
Release: 1%{?dist}
Summary: Classic PC emulator
License: GPLv2+
URL: https://86box.net
Source0: https://github.com/86Box/86Box/archive/refs/tags/v%%{version}.tar.gz
Source1: https://github.com/86Box/roms/archive/refs/tags/%{romver}.tar.gz
BuildRequires: cmake
BuildRequires: desktop-file-utils
BuildRequires: extra-cmake-modules
BuildRequires: gcc-c++
BuildRequires: libFAudio-devel
BuildRequires: libappstream-glib
BuildRequires: libevdev-devel
BuildRequires: libXi-devel
BuildRequires: ninja-build
BuildRequires: qt5-linguist
BuildRequires: qt5-qtconfiguration-devel
BuildRequires: qt5-qtbase-private-devel
BuildRequires: qt5-qtbase-static
BuildRequires: rtmidi-devel
BuildRequires: wayland-devel
BuildRequires: SDL2-devel
Requires: hicolor-icon-theme
Requires: fluid-soundfont-gm
Requires: 86Box-roms
%description
86Box is a hypervisor and IBM PC system emulator that specializes in
running old operating systems and software designed for IBM
PC systems and compatibles from 1981 through fairly recent
system designs based on the PCI bus.
It supports various models of PCs, graphics and sound cards, and CPUs.
%package roms
Summary: ROMs for use with 86Box
Version: %{romver}
License: Proprietary
BuildArch: noarch
%description roms
Collection of ROMs for use with 86Box.
%prep
%autosetup -p1 -a1
%build
%ifarch i386 x86_64
%cmake -DRELEASE=on
%else
%ifarch arm aarch64
%cmake -DRELEASE=on -DNEW_DYNAREC=on
%else
%cmake -DRELEASE=on -DDYNAREC=off
%endif
%endif
%cmake_build
%install
# install base package
%cmake_install
# install icons
for i in 48 64 72 96 128 192 256 512; do
mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${i}x${i}/apps
cp src/unix/assets/${i}x${i}/net.86box.86Box.png $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${i}x${i}/apps/net.86box.86Box.png
done
# install desktop file
desktop-file-install --dir=%{buildroot}%{_datadir}/applications src/unix/assets/net.86box.86Box.desktop
# install metadata
mkdir -p %{buildroot}%{_metainfodir}
cp src/unix/assets/net.86box.86Box.metainfo.xml %{buildroot}%{_metainfodir}
appstream-util validate-relax --nonet %{buildroot}%{_metainfodir}/net.86box.86Box.metainfo.xml
# install roms
pushd roms-%{romver}
mkdir -p %{buildroot}%{_datadir}/%{name}/roms
cp -a * %{buildroot}%{_datadir}/%{name}/roms/
# hack to create symlink in /usr/bin
cd %{buildroot}%{_bindir}
ln -s ../share/%{name}/roms roms
popd
# files part of the main package
%files
%license COPYING
%{_bindir}/86Box
%{_datadir}/applications/net.86box.86Box.desktop
%{_metainfodir}/net.86box.86Box.metainfo.xml
%{_datadir}/icons/hicolor/*/apps/net.86box.86Box.png
# files part of the rom package
%files roms
%license roms-%{romver}/LICENSE
%{_datadir}/%{name}/roms
%{_bindir}/roms
%changelog
* Sat Mar 19 2022 Robert de Rooy <robert.de.rooy[AT]gmail.com> 3.3-1
- Initial RPM release

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@@ -0,0 +1,9 @@
[Desktop Entry]
Name=86Box
GenericName=Classic PC emulator
Comment=An emulator for classic IBM PC clones
Exec=86Box
Icon=net.86box.86Box
Terminal=false
Type=Application
Categories=System;Emulator

View File

@@ -0,0 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop">
<id>net.86box.86Box</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>GPL-2.0-or-later</project_license>
<name>86Box</name>
<summary>An emulator for classic IBM PC clones</summary>
<categories>
<category>Emulation</category>
</categories>
<launchable type="desktop-id">net.86box.86Box.desktop</launchable>
<releases>
<release version="3.3" date="2022-03-19"/>
</releases>
<content_rating type="oars-1.1" />
<description>
<p>
86Box is a hypervisor and IBM PC system emulator that specializes
in running old operating systems and software designed for IBM
PC systems and compatibles from 1981 through fairly recent
system designs based on the PCI bus.
It supports various models of PCs, graphics and sound
cards, and CPUs.
</p>
<p>
To use 86Box you will need to dump BIOS ROMs for each machine you
want to emulate.
</p>
</description>
<url type="homepage">https://86box.net</url>
</component>

View File

@@ -1,6 +1,6 @@
{
"name": "86box",
"version-string": "3.1",
"version-string": "3.3",
"homepage": "https://86box.net/",
"documentation": "http://86box.readthedocs.io/",
"license": "GPL-2.0-or-later",