HauntedBees / emushelf

A middle-of-the-road game launcher.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Mac build

tonywoode opened this issue · comments

I only see a win key in dist_electron/builder-effective-config.yaml

attempting to build on macos fails with InvalidConfigurationError: image {mydir}/emushelf/emushelf/build/icons/icon256x256.png must be at least 512x512

Hi @tonywoode
I've confirmed this does work on Linux, so it's not Windows only, but I do not have a Mac to test it on there. I've committed a 512x512 icon that will hopefully resolve the error you encountered. Let me know if this works or if any other errors come up.

Hi there

The build completed! Nice icon

Got to here:

Screenshot 2021-09-20 at 15 40 34

May I bump this? Sorry...am happy to help with any testing etc...this looks like a simple thing to fix for a mac build to work....

Hello! Apologies for the belated response! I've just committed ac8f1d7 which may resolve the issue. If this doesn't work, please let me know and I can look into other ways to fix this.

Thanks for the response - No change there i'm afraid. If I unpack the asar I see this:

$ npx asar extract dist_electron/mac/emushelf.app/Contents/Resources/app.asar justtesting
$ ls justtesting
total 1288
-rw-r--r--   1 twoode  staff   483K 31 Mar 13:06 background.js
drwxr-xr-x   4 twoode  staff   128B 31 Mar 13:06 css/
-rw-r--r--   1 twoode  staff   148K 31 Mar 13:06 favicon.ico
drwxr-xr-x  30 twoode  staff   960B 31 Mar 13:06 fonts/
drwxr-xr-x  39 twoode  staff   1.2K 31 Mar 13:06 img/
-rw-r--r--   1 twoode  staff   1.3K 31 Mar 13:06 index.html
drwxr-xr-x   6 twoode  staff   192B 31 Mar 13:06 js/
drwxr-xr-x   3 twoode  staff    96B 31 Mar 13:06 node_modules/
-rw-r--r--   1 twoode  staff   444B 31 Mar 13:06 package.json

# and in case you were also wondering

$ tree justtesting/node_modules
node_modules
└── @mdi
    └── font
        ├── LICENSE
        ├── css
        │   ├── materialdesignicons.css
        │   ├── materialdesignicons.css.map
        │   ├── materialdesignicons.min.css
        │   └── materialdesignicons.min.css.map
        ├── fonts
        │   ├── materialdesignicons-webfont.eot
        │   ├── materialdesignicons-webfont.ttf
        │   ├── materialdesignicons-webfont.woff
        │   └── materialdesignicons-webfont.woff2
        ├── package.json
        ├── preview.html
        └── scss
            ├── _animated.scss
            ├── _core.scss
            ├── _extras.scss
            ├── _functions.scss
            ├── _icons.scss
            ├── _path.scss
            ├── _variables.scss
            └── materialdesignicons.scss

5 directories, 19 files

Just made another commit; fingers crossed that this one solves the problem! Not sure why the font-list stuff isn't working on Macs, so I just removed it entirely for the time being. Let me know if it works now, and thank you for your patience!

Success!!! Thanks! I'm in and playing RetroArch emulated games. I think dropping the fonts is definitely the way forward also 😛 This is truly great though!

On Mac the RetroArch setup is not ideal. Main reason is, if you recall, on a Mac, RetroArch does not in fact reside at /Applications/RetroArch.app, because that location is in fact a directory masquerading as a file and the real location of the RetroArch binary is /Applications/RetroArch.app/Contents/MacOS/RetroArch, however this location is not accessible from the open dialog electron pulls up, since you have to be able to right-click and select 'show package contents' to drill down further than /Applications/RetroArch.app, and the file browser window electron offers does not have this function - I had to open a Finder window at the real binary location and then drag its path header into the electron open dialog box for the real binary to be selectable.

To understand how this operates on the options in emushelf: If I try and select just /Applications/RetroArch.app in the Import Emulator dialog, I get a strange path populating in the Emulator Configuration form with a uuid at the end, and it doesn't work. If I try going through 'type emulator path' to put the real RetroArch binary path in, it simly doesn't recognise it as retroarch and treats it as a standard emulator...so perhaps if os==='Darwin' and path.basename='RetroArch.app' then change all uses of RetroArch.app to RetroArch.app/Contents/MacOS/RetroArch ?

The other thing that I seem to remember being more intuitive in Windows was the path to RetroArch cores, potentially because it probably doesn't often need amending from the default but in macos the default install path appears to be the utterly daft ~/Library/Application Support/RetroArch/cores (macos has never understood the concept of portable installs so developers seem to always follow suit, and that's another thing that really troubles cross-platform development - there just isn't any install option for a portable setup other than manually post-install altering hundreds of paths, so of course no one does it!!!). So perhaps if the OS===Darwin then~/Library/Application Support/RetroArch/cores should be the default?

I've checked in a change that should work with what you've suggested. Let me know if that improves things.

I'm afraid that hasn't altered the behaviour at all, in that I still have to fill in my full RetroArch cores path and then drag my retroarch exectuable directory into the finder opened by the Import Emulator button

One thing I have found is that Im unable to use ~ as a homedir shortcut in the ui

Another is that if I try to link (by directory dragging as above) to my RetroArch executable without setting the cores path, we don't seem to know we're macOS for your new conditional to have effect:

vue.runtime.esm.js?2b0e:619 [Vue warn]: Error in v-on handler: "Error: ENOENT: no such file or directory, scandir '/Applications/RetroArch.app/Contents/MacOS/cores'"

found in

---> <Settings> at src/views/Settings.vue
       <App> at src/App.vue
         <Root>
warn @ vue.runtime.esm.js?2b0e:619
logError @ vue.runtime.esm.js?2b0e:1893
globalHandleError @ vue.runtime.esm.js?2b0e:1888
handleError @ vue.runtime.esm.js?2b0e:1848
invokeWithErrorHandling @ vue.runtime.esm.js?2b0e:1871
invoker @ vue.runtime.esm.js?2b0e:2188
original._wrapper @ vue.runtime.esm.js?2b0e:6961
vue.runtime.esm.js?2b0e:1897 Error: ENOENT: no such file or directory, scandir '/Applications/RetroArch.app/Contents/MacOS/cores'
    at Object.readdirSync (fs.js:1021)
    at Object.e.readdirSync (electron/js2c/asar_bundle.js:5)
    at FileUtil.GetRetroarchCores (FileUtil.ts?93cb:42)
    at VueComponent.EmulatorSelect (Settings.vue?c4be:1104)
    at invokeWithErrorHandling (vue.runtime.esm.js?2b0e:1863)
    at HTMLInputElement.invoker (vue.runtime.esm.js?2b0e:2188)
    at HTMLInputElement.original._wrapper (vue.runtime.esm.js?2b0e:6961)

I see you're using ~/Library/Application Support/emushelf for all app data (since I had to delete that to start again with the RetroArch auto-emu-finding). Were you aware of that? Where are the app's data stored on windows?

part-fix. I'd say I'm def the type of user who would not have their emulators in the standard /Applications dir on a mac, so not particularly satisfactory for me, but a large-ish refactor required to get elsewhere atm

Thank you! Sorry I wasn't able to dedicate more bandwidth to this, but thank you for your changes!