2022-04-13 12:49:03 +00:00
|
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
# Copyright (C) 2021-present Shanti Gilbert (https://github.com/shantigilbert)
|
2022-04-13 12:57:00 +00:00
|
|
|
# Copyright (C) 2022-present BrooksyTech (https://github.com/brooksytech)
|
2022-05-27 22:33:28 +00:00
|
|
|
# Copyright (C) 2022-present Fewtarius
|
2022-04-13 12:49:03 +00:00
|
|
|
|
2023-03-17 16:40:00 +00:00
|
|
|
PKG_NAME="flycast-sa"
|
2023-04-06 12:13:13 +00:00
|
|
|
PKG_VERSION="187674ddac84038922bb29a0f89e99ecf3135e52"
|
2022-04-13 12:49:03 +00:00
|
|
|
PKG_LICENSE="GPLv2"
|
|
|
|
PKG_SITE="https://github.com/flyinghead/flycast"
|
2022-04-29 08:44:15 +00:00
|
|
|
PKG_URL="${PKG_SITE}.git"
|
2023-03-27 00:01:25 +00:00
|
|
|
PKG_DEPENDS_TARGET="toolchain alsa SDL2 libzip zip curl miniupnpc lua54 libao"
|
2022-04-13 12:49:03 +00:00
|
|
|
PKG_LONGDESC="Flycast is a multiplatform Sega Dreamcast, Naomi and Atomiswave emulator"
|
|
|
|
PKG_TOOLCHAIN="cmake"
|
2022-05-27 22:33:28 +00:00
|
|
|
PKG_PATCH_DIRS+="${DEVICE}"
|
2022-04-13 12:49:03 +00:00
|
|
|
|
2022-07-11 22:23:00 +00:00
|
|
|
if [ ! "${OPENGL}" = "no" ]; then
|
|
|
|
PKG_DEPENDS_TARGET+=" ${OPENGL} glu libglvnd"
|
2022-10-03 23:10:53 +00:00
|
|
|
PKG_CMAKE_OPTS_TARGET+=" USE_OPENGL=ON"
|
|
|
|
else
|
|
|
|
PKG_CMAKE_OPTS_TARGET+=" USE_OPENGL=OFF"
|
2022-07-11 22:23:00 +00:00
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "${OPENGLES_SUPPORT}" = yes ]; then
|
|
|
|
PKG_DEPENDS_TARGET+=" ${OPENGLES}"
|
|
|
|
PKG_CMAKE_OPTS_TARGET+=" -DUSE_GLES=ON"
|
2022-10-03 23:10:53 +00:00
|
|
|
else
|
|
|
|
PKG_CMAKE_OPTS_TARGET+=" -DUSE_GLES=OFF"
|
2022-07-11 22:23:00 +00:00
|
|
|
fi
|
|
|
|
|
2022-08-30 00:32:44 +00:00
|
|
|
if [ "${VULKAN_SUPPORT}" = "yes" ]
|
2022-07-11 22:23:00 +00:00
|
|
|
then
|
|
|
|
PKG_DEPENDS_TARGET+=" vulkan-loader vulkan-headers"
|
|
|
|
PKG_CMAKE_OPTS_TARGET+=" -DUSE_VULKAN=ON"
|
2022-10-03 23:10:53 +00:00
|
|
|
else
|
|
|
|
PKG_CMAKE_OPTS_TARGET+=" -DUSE_VULKAN=OFF"
|
2022-07-11 22:23:00 +00:00
|
|
|
fi
|
|
|
|
|
2022-04-13 12:49:03 +00:00
|
|
|
pre_configure_target() {
|
|
|
|
export CXXFLAGS="${CXXFLAGS} -Wno-error=array-bounds"
|
2022-07-11 22:23:00 +00:00
|
|
|
PKG_CMAKE_OPTS_TARGET+=" -DUSE_OPENMP=ON"
|
2022-04-13 12:49:03 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
makeinstall_target() {
|
2022-04-29 08:44:15 +00:00
|
|
|
mkdir -p ${INSTALL}/usr/bin
|
2023-03-30 23:45:49 +00:00
|
|
|
mkdir -p ${INSTALL}/usr/config/flycast
|
2022-04-29 08:44:15 +00:00
|
|
|
cp ${PKG_BUILD}/.${TARGET_NAME}/flycast ${INSTALL}/usr/bin/flycast
|
|
|
|
cp ${PKG_DIR}/scripts/* ${INSTALL}/usr/bin
|
2023-03-30 23:45:49 +00:00
|
|
|
cp ${PKG_DIR}/config/${DEVICE}/* ${INSTALL}/usr/config/flycast
|
2022-04-13 12:49:03 +00:00
|
|
|
|
2023-03-30 23:45:49 +00:00
|
|
|
chmod +x ${INSTALL}/usr/bin/start_flycastsa.sh
|
2022-04-13 12:49:03 +00:00
|
|
|
}
|