207f8d8f69
* box64, a5200-lr, atari800-lr, beetle-pce-fast-lr, beetle-pce-lr, beetle-psx-lr, bsnes-lr, package.mk, desmume-lr, dosbox-pure-lr, fbneo-lr, flycast-lr, genesis-plus-gx-lr, genesis-plus-gx-wide-lr, handy-lr, package.mk, mame-lr, mame2003-plus-lr, mupen64plus-nx-lr, opera-lr, pcsx_rearmed-lr, picodrive-lr, play-lr, ppsspp-lr, stella-lr, swanstation-lr, tic80-lr, cemu-sa, duckstation-sa, hatarisa, package.mk, ppsspp-sa, primehack, retroarch, scummvmsa, yuzu-sa, glsl-shaders, slang-shaders, and retroarch-joypads. * Fix pipewire package oops.
71 lines
1.8 KiB
Makefile
71 lines
1.8 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
# Copyright (C) 2019 Trond Haugland (trondah@gmail.com)
|
|
|
|
PKG_NAME="mame-lr"
|
|
PKG_VERSION="4cd28066d8f9e129b1915a72163a10dac84a8731"
|
|
PKG_ARCH="any"
|
|
PKG_LICENSE="GPLv2"
|
|
PKG_SITE="https://github.com/libretro/mame"
|
|
PKG_URL="https://github.com/libretro/mame/archive/${PKG_VERSION}.tar.gz"
|
|
PKG_DEPENDS_TARGET="toolchain zlib flac sqlite expat"
|
|
PKG_SECTION="libretro"
|
|
PKG_SHORTDESC="MAME - Multiple Arcade Machine Emulator"
|
|
PKG_TOOLCHAIN="make"
|
|
PKG_BUILD_FLAGS="-lto +pic"
|
|
|
|
case ${TARGET_ARCH} in
|
|
arm|aarch64)
|
|
MAME_PLATFORM="PLATFORM=arm64"
|
|
CROSS_BUILD="1"
|
|
PTR64=0
|
|
;;
|
|
*)
|
|
CROSS_BUILD="0"
|
|
PTR64=1
|
|
;;
|
|
esac
|
|
|
|
PKG_MAKE_OPTS_TARGET="REGENIE=1 \
|
|
VERBOSE=1 \
|
|
NOWERROR=1 \
|
|
OPENMP=1 \
|
|
CROSS_BUILD=${CROSS_BUILD} \
|
|
TOOLS=0 \
|
|
RETRO=1 \
|
|
PTR64=${PTR64} \
|
|
NOASM=0 \
|
|
PYTHON_EXECUTABLE=python3 \
|
|
CONFIG=libretro \
|
|
LIBRETRO_OS=unix \
|
|
LIBRETRO_CPU= \
|
|
${MAME_PLATFORM} \
|
|
ARCH= \
|
|
TARGET=mame \
|
|
SUBTARGET=mame \
|
|
OSD=retro \
|
|
USE_SYSTEM_LIB_EXPAT=1 \
|
|
USE_SYSTEM_LIB_ZLIB=1 \
|
|
USE_SYSTEM_LIB_FLAC=1 \
|
|
USE_SYSTEM_LIB_SQLITE3=1"
|
|
|
|
pre_configure_target() {
|
|
sed -i "s/-static-libstdc++//g" scripts/genie.lua
|
|
}
|
|
|
|
make_target() {
|
|
unset ARCH
|
|
unset DISTRO
|
|
unset PROJECT
|
|
if [ "${PLATFORM}" = "arm64" ]
|
|
then
|
|
export ARCHOPTS="-D__aarch64__ -DASMJIT_BUILD_X86"
|
|
fi
|
|
make ${PKG_MAKE_OPTS_TARGET} OVERRIDE_CC=${CC} OVERRIDE_CXX=${CXX} OVERRIDE_LD=$LD AR=${AR} ${MAKEFLAGS}
|
|
}
|
|
|
|
makeinstall_target() {
|
|
mkdir -p ${INSTALL}/usr/lib/libretro
|
|
cp *.so ${INSTALL}/usr/lib/libretro/mame_libretro.so
|
|
mkdir -p ${INSTALL}/usr/config/retroarch/savefiles/mame/hi
|
|
cp plugins/hiscore/hiscore.dat ${INSTALL}/usr/config/retroarch/savefiles/mame/hi
|
|
}
|