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: Groovy Arcade : segmentation fault  (Read 3740 times)

0 Members and 1 Guest are viewing this topic.

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Groovy Arcade : segmentation fault
« on: January 21, 2019, 02:21:29 am »
GroovyArcade-Arch2018.03.04-x86_64
Installed using virtualbox on my mid-2011 i5 iMac.

Default groovymame works.

Used mame source, applied groovy suppression haynor patches. Make -j5 succeeds. ./mame64 results in a Segmentation fault.

Dumped and started with a fresh source. Downloaded calamity’s groovy binary. ./groovymame -v and I get two messages from SwitchRes and then a Segmentation fault.

Ideas?

jimmyj1979

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 39
  • Last login:May 02, 2022, 07:26:01 am
  • I want to build my own arcade controls!
Re: Groovy Arcade : segmentation fault
« Reply #1 on: January 21, 2019, 03:14:36 am »
Try it under XKDE

i had this problem yesterday, couldnt run groovymame from terminal, needed to be run from within terminal in KDE :)

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #2 on: January 21, 2019, 07:44:13 am »
Try it under XKDE

i had this problem yesterday, couldnt run groovymame from terminal, needed to be run from within terminal in KDE :)

wtf I booted to lxde as you suggested, launch lxterminal, and both my binaries run! Any idea why this is? Are they dependent on x11? The preinstalled mame does not need it. Hmm…?

I also get the following error: ALSA lib pcm.c:8424:(snd_pcm_recover) underrun occurred

This does not work from the shell:
$ ./mame64 -videodriver directfb
$ coredumpctl list
$ coredumpctl gdb 1663
See attached photo.

This does not work from the shell:
$ ./mame64 -cc
$ nano mame.ini
#
# SDL LOW-LEVEL DRIVER OPTIONS
#
videodriver directfb
$ ./mame64

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #3 on: January 21, 2019, 09:19:05 am »
Sidenote: Be careful because groovy arcade isn’t set to ignore updates to the linux kernel. Meaning you can loose your modified 15khz kernel! Good thing I am testing within a virtual box install!

$ cd /var/cache/pacman/pkg
$ ls | less

I have no linux package to downgrade!

To ignore package updates of the kernel:

1. ```$ sudo nano /etc/pacman.conf```
2. Change line 25 ```#IgnorePkg =``` to ```IgnorePkg = linux```

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7414
  • Last login:April 10, 2024, 02:02:31 pm
  • Quote me with care
Re: Groovy Arcade : segmentation fault
« Reply #4 on: January 21, 2019, 09:48:00 am »
What's the purpose of -videodriver directfb?
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #5 on: January 21, 2019, 10:38:33 am »
What's the purpose of -videodriver directfb?

SDL Low-level Driver Options ~—————————

-videodriver <driver>

SDL video driver to use (‘x11’, ‘directfb’, … or ‘auto’ for SDL default)

Just trying things. The groovymame that comes bundled has options set to auto in mame.ini. Perhaps there is compilation options?

Doozer

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 498
  • Last login:June 12, 2023, 09:19:49 am
  • Z80 ERROR
Re: Groovy Arcade : segmentation fault
« Reply #6 on: January 21, 2019, 10:52:39 am »
What's the purpose of -videodriver directfb?

SDL Low-level Driver Options ~—————————

-videodriver <driver>

SDL video driver to use (‘x11’, ‘directfb’, … or ‘auto’ for SDL default)

Just trying things. The groovymame that comes bundled has options set to auto in mame.ini. Perhaps there is compilation options?

You should stick to the SDL2 library under Linux.

It seems that the "groovy suppression" patch is causing issue. Are you sure this patch is working for the Linux build?

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #7 on: January 21, 2019, 11:21:17 am »
http://mamestuff.lowtrucks.net/MKChamp/

Using the binary I compiled with suppression groovy and haynor666 various fixes patches does not work in auto (sdl) from shell. The precompiled Linux binary provides on calamity google drive yields same error. Did you compile with suppression? I’ll try again without, but it takes hours each time I try this. Both binaries work when launched with LXDE is loaded, so I don’t think its the suppression patch.

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #8 on: January 21, 2019, 01:35:59 pm »
I’m into something. I think default videodriver is x11, which is available when lxde is launched. However, explicitly demanding SDL results in sdl not available.

Before compiling, I did the following:

1. ```$ sudo pacman -Syu``` Update all packages on the system.
2. ```$ sudo pacman -S base-devel git sdl2 gconf sdl2_ttf gcc qt5```

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7414
  • Last login:April 10, 2024, 02:02:31 pm
  • Quote me with care
Re: Groovy Arcade : segmentation fault
« Reply #9 on: January 21, 2019, 04:17:03 pm »
GroovyMAME only works properly with -video opengl (IIRC). Whatever it's set as default in the live-CD's mame.ini is what you should use.

@Doozer, is it possible that the use of the xrandr api now makes GM require x11 to run?
« Last Edit: January 21, 2019, 04:19:52 pm by Calamity »
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead of pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

jimmyj1979

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 39
  • Last login:May 02, 2022, 07:26:01 am
  • I want to build my own arcade controls!
Re: Groovy Arcade : segmentation fault
« Reply #10 on: January 21, 2019, 05:18:20 pm »
Sidenote: Be careful because groovy arcade isn’t set to ignore updates to the linux kernel. Meaning you can loose your modified 15khz kernel! Good thing I am testing within a virtual box install!

