SparkSDR segfaults when started as any user other than root

64 views
Skip to first unread message

Reece Lamb

unread,
Aug 5, 2024, 1:33:46 PMAug 5
to SparkSDR
Hi,

I am trying to run SparkSDR on an Odroid M1-S, running Ubuntu 20.04 LTS. I have a display attached to the MIPI-DSI connector and the Ubuntu graphical desktop is working. 

When I start SparkSDR 2.033.0 Avalonia Version 0.10.18.0 from my user either on the command line, or via the GNOME Desktop icon, the GUI window appears briefly with no contents (in this case a black screen in the window), then segfaults.

If I start it with sudo `sudo /usr/local/bin/SparkSDR`, then it opens fine and I am able to connect to the Hermes Lite 2 (haven't played with it yet but at least I can connect).

Is it supposed to be run as sudo? Attached are the stdout and stderr from the program. If there are any additional logs I can provide, let me know! Thanks!
sparklog.txt

Reece Lamb

unread,
Aug 5, 2024, 4:51:16 PMAug 5
to SparkSDR
I'm integrating this into a portable SDR-in-a-box with keyboard and all, so I am trying to get it to launch from the GNOME desktop icon. If running it with sudo is no big deal, this is what I had to do to get it to work in Ubuntu 20.04:

Edit `sudo vim /usr/share/polkit-1/actions/SparkSDR.policy`:

```
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE policyconfig PUBLIC
 "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
 "http://www.freedesktop.org/standards/PolicyKit/1/policyconfig.dtd">

<policyconfig>

  <action id="org.freedesktop.policykit.pkexec.run-SparkSDR">
    <description>Run SparkSDR</description>
    <message>Authentication is required to run SparkSDR</message>
    <defaults>
      <allow_any>no</allow_any>
      <allow_inactive>no</allow_inactive>
      <allow_active>auth_admin_keep</allow_active>
    </defaults>
    <annotate key="org.freedesktop.policykit.exec.path">/usr/local/bin/SparkSDR</annotate>
    <annotate key="org.freedesktop.policykit.exec.allow_gui">TRUE</annotate>
  </action>

</policyconfig>
```

Then edit the desktop entry in `/usr/share/applications/SparkSDR.desktop`:

```
[Desktop Entry]
Terminal=false
Name=SparkSDR
Exec=/home/odroid/SparkSDR/sparksdr-pkexec
Icon=sparksdr.png
Type=Application
Comment=SparkSDR software defined radio
Categories=AudioVideo;Audio;HamRadio;
```

Then make a new folder: `/home/odroid/SparkSDR`:
`mkdir /home/odroid/SparkSDR`

and edit this file:

`nano /home/odroid/SparkSDR/sparksdr-pkexec`

paste in the following:
```
#!/bin/sh
bash -c 'pkexec /usr/local/bin/SparkSDR'
```

and then make it executable:
`chmod +x /home/odroid/SparkSDR/sparksdr-pkexec`

Then you should be able to run the program from the desktop icon.

ahop...@googlemail.com

unread,
Aug 5, 2024, 5:09:59 PMAug 5
to SparkSDR
Hi Reece,
you should not need to run as sudo , is there anything in the error logs (see help file for location) I f you could run with gdb and get a back trace that would also be helpful. It might also be worth trying the newer version on the download page.
73 Alan M0NNB

Reece Lamb

unread,
Aug 5, 2024, 9:21:35 PMAug 5
to SparkSDR
Hi Alan,

Thanks for the reply and the help! Attached is a gdb trace (no symbols are in the binary but it looks like there is some helpful info on an EGL library error). Something with OpenGL maybe? I also attached a lib trace if that is helpful.

I looked in this location for logs:
~/.config/m0nnb/SparkSDR2/errorlogs/

the only thing I see in there is corelog though - that corelog is timestamped with the latest time, but is blank unfortunately. 




Reece

gdb.txt
ltrace.txt

ahop...@googlemail.com

unread,
Aug 6, 2024, 1:32:42 AMAug 6
to SparkSDR
Hi Reece,
thanks for that,  it looks like some issue with Avalonia, try the 2.0.975 version from the spark download page, it uses a much more recent version.
73 Alan M0NNB

Reply all
Reply to author
Forward
0 new messages