Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: GroovyArcade EFI USB conversion  (Read 2916 times)

0 Members and 1 Guest are viewing this topic.

DoogyRev

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 35
  • Last login:July 04, 2019, 08:24:49 am
  • I want to build my own arcade controls!
GroovyArcade EFI USB conversion
« on: May 28, 2017, 06:04:07 pm »
For anyone who is interested here is a step by step guide on how to convert a fresh USB installation of GroovyArcade to boot in EFI mode. I use it so my boot manager (rEFInd) recognises the USB stick so I don't have to use the EFI setup utility to boot it each time.  It doesn't have to be on a fresh install, pretty much the exact same steps can be taken from the cli in a running installation but the /groovyarcade/ directory should just be /.

BE AWARE THIS WILL REMOVE THE NORMAL MBR BOOTING ABILITY OF YOUR INSTALLATION. There are ways to have both, you could copy the full original syslinux folder to the root of the new partiton, syslinux --install to it and set the boot flag or install groovyarcade to one partition in the first place with an additional EFI partition prepared as below but it's outside the scope of this guide.

First, install to the USB stick as normal from the live CD. I will assume the partition empty drive method has been used.
TAKE NOTE OF THE DEVICE IT WAS INSTALLED TO...
In my case it was /dev/sdc but it will be referred to as /dev/sd? in this guide to try to avoid unnecessary borking of hard drives.
When it is finished installing do not reboot, instead exit to shell from gasetup.

Type the following command to make the EFI folder:

Code: [Select]
sudo mkdir /EFI

NOTE: I had to use SHIFT + 7 (&) on the UK keymap for /

Next copy the EFI version of syslinux:

Code: [Select]
sudo cp -afv /usr/lib/syslinux/efi64 /EFI/syslinux

NOTE: I had to use / for - on the UK keymap

Optionally, rename syslinux.efi to Groovy.efi or similar.

Copy the config, background, kernel and initramfs:

Code: [Select]
sudo cp -afv /groovyarcade/boot/syslinux/GA.png /EFI/syslinux/
sudo cp -afv /groovyarcade/boot/syslinux/syslinux.cfg /EFI/syslinux/
sudo cp -afv /groovyarcade/boot/init* /EFI/
sudo cp -afv /groovyarcade/boot/vmlinuz.linux /EFI/

NOTE: I had to use } for * on the UK keymap

Now go back to gasetup:

Code: [Select]
sudo gasetup
Go into HD installation and Partition Manager and select the device you have installed GroovyArcade on (dev/sd?).

Select the boot partition (marked with *) and change the TYPE to ef (EFI FAT 12/16/32).
NOTE THE NUMBER OF THE PARTITION e.g. dev/sdc1 (will be referred to as dev/sd?x)

Select WRITE and type yes in full to confirm your changes then exit to shell again from gasetup.

Unmount the boot partition:

Code: [Select]
sudo umount dev/sd?x
where dev/sd?x is the partition you just changed to ef type

Make the EFI partition FAT 16 and label as GAboot:

Code: [Select]
mkdosfs -F 16 dev/sd?x
fatlabel dev/sd?x GAboot

Mount the EFI partition and move the bootloader files over:

Code: [Select]
sudo mount dev/sd?x /groovyarcade/boot
sudo mv /EFI /groovyarcade/boot/

Finally edit the filesystem table to mount (or not) the new EFI partiton:

Code: [Select]
sudo nano /groovyarcade/etc/fstab

look for the line that refers to the boot partition (GAboot) and change the type from ext2 to vfat
if you don't want it mounted at boot make the edit anyway and put a # at the beginning of the line

Optionally the GAboot may be mounted to /boot/efi by making that directory (/groovyarcade//boot/efi) before you type the command to mount /dev/sd?x to /groovyarcade/boot and making the appropriate change to fstab.

This method can also be used on a HD installation and, with a bit of modification, on a multi boot HD installation. The alternative is to put the kernel and initramfs on the EFI partition and have the boot manager call that directly but I find this makes updating the installation from a live CD slightly more complicated.
« Last Edit: May 28, 2017, 06:18:11 pm by DoogyRev »