mirror of
https://github.com/libretro/libretro-super
synced 2025-01-01 09:00:08 +00:00
The stuff that would've broken libretro-fetch.sh
This commit is contained in:
parent
d197fdf405
commit
54acbcaaee
@ -22,7 +22,8 @@ register_module() {
|
|||||||
build_plats="${build_plats#,}"
|
build_plats="${build_plats#,}"
|
||||||
skip_plats="${skip_plats#,}"
|
skip_plats="${skip_plats#,}"
|
||||||
|
|
||||||
eval "libretro_${mod_type}s=\"\$libretro_${mod_type}s $mod_name:${build_plats:-any}:$skip_plats\""
|
eval "libretro_${mod_type}s=\"\$libretro_${mod_type}s $mod_name:${build_plats:=any}:$skip_plats\""
|
||||||
|
libretro_modules="$libretro_modules $mod_name:$build_plats:$skip_plats"
|
||||||
else
|
else
|
||||||
echo "register_module:Trying to register a $mod_type without a name"
|
echo "register_module:Trying to register a $mod_type without a name"
|
||||||
exit 1
|
exit 1
|
||||||
@ -40,9 +41,11 @@ register_core() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
can_build_module() {
|
can_build_module() {
|
||||||
|
[ -n "$force" ] && return 0
|
||||||
|
|
||||||
if [[ "$1" != *:*:* ]]; then
|
if [[ "$1" != *:*:* ]]; then
|
||||||
# Not in <name>:<build>:<skip> format, assume developer mode
|
# Not in <name>:<build>:<skip> format, assume error
|
||||||
return 0
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
build_plats="${1#*:}"
|
build_plats="${1#*:}"
|
||||||
@ -64,3 +67,14 @@ can_build_module() {
|
|||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
find_module() {
|
||||||
|
needle="$1"
|
||||||
|
shift
|
||||||
|
|
||||||
|
for haystack in $@; do
|
||||||
|
if [[ "$needle" == $haystack:* ]]; then
|
||||||
|
echo "$needle"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user