From 01deedebb3c1748fbd31fd16a97824c9b23dad2c Mon Sep 17 00:00:00 2001 From: Yuri Konotopov Date: Sun, 18 Aug 2019 11:28:56 +0400 Subject: libretro-core.eclass: replace hyphens in default $LIBRETRO_CORE_NAME Libretro cores are named with underscores instead of hyphens. E.g. genesis_plus_gx or vba_next. Signed-off-by: Yuri Konotopov Closes: https://github.com/gentoo/gentoo/pull/12738 Signed-off-by: Craig Andrews --- eclass/libretro-core.eclass | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'eclass/libretro-core.eclass') diff --git a/eclass/libretro-core.eclass b/eclass/libretro-core.eclass index 6825ef24dda..0fe522911f0 100644 --- a/eclass/libretro-core.eclass +++ b/eclass/libretro-core.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: libretro-core.eclass @@ -44,9 +44,13 @@ IUSE="debug" # @DESCRIPTION: # Name of this Libretro core. The libretro-core_src_install() phase function # will install the shared library "${S}/${LIBRETRO_CORE_NAME}_libretro.so" as a -# Libretro core. Defaults to the name of the current package excluding the -# "libretro-" prefix (e.g., "mgba" for the package "libretro-mgba"). -: ${LIBRETRO_CORE_NAME:=${PN#libretro-}} +# Libretro core. Defaults to the name of the current package with the +# "libretro-" prefix excluded and hyphens replaced with underscores +# (e.g. genesis_plus_gx for libretro-genesis-plus-gx) +if [[ -z "${LIBRETRO_CORE_NAME}" ]]; then + LIBRETRO_CORE_NAME=${PN#libretro-} + LIBRETRO_CORE_NAME=${LIBRETRO_CORE_NAME//-/_} +fi # @ECLASS-VARIABLE: LIBRETRO_COMMIT_SHA # @DESCRIPTION: -- cgit v1.2.3-18-g5258