A slight non-runinng issue with 1.75.4
Posted: Fri Nov 04, 2011 11:21 am
Hi,
I've finally decided to have a bash at compiling 1.75.4 (trunk) on my FreeBSD workstation in preparation for the MNSR. After a few additional tweaks to the makefile as detailed here - https://bb.oolite.space/viewtopic.ph ... 75#p146976 it compiles without issue. However once I start the application I'm presented with the splash screen, which disappears and then nothing... the application just exits quietly without error.
I've run the application through gdb and get the following -
(gdb) run
Starting program: /home/spooky/oolite-build/trunk/oolite.app/oolite.dbg
[New LWP 101048]
[New Thread 806e041c0 (LWP 101048)]
[New Thread 806fb9380 (LWP 100462)]
[New Thread 806e0ae40 (LWP 100938)]
[New Thread 806fbfac0 (LWP 100944)]
[New Thread 806fbf900 (LWP 101013)]
[New Thread 806fbee80 (LWP 101014)]
[New Thread 806fbeb00 (LWP 101016)]
[New Thread 806fbe080 (LWP 101020)]
[New Thread 806fbd0c0 (LWP 101041)]
[New Thread 806fbe940 (LWP 101052)]
[New Thread 806fbcf00 (LWP 101053)]
[New Thread 806fbecc0 (LWP 101055)]
[New Thread 806fbcd40 (LWP 101056)]
[New Thread 806fbcb80 (LWP 101058)]
[Thread 806fb9380 (LWP 100462) exited]
Program exited with code 01.
I've run it through multiple times and on different machines and it always seems to terminate with the 2nd spawned thread exiting. I still have the 1.75.3 code and that builds and executes without issue.
Without any obvious error and no core file to examine I set a break point at main and single stepped through the code until I saw the thread in question being spawned.
(gdb) s
OOLogOutputHandlerInit () at src/Core/OOLogOutputHandler.m:127
127 sInited = YES;
(gdb) s
129 if (sLogger != nil)
(gdb) s
131 sWriteToStderr = [[NSUserDefaults standardUserDefaults] boolForKey:@"logging-echo-to-stderr"];
(gdb) s
150 NSRecursiveLock *lock = GSLogLock();
(gdb) s
0x0000000802735760 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) info threads
3 Thread 806fb9380 (LWP 100883) 0x000000080273b3cc in __error ()
from /lib/libthr.so.3
* 2 Thread 806e041c0 (LWP 100754) 0x0000000802735760 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) thread 3
[Switching to thread 3 (Thread 806fb9380 (LWP 100883))]#0 0x000000080273b3cc in __error () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function __error,
which has no line number information.
0x0000000802735762 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_rwlock_trywrlock,
which has no line number information.
0x0000000802734f80 in raise () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function raise,
which has no line number information.
0x0000000802739a80 in pthread_setcancelstate () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_setcancelstate,
which has no line number information.
0x0000000802734f9c in raise () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function raise,
which has no line number information.
0x0000000802735aaa in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_rwlock_trywrlock,
which has no line number information.
[New Thread 806e0ae40 (LWP 100408)]
[New Thread 806e04e00 (LWP 101013)]
[New Thread 806e04c40 (LWP 101014)]
[New Thread 806fbfc80 (LWP 101016)]
[New Thread 806fbf900 (LWP 101020)]
[New Thread 806fbee80 (LWP 101041)]
[New Thread 806fbdec0 (LWP 101044)]
[New Thread 806fbf740 (LWP 101052)]
[New Thread 806fbdd00 (LWP 101053)]
[New Thread 806fbfac0 (LWP 101055)]
[New Thread 806fbdb40 (LWP 101056)]
[New Thread 806fbd980 (LWP 101058)]
[Thread 806fb9380 (LWP 100883) exited]
Program exited with code 01.
To my simplistic brain it looks like its something to do with NSRecursiveLock *lock = GSLogLock(); I've compared the OOLogOutput.m and .h from 1.75.3 and 1.75.4 and they're identical. I then decided to find all the files in Core that reference NSRecursiveLock... and they're all identical too.
Does anybody have any other suggestions?
I've finally decided to have a bash at compiling 1.75.4 (trunk) on my FreeBSD workstation in preparation for the MNSR. After a few additional tweaks to the makefile as detailed here - https://bb.oolite.space/viewtopic.ph ... 75#p146976 it compiles without issue. However once I start the application I'm presented with the splash screen, which disappears and then nothing... the application just exits quietly without error.
I've run the application through gdb and get the following -
(gdb) run
Starting program: /home/spooky/oolite-build/trunk/oolite.app/oolite.dbg
[New LWP 101048]
[New Thread 806e041c0 (LWP 101048)]
[New Thread 806fb9380 (LWP 100462)]
[New Thread 806e0ae40 (LWP 100938)]
[New Thread 806fbfac0 (LWP 100944)]
[New Thread 806fbf900 (LWP 101013)]
[New Thread 806fbee80 (LWP 101014)]
[New Thread 806fbeb00 (LWP 101016)]
[New Thread 806fbe080 (LWP 101020)]
[New Thread 806fbd0c0 (LWP 101041)]
[New Thread 806fbe940 (LWP 101052)]
[New Thread 806fbcf00 (LWP 101053)]
[New Thread 806fbecc0 (LWP 101055)]
[New Thread 806fbcd40 (LWP 101056)]
[New Thread 806fbcb80 (LWP 101058)]
[Thread 806fb9380 (LWP 100462) exited]
Program exited with code 01.
I've run it through multiple times and on different machines and it always seems to terminate with the 2nd spawned thread exiting. I still have the 1.75.3 code and that builds and executes without issue.
Without any obvious error and no core file to examine I set a break point at main and single stepped through the code until I saw the thread in question being spawned.
(gdb) s
OOLogOutputHandlerInit () at src/Core/OOLogOutputHandler.m:127
127 sInited = YES;
(gdb) s
129 if (sLogger != nil)
(gdb) s
131 sWriteToStderr = [[NSUserDefaults standardUserDefaults] boolForKey:@"logging-echo-to-stderr"];
(gdb) s
150 NSRecursiveLock *lock = GSLogLock();
(gdb) s
0x0000000802735760 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) info threads
3 Thread 806fb9380 (LWP 100883) 0x000000080273b3cc in __error ()
from /lib/libthr.so.3
* 2 Thread 806e041c0 (LWP 100754) 0x0000000802735760 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) thread 3
[Switching to thread 3 (Thread 806fb9380 (LWP 100883))]#0 0x000000080273b3cc in __error () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function __error,
which has no line number information.
0x0000000802735762 in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_rwlock_trywrlock,
which has no line number information.
0x0000000802734f80 in raise () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function raise,
which has no line number information.
0x0000000802739a80 in pthread_setcancelstate () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_setcancelstate,
which has no line number information.
0x0000000802734f9c in raise () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function raise,
which has no line number information.
0x0000000802735aaa in pthread_rwlock_trywrlock () from /lib/libthr.so.3
(gdb) s
Single stepping until exit from function pthread_rwlock_trywrlock,
which has no line number information.
[New Thread 806e0ae40 (LWP 100408)]
[New Thread 806e04e00 (LWP 101013)]
[New Thread 806e04c40 (LWP 101014)]
[New Thread 806fbfc80 (LWP 101016)]
[New Thread 806fbf900 (LWP 101020)]
[New Thread 806fbee80 (LWP 101041)]
[New Thread 806fbdec0 (LWP 101044)]
[New Thread 806fbf740 (LWP 101052)]
[New Thread 806fbdd00 (LWP 101053)]
[New Thread 806fbfac0 (LWP 101055)]
[New Thread 806fbdb40 (LWP 101056)]
[New Thread 806fbd980 (LWP 101058)]
[Thread 806fb9380 (LWP 100883) exited]
Program exited with code 01.
To my simplistic brain it looks like its something to do with NSRecursiveLock *lock = GSLogLock(); I've compared the OOLogOutput.m and .h from 1.75.3 and 1.75.4 and they're identical. I then decided to find all the files in Core that reference NSRecursiveLock... and they're all identical too.
Does anybody have any other suggestions?