-
Notifications
You must be signed in to change notification settings - Fork 453
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Satellite tracker crash on MacOs #1648
Comments
Adding Mac back trace posted in mailing list: lldb) thread backtrace
And similar on ubuntu: Both crashes appear to be in getPipes, rather than the Satellite Tracker. I've been unable to reproduce this on Windows, Linux or Mac. Do other plugins such as the AIS Feature crash? Does the problem occur with the release .dmg as well as your own build? |
If just your own build, make sure you do a:
first, to ensure everything is rebuilt. |
I always start with a clean start and then git pull etc.
So…make clean, is that useful then?
…On 12 Apr 2023 at 17:55 +0200, srcejon ***@***.***>, wrote:
If just your own build, make sure you do a:
make clean
First, to ensure everything is rebuilt.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
I use this script while in the Downloads folder:
clear
git clone https://github.com/f4exb/sdrangel.git
cd sdrangel
mkdir build
cd build
cmake -Wno-dev -DRX_SAMPLE_24BIT=ON ..
make -j2
sudo make install
cd ~/Downloads
sudo rm -R sdrangel
All plugins etc. are installed with Homebrew.
The satellite feature is the only one that crashes.
…On 12 Apr 2023 at 17:55 +0200, srcejon ***@***.***>, wrote:
If just your own build, make sure you do a:
make clean
First, to ensure everything is rebuilt.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Only my own, on Linux as well as Mac.
Ais is ok.
…On 12 Apr 2023 at 17:54 +0200, srcejon ***@***.***>, wrote:
Adding Mac back trace posted in mailing list:
lldb) thread backtrace
• thread #22, name = 'QThread', stop reason = EXC_BAD_ACCESS (code=1, address=0x33fa8d30)
• frame #0: 0x0000000100faf5e9 libsdrbase.dylibObjectPipesRegistrations::getPipes(QObject const*, QString const&, QList<ObjectPipe*>&) + 89 frame #1: 0x00000001838c3610 libfeaturesatellitetracker.dylibSatelliteTrackerWorker::update() + 3584
frame #2: 0x0000000102ff78ef QtCore___lldb_unnamed_symbol9624 + 159 frame #3: 0x0000000102fe62e1 QtCoreQObject::event(QEvent*) + 113
frame #4: 0x000000010282d886 QtWidgetsQApplicationPrivate::notify_helper(QObject*, QEvent*) + 262 frame #5: 0x000000010282ec0d QtWidgetsQApplication::notify(QObject*, QEvent*) + 477
frame #6: 0x0000000102fbcd67 QtCoreQCoreApplication::notifyInternal2(QObject*, QEvent*) + 167 frame #7: 0x000000010301e2b5 QtCoreQTimerInfoList::activateTimers() + 1029
frame #8: 0x000000010301c964 QtCoreQEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 932 frame #9: 0x0000000102fb9336 QtCoreQEventLoop::exec(QFlagsQEventLoop::ProcessEventsFlag) + 502
frame #10: 0x0000000102df406c QtCoreQThread::exec() + 140 frame #11: 0x0000000102df4f60 QtCore___lldb_unnamed_symbol7195 + 320
frame #12: 0x00007ff80328a1d3 libsystem_pthread.dylib_pthread_start + 125 frame #13: 0x00007ff803285bd3 libsystem_pthread.dylibthread_start + 15
And similar on ubuntu:
Both crashes appear to be in getPipes, rather than the Satellite Tracker. I've been unable to reproduce this on Windows, Linux or Mac. Do other plugins such as the AIS Feature crash?
Does the problem occur with the release .dmg as well as your own build?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
If you start from an empty directory, then no need for make clean. |
Is it possible plugins from different builds are being mixed together? Maybe do:
And check the dates on the plugins match |
They are all from April 11.
…On 12 Apr 2023 at 19:04 +0200, f4exb/sdrangel ***@***.***>, wrote:
ls -l /opt/install/sdrangel/lib/sdrangel/plugins
|
Hmm. Built using your above script, and it works OK. What version of gcc are you using? gcc --version |
Can you also confirm exactly when it crashes and the exact steps you use.
|
Hi Jon,
Thanks for investigating this.
DMG 13 (and also 12) work fine.
This is the Ubuntu-version:
gcc (Ubuntu 12.2.0-3ubuntu1) 12.2.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
This is the MacOs-version:
Apple clang version 14.0.3 (clang-1403.0.22.14.1)
Target: x86_64-apple-darwin22.5.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
On both systems (in fact 2x2=4) it crashes when..
• I start with an empty workspace
• Add the satellite-tracker
• Start it….segmentation fault!
Also adding the satellite-tracker to an existing preset crashes the same way
Regards
…On 13 Apr 2023 at 15:17 +0200, srcejon ***@***.***>, wrote:
Hmm. Built using your above script, and it works OK. What version of gcc are you using?
gcc --version
gcc (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Is it possible you built sgp4 library using gcc 11? If so, try rebuilding that. |
Hi Jon,
I compiled on both systems. Even rebooted.., but no, no difference...
…On 13 Apr 2023 at 16:15 +0200, srcejon ***@***.***>, wrote:
> This is the Ubuntu-version: gcc (Ubuntu 12.2.0-3ubuntu1)
Is it possible you built sgp4 library using gcc 11? If so, try rebuilding that.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Hmm. Running out of ideas. What version of Qt is reported in SDRangel status bar? What version of Ubuntu? Just tried Gcc 12 here and no problem. |
MacOs:
DMG: 5.15.2
Selfcompiled: 5.15.8
Ubuntu: 5.15.6
…On 13 Apr 2023 at 16:51 +0200, srcejon ***@***.***>, wrote:
Hmm. Running out of ideas.
What version of Qt is reported in SDRangel status bar?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Just rebuilt on Ubuntu 22.10 with gcc 12 and Qt 5.15.6 and still can't see the problem. All I can really suggest is trying a debug build with cmake -DCMAKE_BUILD_TYPE=Debug ... then rerunning in the debugger, which should give the exact line the program is crashing on. |
Try the debug build on ubuntu, instead. As I can more easily reproduce that. Thanks |
What is happening Jon?:
[ 37%] Linking CXX shared library ../../../lib/pluginssrv/liblocalsinksrv.dylib
Undefined symbols for architecture x86_64:
"LocalSinkSettings::m_maxFFTBands", referenced from:
LocalSinkSettings::deserialize(QByteArray const&) in localsinksettings.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [lib/pluginssrv/liblocalsinksrv.dylib] Error 1
make[1]: *** [pluginssrv/channelrx/localsink/CMakeFiles/localsinksrv.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 37%] Building CXX object pluginssrv/channelrx/filesink/CMakeFiles/filesinksrv.dir/filesinkmessages.cpp.o
[ 37%] Building CXX object pluginssrv/channelrx/filesink/CMakeFiles/filesinksrv.dir/filesinkwebapiadapter.cpp.o
[ 37%] Building CXX object pluginssrv/channelrx/filesink/CMakeFiles/filesinksrv.dir/filesinkplugin.cpp.o
[ 37%] Linking CXX shared library ../../../lib/pluginssrv/libfilesinksrv.dylib
[ 37%] Built target filesinksrv
make: *** [all] Error 2
This is new, never got this error.
On 13 Apr 2023 at 21:03 +0200, srcejon ***@***.***>, wrote:
Try the debug build on ubuntu, instead. As I can more easily reproduce that. Thanks
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
It's just an issue when optimisation is disabled. I'll take a look tomorrow, but for now, you can skip it with cmake -DENABLE_CHANNELRX_LOCALSINK=OFF |
It gets (for me) even stranger..
The compilation on my Mac mini (Ubuntu) went fine. I will continue testing with the debugger.
However, why do I see this error only on my iMac. Here I will add the string you mention below and let you know.
…On 13 Apr 2023 at 22:48 +0200, srcejon ***@***.***>, wrote:
It's just an issue when optimisation is disabled. I'll take a look tomorrow, but for now, you can skip it with cmake -DENABLE_CHANNELRX_LOCALSINK=OFF
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
This is the result Jon:
[ 43%] Linking CXX shared library ../../../lib/pluginssrv/libmodaissrv.dylib
Undefined symbols for architecture x86_64:
"AISModSettings::AISMOD_SAMPLE_RATE", referenced from:
AISModSource::applySettings(AISModSettings const&, bool) in aismodsource.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [lib/pluginssrv/libmodaissrv.dylib] Error 1
make[1]: *** [pluginssrv/channeltx/modais/CMakeFiles/modaissrv.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 43%] Building CXX object pluginssrv/channeltx/modam/CMakeFiles/modamsrv.dir/ammodsettings.cpp.o
[ 43%] Building CXX object pluginssrv/channeltx/modam/CMakeFiles/modamsrv.dir/ammodbaseband.cpp.o
[ 43%] Building CXX object pluginssrv/channeltx/modam/CMakeFiles/modamsrv.dir/ammodsource.cpp.o
[ 43%] Building CXX object pluginssrv/channeltx/modam/CMakeFiles/modamsrv.dir/ammodwebapiadapter.cpp.o
[ 43%] Linking CXX shared library ../../../lib/pluginssrv/libmodamsrv.dylib
[ 43%] Built target modamsrv
make: *** [all] Error 2
The scripts are exactly the same on both machines and were always used without any problem.
This happens since adding the debug option to cmake.
Or….?
…On 13 Apr 2023 at 22:48 +0200, srcejon ***@***.***>, wrote:
It's just an issue when optimisation is disabled. I'll take a look tomorrow, but for now, you can skip it with cmake -DENABLE_CHANNELRX_LOCALSINK=OFF
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
This was the debugger-report on Ubuntu:
023-04-14 07:43:11.560 (I) WebAPIServer::start: starting web API server at http://:8091
Process 44536 stopped and restarted: thread 1 received signal: SIGCHLD
2023-04-14 07:43:32.019 (W) FeatureWebAPIUtils::mapSetDateTime: no Map feature
Process 44536 stopped
* thread #43, name = 'QThread', stop reason = signal SIGSEGV: address access protected (fault address: 0x7ffff5da6678)
frame #0: 0x00007ffff5acd240 libQt5Core.so.5`___lldb_unnamed_symbol9613 + 48
libQt5Core.so.5`___lldb_unnamed_symbol9613:
-> 0x7ffff5acd240 <+48>: lock
0x7ffff5acd241 <+49>: cmpxchgq %rdx, (%rdi)
0x7ffff5acd245 <+53>: jne 0x7ffff5acd276 ; <+102>
0x7ffff5acd247 <+55>: movq %rbp, 0x8(%rbx)
(lldb) thread backtrace
* thread #43, name = 'QThread', stop reason = signal SIGSEGV: address access protected (fault address: 0x7ffff5da6678)
* frame #0: 0x00007ffff5acd240 libQt5Core.so.5`___lldb_unnamed_symbol9613 + 48
frame #1: 0x00007ffff70c8c57 libsdrbase.so`QMutexLocker::QMutexLocker(this=0x00007fff991fd768, m=0x00007ffff7b376e8) at qmutex.h:233:43
frame #2: 0x00007ffff70c910d libsdrbase.so`QMutexLocker::QMutexLocker(this=0x00007fff991fd768, m=0x00007ffff7b376e8) at qmutex.h:238:52
frame #3: 0x00007ffff71e7437 libsdrbase.so`ObjectPipesRegistrations::getPipes(this=0x00007ffff7b37688, producer=0x0000555556323fe0, type=0x00007fff991fd8f8, pipes=0x00007fff991fd898) at objectpipesregistrations.cpp:145:32
frame #4: 0x00007ffff71e6178 libsdrbase.so`MessagePipes::getMessagePipes(this=0x00007ffff7b37668, producer=0x0000555556323fe0, type=0x00007fff991fd8f8, pipes=0x00007fff991fd898) at messagepipes.cpp:50:36
frame #5: 0x00007fffaf983ab9 libfeaturesatellitetracker.so`SatelliteTrackerWorker::update() + 2761
frame #6: 0x00007ffff5cf7776 libQt5Core.so.5`___lldb_unnamed_symbol11852 + 118
frame #7: 0x00007ffff5ce7945 libQt5Core.so.5`QObject::event(QEvent*) + 165
frame #8: 0x00007ffff696bf32 libQt5Widgets.so.5`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 130
frame #9: 0x00007ffff5cbae38 libQt5Core.so.5`QCoreApplication::notifyInternal2(QObject*, QEvent*) + 296
frame #10: 0x00007ffff5d13e71 libQt5Core.so.5`QTimerInfoList::activateTimers() + 929
frame #11: 0x00007ffff5d1475c libQt5Core.so.5`___lldb_unnamed_symbol11955 + 44
frame #12: 0x00007ffff4121569 libglib-2.0.so.0`g_main_context_dispatch + 665
frame #13: 0x00007ffff41763c8 libglib-2.0.so.0`___lldb_unnamed_symbol2758 + 520
frame #14: 0x00007ffff411ed20 libglib-2.0.so.0`g_main_context_iteration + 48
frame #15: 0x00007ffff5d14aea libQt5Core.so.5`QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 106
frame #16: 0x00007ffff5cb97cb libQt5Core.so.5`QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) + 299
frame #17: 0x00007ffff5acba1b libQt5Core.so.5`QThread::exec() + 107
frame #18: 0x00007ffff5accc51 libQt5Core.so.5`___lldb_unnamed_symbol9612 + 321
frame #19: 0x00007ffff5290402 libc.so.6`start_thread(arg=<unavailable>) at pthread_create.c:442:8
frame #20: 0x00007ffff531f590 libc.so.6`__clone3 at clone3.S:81
…On 13 Apr 2023 at 22:48 +0200, srcejon ***@***.***>, wrote:
It's just an issue when optimisation is disabled. I'll take a look tomorrow, but for now, you can skip it with cmake -DENABLE_CHANNELRX_LOCALSINK=OFF
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Probably because it's a different compiler (clang vs gcc) and has compiled that bit of code slightly differently. |
But that doesn’t explain why things compiled fine two days ago...
…On 14 Apr 2023 at 09:02 +0200, srcejon ***@***.***>, wrote:
> It gets (for me) even stranger.. The compilation on my Mac mini (Ubuntu) went fine. I will continue testing with the debugger. However, why do I see this error only on my iMac.
Probably because it's a different compiler (clang vs gcc) and has compiled that bit of code slightly differently.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
???
I just plain old used "cmake -Wno-dev -DRX_SAMPLE_24BIT=ON"
And I don’t get any compilation-errors anymore.
Is there any logical explanation?
I wanted to compile myself because a) I can learn things and b) the DMG has no support for the Adam Pluto.
To make things easier: shall I make a pull-request for that?
…On 14 Apr 2023 at 09:08 +0200, Loe Walter ***@***.***>, wrote:
But that doesn’t explain why things compiled fine two days ago...
On 14 Apr 2023 at 09:02 +0200, srcejon ***@***.***>, wrote:
> > It gets (for me) even stranger.. The compilation on my Mac mini (Ubuntu) went fine. I will continue testing with the debugger. However, why do I see this error only on my iMac.
> Probably because it's a different compiler (clang vs gcc) and has compiled that bit of code slightly differently.
> —
> Reply to this email directly, view it on GitHub, or unsubscribe.
> You are receiving this because you authored the thread.Message ID: ***@***.***>
|
It's because of the -DCMAKE_BUILD_TYPE=Debug option. That tells the compiler to compile slightly differently, which results in the error. If you use -DCMAKE_BUILD_TYPE=Release you wont see the problem. Note that not specifying -DCMAKE_BUILD_TYPE defaults to Release. |
Thanks for the info Jon.
…On 14 Apr 2023 at 10:06 +0200, srcejon ***@***.***>, wrote:
It's because of the -DCMAKE_BUILD_TYPE=Debug option. That tells the compiler to compile slightly differently, which results in the error.
If you use -DCMAKE_BUILD_TYPE=Release you wont see the problem. Note that not specifying -DCMAKE_BUILD_TYPE defaults to Release.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Forgot to ask:
So there is an error in the source code?
…On 14 Apr 2023 at 10:06 +0200, srcejon ***@***.***>, wrote:
It's because of the -DCMAKE_BUILD_TYPE=Debug option. That tells the compiler to compile slightly differently, which results in the error.
If you use -DCMAKE_BUILD_TYPE=Release you wont see the problem. Note that not specifying -DCMAKE_BUILD_TYPE defaults to Release.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Compiled v.7.12 on MacOs Ventura.
Started with an empty workspace and added Satellite tracker
Crash with only: segmentation fault.
Did I start wrong...?
The text was updated successfully, but these errors were encountered: