|
10 | 10 | #
|
11 | 11 |
|
12 | 12 | rp_module_id="lr-vice"
|
13 |
| -rp_module_desc="C64 emulator - port of VICE for libretro" |
14 |
| -rp_module_help="ROM Extensions: .cmd .crt .d64 .d71 .d80 .d81 .g64 .m3u .prg .t64 .tap .x64 .zip .vsf\n\nCopy your Commodore 64 games to $romdir/c64" |
| 13 | +rp_module_desc="C64 / C128 / PET / Plus4 / VIC20 emulator - port of VICE for libretro" |
| 14 | +rp_module_help="ROM Extensions: .cmd .crt .d64 .d71 .d80 .d81 .g64 .m3u .prg .t64 .tap .x64 .zip .vsf\n\nCopy your games to $romdir/c64" |
15 | 15 | rp_module_licence="GPL2 https://raw.githubusercontent.com/libretro/vice-libretro/master/vice/COPYING"
|
16 | 16 | rp_module_repo="git https://github.com/libretro/vice-libretro.git master"
|
17 | 17 | rp_module_section="opt"
|
18 | 18 | rp_module_flags=""
|
19 | 19 |
|
| 20 | +function _get_targets_lr-vice() { |
| 21 | + echo x64 x64dtv x64sc x128 xpet xplus4 xvic |
| 22 | +} |
| 23 | + |
20 | 24 | function sources_lr-vice() {
|
21 | 25 | gitPullOrClone
|
22 | 26 | }
|
23 | 27 |
|
24 | 28 | function build_lr-vice() {
|
25 |
| - make clean |
26 |
| - make |
27 |
| - md_ret_require="$md_build/vice_x64_libretro.so" |
| 29 | + mkdir -p "$md_build/cores" |
| 30 | + local target |
| 31 | + for target in $(_get_targets_lr-vice); do |
| 32 | + make clean |
| 33 | + make EMUTYPE="$target" |
| 34 | + cp "$md_build/vice_${target}_libretro.so" "cores/" |
| 35 | + md_ret_require+=("$md_build/cores/vice_${target}_libretro.so") |
| 36 | + done |
28 | 37 | }
|
29 | 38 |
|
30 | 39 | function install_lr-vice() {
|
31 | 40 | md_ret_files=(
|
32 | 41 | 'vice/data'
|
33 | 42 | 'vice/COPYING'
|
34 |
| - 'vice_x64_libretro.so' |
35 | 43 | )
|
| 44 | + local target |
| 45 | + for target in $(_get_targets_lr-vice); do |
| 46 | + md_ret_files+=("cores/vice_${target}_libretro.so") |
| 47 | + done |
36 | 48 | }
|
37 | 49 |
|
38 | 50 | function configure_lr-vice() {
|
39 | 51 | mkRomDir "c64"
|
40 | 52 | ensureSystemretroconfig "c64"
|
41 | 53 |
|
42 |
| - addEmulator 1 "$md_id" "c64" "$md_inst/vice_x64_libretro.so" |
43 |
| - addSystem "c64" |
| 54 | + local target |
| 55 | + local name |
| 56 | + local def |
| 57 | + for target in $(_get_targets_lr-vice); do |
| 58 | + def=0 |
| 59 | + name="-${target}" |
| 60 | + if [[ "$target" == "x64" ]]; then |
| 61 | + name="" |
| 62 | + def=1 |
| 63 | + fi |
| 64 | + addEmulator "$def" "$md_id${name}" "c64" "$md_inst/vice_${target}_libretro.so" |
| 65 | + done |
44 | 66 |
|
45 | 67 | [[ "$md_mode" == "remove" ]] && return
|
46 | 68 |
|
|
0 commit comments