From 9143a3558bb7dadc9cf9b98ab707df560131b263 Mon Sep 17 00:00:00 2001 From: Chris Wedgwood Date: Mon, 11 Dec 2023 17:26:01 -0800 Subject: [PATCH] RFC/WIP A8 Libretro integration --- .github/workflows/package.yml | 8 ++++++++ CMakeLists.txt | 6 ++++++ README.md | 11 +++++++++-- 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 46bfe02fd..1525cdc3f 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -44,6 +44,14 @@ jobs: make --silent -j 4 mkdir -p ${{ env.LIBRETRO_CORES_DIR }} mv stella2014_libretro.so ${{ env.LIBRETRO_CORES_DIR }} + - name: 'Build "atari800" core' + if: steps.cache.outputs.cache-hit != 'true' + run: | + git clone https://github.com/libretro/libretro-atari800 + cd libretro-atari800/ + make --silent -j 4 + mkdir -p ${{ env.LIBRETRO_CORES_DIR }} + mv atari800_libretro.so ${{ env.LIBRETRO_CORES_DIR }} - name: Build Mesen-X core if: steps.cache.outputs.cache-hit != 'true' run: | diff --git a/CMakeLists.txt b/CMakeLists.txt index 7bfb3572a..dd8bd11eb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -52,6 +52,12 @@ if(NOT CMAKE_CROSSCOMPILING) PATHS ENV EMUTEST_DIR) message(STATUS "Emutest test runner: ${EMUTEST_COMMAND}") + find_library(LIBRETRO_ATARI800_CORE + NAMES + atari800_libretro.so atari800_libretro.dylib atari800_libretro.dll + PATHS /lib64/libretro ENV LIBRETRO_CORES_DIR) + message(STATUS "Libretro Atari800 core: ${LIBRETRO_ATARI800_CORE}") + find_library(LIBRETRO_STELLA_CORE NAMES stella2014_libretro.so stella2014_libretro.dylib stella2014_libretro.dll diff --git a/README.md b/README.md index 9dfe78987..fbd6d2435 100644 --- a/README.md +++ b/README.md @@ -306,14 +306,21 @@ Copy `test/mesen_settings.xml` to this folder. Install emutest (requires Go 1.21): ```console -$ go install https://github.com/kivutar/emutest +$ go install github.com/kivutar/emutest@latest ``` -Make sure `$GOBIN` (usually `~/go/bin`) is included in your PATH environment variable so that CMake can find the binary, or set the `EMUTEST_DIR` environment variable to point to this directory before running `cmake -G` for the first time. +Make sure `$GOBIN` (usually `~/go/bin`) is included in your `PATH` +environment variable so that CMake can find the binary, or set the +`EMUTEST_DIR` environment variable to point to this directory before +running `cmake -G` for the first time. + +You can verify emutest with `emutest -h < /dev/null` on the +command-line. Build Libretro cores for desired target(s): * Atari 2600 - https://github.com/libretro/stella2014-libretro +* Atari 800 - https://github.com/libretro/libretro-atari800 * NES - https://github.com/NovaSquirrel/Mesen-X Copy the output Libretro core library files (they have extensions .so | .dylib | .dll) to a shared directory, maybe `$HOME/libretro`.