/tools-orca

Open ROM Conversion Assistant

Primary LanguageCMozilla Public License 2.0MPL-2.0

logo


release license discord forum stars issues

What is ORCA

A tool to merge MAME ROMs using recipes (.xml or .mra) into a single .rom file to be used with an Arcade gateware IP Core.

Installation

To set up ORCA, you only need to:

  • Download the latest release
    • Debian/Ubuntu and WSL users can download the .deb package and install using sudo dpkg -i ORCA-<version>-Linux.deb
  • Extract the executable to a directory in your PATH System Variable. e.g: /usr/bin on macOS/Linux or %WINDIR% on Windows

Usage

Single File

# Linux/macOS
orca -z /PATH/TO/MAME/ZIPS file.[xml/mra]

# Windows
orca.exe -z DRIVE:\PATH\TO\MAME\ZIPS file.[xml/mra]

Batch processing using scripts

Assuming you have the following structure

.
├── output
├── roms
├── tools
│   └── make_roms.[sh/ps1]
└── xml

On Linux/WSL and macOS:

Note: Change the PATHs according to your needs

#!/usr/bin/env bash

PARENT=$(dirname $PWD)
XML=$PARENT/xml
ROMS=$PARENT/roms
ASSETS=$PARENT/output

find ${XML} -name '*.xml' | while read line; do
    echo "Processing '$line'"
    orca -z ${ROMS} -O ${ASSETS} "$line"
done

Windows Powershell:

$currentPath = $(Get-Item $($MyInvocation.MyCommand.Path)).DirectoryName
$fileNames = Get-ChildItem -Path "$currentPath\..\xml" -Recurse -Include *.xml

try { 
    foreach ($f in $fileNames){
        $xmlfile = $f.FullName
        Write-Host "Processing $xmlfile ..."
        orca.exe -z ..\roms -O ..\output $xmlfile
    }
} catch {
    Write-Host "Error: $($_.Exception.Message)"
    exit 1
} finally {
    Write-Host "Done."
    timeout /t 5
}

exit 0

Output:

PS A:\rom-recipes\tools> .\make_roms.ps1
Processing A:\recipes\xml\Recipe.xml ...
Done.

Contributing

This project welcomes contributions and suggestions.

If you've found a bug or have a suggestion, please don't hesitate to detail these in the issue tracker. At this time if you have questions please leave them in the Q&A section or use the #tools-r-us channel on Rætro Discord.

Legal Notices

This work is licensed under multiple licenses.

Open Gateware and any contributors reserve all others rights, whether under their respective copyrights, patents, or trademarks, whether by implication, estoppel or otherwise.

Individual files may contain the following SPDX license tags as a shorthand for the above copyright and warranty notices:

SPDX-License-Identifier: MPL-2.0
SPDX-License-Identifier: CC-BY-SA-4.0
SPDX-License-Identifier: CC0-1.0

This eases machine processing of licensing information based on the SPDX License Identifiers that are available at https://spdx.org/licenses/.

All brands or product names are the property of their respective holders.

Powered by Open-Source Software

This project borrowed and use code from several other projects. A great thanks to their efforts!

Software/Library License Copyright/Developer
mra-tool-c The Unlicense 2020 (c) Sebastien Delestaing
JUnzip The Unlicense 2014 (c) Joonas Pihlajamaa
MD5 The Unlicense 2001 (c) Alexander Peslyak
sxmlc BSD 2-Clause "Simplified" License 2010 (c) Matthieu Labas