Previous Thread
Next Thread
Print Thread
Unable to run MAME from an external hard disk #116030 09/28/19 06:28 PM
Joined: May 1999
Posts: 559
Carbon Online Content OP
Senior Member
OP Online Content
Senior Member
Joined: May 1999
Posts: 559
I didn't try this for a long time, so I'm a bit baffled why it doesn't work because I'm sure I did it successfully before.

I have an external hard disk (USB C, but I don't think that matters), and I'm using Terminal to cd to it. In the MAME folder I created a MAME.ini file where I specified the individual folders full path:

Code
rompath                   /Volumes/TerraMaster/Emulation/MAME/ROMs
hashpath                  /Volumes/TerraMaster/Emulation/MAME/Hash
samplepath                /Volumes/TerraMaster/Emulation/MAME/Samples
artpath                   /Volumes/TerraMaster/Emulation/MAME/Artwork


But whatever system I want to start I always get the "Fatal error: Required files are missing, the machine cannot be run" error, but the ROMs I want to use check out ok in ClrMAME.

What am I doing wrong?

PS: I'm using v0.214 on macOS 10.14.6 with an executable name of MAME

Last edited by Carbon; 09/28/19 06:29 PM.
Re: Unable to run MAME from an external hard disk [Re: Carbon] #116031 09/28/19 06:35 PM
Joined: May 1999
Posts: 559
Carbon Online Content OP
Senior Member
OP Online Content
Senior Member
Joined: May 1999
Posts: 559
OK, I forgot about the necessary -inipath parameter. I assumed MAME would read by default the .ini file from the current working directory.

Anyway, it works now, please ignore my post.

Last edited by Carbon; 09/28/19 06:35 PM.
Re: Unable to run MAME from an external hard disk [Re: Carbon] #116034 09/29/19 02:14 AM
Joined: Feb 2004
Posts: 2,067
Vas Crabb Offline
Very Senior Member
Offline
Very Senior Member
Joined: Feb 2004
Posts: 2,067
It does read an INI file from the current working directory. If you double-click an executable in the Finder, the current working directory is set to your home directory when it's launched. See here: https://docs.mamedev.org/commandline/commandline-all.html

Re: Unable to run MAME from an external hard disk [Re: Carbon] #116041 09/29/19 04:23 PM
Joined: May 1999
Posts: 559
Carbon Online Content OP
Senior Member
OP Online Content
Senior Member
Joined: May 1999
Posts: 559
I'm using the following shell file that I double click to start MAME:

Code
#!/bin/sh
cd /Applications/Emulation/MAME
./MAME -inipath /Applications/Emulation/MAME/MAME.ini -window


or when using the external drive, the contents are:

Code
#!/bin/sh
cd /Volumes/External/Emulation/MAME
./MAME -inipath /Volumes/External/Emulation/MAME/MAME.ini -window


I have to specify the window parameter on the command line as it ignores the same parameter in the ini file.

When I put a copy of the ini file into my home folder, I get the following error when I double click on the MAME app:

Code
Unable to open effect file bgfx/effects/gui_opaque.json
Unable to open effect file bgfx/effects/gui_blend.json
Unable to open effect file bgfx/effects/gui_multiply.json
Unable to open effect file bgfx/effects/gui_add.json
Unable to open effect file bgfx/effects/screen_opaque.json
Unable to open effect file bgfx/effects/screen_blend.json
Unable to open effect file bgfx/effects/screen_multiply.json
Unable to open effect file bgfx/effects/screen_add.json
Ignoring MAME exception: BGFX: Unable to load required shaders. Please check and reinstall the bgfx folder

Fatal error: BGFX: Unable to load required shaders. Please check and reinstall the bgfx folder

Segmentation fault: 11
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

Re: Unable to run MAME from an external hard disk [Re: Carbon] #116042 09/29/19 04:43 PM
Joined: Mar 2001
Posts: 16,336
R
R. Belmont Online Content
Very Senior Member
Online Content
Very Senior Member
R
Joined: Mar 2001
Posts: 16,336
You need the entire bgfx/ folder in the current directory, IIRC. That's why Vas's recommended script in the documentation sets it first.

Re: Unable to run MAME from an external hard disk [Re: Carbon] #116043 09/29/19 07:25 PM
Joined: May 1999
Posts: 559
Carbon Online Content OP
Senior Member
OP Online Content
Senior Member
Joined: May 1999
Posts: 559
Yeah, it's no big deal for me as the small script I'm using works fine, but shouldn't there be a way to specify the BGFX folder in the ini file, too? That way this error would not occur.

Re: Unable to run MAME from an external hard disk [Re: Carbon] #116045 09/29/19 10:12 PM
Joined: Mar 2001
Posts: 16,336
R
R. Belmont Online Content
Very Senior Member
Online Content
Very Senior Member
R
Joined: Mar 2001
Posts: 16,336
You could not use BGFX for the portable version.


Moderated by  R. Belmont 

Who's Online Now
6 registered members (R. Belmont, Reznor007, Olivier Galibert, ICEknight, 2 invisible), 145 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
ShoutChat Box
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics8,693
Posts114,269
Members4,865
Most Online510
Aug 26th, 2019
Powered by UBB.threads™ PHP Forum Software 7.7.3