Lakka-LibreELEC/projects/RPi/devices/RPi4-PiBoyDmg/packages/xpi_gamecon/package.mk
David Lawson 49f9ce8b0a
RPi4-PiBoyDmg: switch back to compiling xpi_gamecon as a module (#1832)
* RPi4-PiBoyDmg: switch back to compiling xpi_gamecon as a module

This fixes PiBoy DMG not booting with Lakka v5

* RPi4-PiBoyDmg: audio device is now PCM
2023-09-06 00:04:26 +03:00

28 lines
835 B
Makefile

PKG_NAME="xpi_gamecon"
PKG_LICENSE="GPL"
PKG_DEPENDS_TARGET="toolchain linux"
PKG_NEED_UNPACK="${LINUX_DEPENDS}"
PKG_LONGDESC="xpi_gamecon driver for PiBoyDMG"
PKG_IS_KERNEL_PKG="yes"
PKG_TOOLCHAIN="manual"
PKG_IS_KERNEL_PKG="yes"
make_target() {
kernel_make -C $(kernel_path) M=${PKG_BUILD} modules
}
makeinstall_target() {
mkdir -p ${INSTALL}/$(get_full_module_dir)/${PKG_NAME}
cp -v ${PKG_BUILD}/*.ko ${INSTALL}/$(get_full_module_dir)/${PKG_NAME}/
mkdir -p ${INSTALL}/usr/lib/modules-load.d
echo xpi_gamecon > ${INSTALL}/usr/lib/modules-load.d/xpi_gamecon.conf
mkdir -p ${INSTALL}/usr/bin
cp -v ${PKG_DIR}/scripts/piboy-dmg-control.sh ${INSTALL}/usr/bin/
}
post_install() {
enable_service xpi_gamecon_reboot.service
enable_service xpi_gamecon_shutdown.service
enable_service piboy-dmg-control.service
}