$ cd /var/cache/pacman/pkg
$ ls | less

I have no linux package to downgrade!

To ignore package updates of the kernel:

1. ```$ sudo nano /etc/pacman.conf```
2. Change line 25 ```#IgnorePkg =``` to ```IgnorePkg = linux```

hey mate I have tried this on my 2017 GA build, it killed my attract mode install. Did your attract mode work after you did this?

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #11 on: January 21, 2019, 10:17:28 pm »
Sidenote: Be careful because groovy arcade isn’t set to ignore updates to the linux kernel. Meaning you can loose your modified 15khz kernel! Good thing I am testing within a virtual box install!

$ cd /var/cache/pacman/pkg
$ ls | less

I have no linux package to downgrade!

To ignore package updates of the kernel:

1. ```$ sudo nano /etc/pacman.conf```
2. Change line 25 ```#IgnorePkg =``` to ```IgnorePkg = linux```

hey mate I have tried this on my 2017 GA build, it killed my attract mode install. Did your attract mode work after you did this?

I currently have a working attractmode. I compiled and installed attract 2.5.1 before doing a Pac-Man update.

jimmyj1979

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 39
  • Last login:May 02, 2022, 07:26:01 am
  • I want to build my own arcade controls!
Re: Groovy Arcade : segmentation fault
« Reply #12 on: January 21, 2019, 10:45:24 pm »
i just may try this :)

Doozer

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 498
  • Last login:June 12, 2023, 09:19:49 am
  • Z80 ERROR
Re: Groovy Arcade : segmentation fault
« Reply #13 on: January 22, 2019, 07:51:47 am »
@Doozer, is it possible that the use of the xrandr api now makes GM require x11 to run?

The xrandr tool is indeed needing the X library to run. The DRM part is not X related but the management of the video screen requires X to be loaded.

@keilmillerjr, do you try to launch GM from a frame buffer? If this is the case, it is better to stick to the stock Mame executable.

Under X the -video auto is treated equivalent to -video opengl for SDL. The opengl backend is indeed the way the system draw the picture to screen.

Video option is one of the following output method: none, soft, opengl or bgfx

Videodriver can be either:
Code: [Select]
                            opengl
                         opengles2
                          opengles
                          software

SDL will be used as the drawing library (Using SDL multi-window OpenGL driver (SDL 2.0+))

SDL use internally XRANDR with X11 to manipulate the connected CRTCs (SDL_VIDEO_X11_XRANDR).

Cheers!

Doozer

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 498
  • Last login:June 12, 2023, 09:19:49 am
  • Z80 ERROR
Re: Groovy Arcade : segmentation fault
« Reply #14 on: January 22, 2019, 07:55:35 am »
I went through the entire thread. Now I understand better the situation.

Groovymame is not designed to be functional under directfb. It is expecting to be run under X11.

DRM can be used to control the screen but the xrandr library will not be operational as it requires X11. Directfb is only providing very basic screen control.

« Last Edit: January 22, 2019, 01:28:15 pm by Doozer »

keilmillerjr

  • Trade Count: (+5)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1847
  • Last login:October 06, 2023, 10:20:39 pm
  • Web Developer.
Re: Groovy Arcade : segmentation fault
« Reply #15 on: January 23, 2019, 07:39:27 am »
I went through the entire thread. Now I understand better the situation.

Groovymame is not designed to be functional under directfb. It is expecting to be run under X11.

DRM can be used to control the screen but the xrandr library will not be operational as it requires X11. Directfb is only providing very basic screen control.

Gotcha. So I noticed, the preinstalled binary /usr/local/bin/groovymame when launched from shell also returns a seg fault. This tells me that it is not being launched alone from a shell. Time to investigate how attract/mame is being launched. Perhaps somewhere in /opt/gasetup/core/procedures/interactive is the answer.? Replacing the official binary with the one I compiled worked. However, a more normal directory structure would be helpful. GA seems awesome but a little complicated with its pre-configuring.

Doozer

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 498
  • Last login:June 12, 2023, 09:19:49 am
  • Z80 ERROR
Re: Groovy Arcade : segmentation fault
« Reply #16 on: January 23, 2019, 08:21:49 am »
Gotcha. So I noticed, the preinstalled binary /usr/local/bin/groovymame when launched from shell also returns a seg fault. This tells me that it is not being launched alone from a shell. Time to investigate how attract/mame is being launched. Perhaps somewhere in /opt/gasetup/core/procedures/interactive is the answer.? Replacing the official binary with the one I compiled worked. However, a more normal directory structure would be helpful. GA seems awesome but a little complicated with its pre-configuring.

Hi keilmillerjr,

Are you sure the environment variable named DISPLAY is properly set? If X is started from another shell the previously opened shells do not have DISPLAY set.

E.g.
Code: [Select]
[arcade@cabvm64 ~]$ groovymame -verbose -seconds_to_run 10 bonzeadv
SwitchRes: v0.017m, Monitor: lcd, Orientation: horizontal, Modeline generation: enabled
SwitchRes: Using default vfreq range for LCD 59.000000-61.000000
Segmentation fault (core dumped)

This can be easily fixed by specifying how to reach X. I don't know if you have already tried but you can give the following call a try.
Code: [Select]
DISPLAY=:0 groovymame [...]

If this is solving your issue, you can also export it once. This line can be made permanent in a shell script or at login by adding it to either .back_profile, .bashrc or /etc/profile (at your convenience).
Code: [Select]
export DISPLAY=:0
groovymame [...]