From 491cc137ff66c3ffa5c7e166a7111deb7a3a2070 Mon Sep 17 00:00:00 2001 From: Yuri Konotopov Date: Sun, 18 Aug 2019 11:32:57 +0400 Subject: libretro-core.eclass: make $LIBRETRO_CORE_LIB_FILE variable local Default $LIBRETRO_CORE_LIB_FILE variable value depends on $S which should be set after "inherit" section according to skel.ebuild. Also this variable is used in libretro-core_src_install function only. Signed-off-by: Yuri Konotopov Signed-off-by: Craig Andrews --- eclass/libretro-core.eclass | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) (limited to 'eclass/libretro-core.eclass') diff --git a/eclass/libretro-core.eclass b/eclass/libretro-core.eclass index 0fe522911f06..c8c1933764fa 100644 --- a/eclass/libretro-core.eclass +++ b/eclass/libretro-core.eclass @@ -76,12 +76,6 @@ else fi inherit flag-o-matic -# @ECLASS-VARIABLE: LIBRETRO_CORE_LIB_FILE -# @REQUIRED -# @DESCRIPTION: -# Absolute path of this Libretro core's shared library. -: ${LIBRETRO_CORE_LIB_FILE:="${S}/${LIBRETRO_CORE_NAME}_libretro.so"} - case "${EAPI:-0}" in 6|7) EXPORT_FUNCTIONS src_unpack src_prepare src_compile src_install @@ -172,12 +166,27 @@ libretro-core_src_compile() { $([[ -f Makefile.libretro ]] && echo '-f Makefile.libretro') } +# @VARIABLE: LIBRETRO_CORE_LIB_FILE +# @DEFAULT_UNSET +# @DESCRIPTION: +# Absolute path of this Libretro core's shared library. +# src_install. +# @CODE +# src_install() { +# local LIBRETRO_CORE_LIB_FILE="${S}/somecore_libretro.so" +# +# libretro-core_src_install +# } +# @CODE + # @FUNCTION: libretro-core_src_install # @DESCRIPTION: # The libretro-core src_install function which is exported. # # This function installs the shared library for this Libretro core. libretro-core_src_install() { + local LIBRETRO_CORE_LIB_FILE=${LIBRETRO_CORE_LIB_FILE:-"${S}/${LIBRETRO_CORE_NAME}_libretro.so"} + # Absolute path of the directory containing Libretro shared libraries. local libretro_lib_dir="/usr/$(get_libdir)/libretro" # If this core's shared library exists, install that. -- cgit v1.2.3-65-gdbad