Skip to content
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

GWorkspace dies on start up on Ubuntu 24.04 after fresh GNUstep install with the following exception #37

Closed
IOOI-SqAR opened this issue Oct 12, 2024 · 15 comments
Assignees

Comments

@IOOI-SqAR
Copy link

[Detaching after fork from child process 107719]
2024-10-13 00:06:43.176 fswatcher[107719:107719] register client 2
2024-10-13 00:06:43.351 GWorkspace[107713:107713] no WS icon for /home/lars/.Trash

Breakpoint 1, -[NSException raise] (self=0x5555570896a8, 
    _cmd=0x7ffff7609e38 <objc_selector_raise_v160:8>) at NSException.m:1599
1599	  if (_reserved == 0)

(gdb) up

#1  0x00007ffff719fc00 in -[GSMutableDictionary setObject:forKey:] (
    self=0x55555707edc8, 
    _cmd=0x7ffff7fb8468 <.objc_selector_setObject:forKey:_v320:81624>, 
    anObject=0x0, aKey=0x181) at GSDictionary.m:440
440	      [e raise];
(gdb) up

#2  0x00007ffff7f739d9 in -[FSNodeRep(Icons) cachedIconOfSize:forKey:addBaseIcon:] (self=0x555556e63228, _cmd=<optimized out>, size=48, key=0x555556efd998, 
    baseIcon=0x0) at FSNodeRepIcons.m:323
323	  [dict setObject: baseIcon forKey: [NSNumber numberWithInt: basesize]];
(gdb) list

318	  
319	  if ((icnsize.width > basesize) || (icnsize.height > basesize)) {
320	    baseIcon = [self resizedIcon: baseIcon ofSize: basesize];
321	  }  
322	
323	  [dict setObject: baseIcon forKey: [NSNumber numberWithInt: basesize]];
324	  [iconsCache setObject: dict forKey: key];
325	  
326	  return [self cachedIconOfSize: size forKey: key];
327	}
(gdb) po baseIcon

Cannot access memory at address 0x0
(gdb) bt

#0  -[NSException raise] (self=0x5555570896a8, 
    _cmd=0x7ffff7609e38 <objc_selector_raise_v160:8>) at NSException.m:1599
#1  0x00007ffff719fc00 in -[GSMutableDictionary setObject:forKey:] (
    self=0x55555707edc8, 
    _cmd=0x7ffff7fb8468 <.objc_selector_setObject:forKey:_v320:81624>, 
    anObject=0x0, aKey=0x181) at GSDictionary.m:440
#2  0x00007ffff7f739d9 in -[FSNodeRep(Icons) cachedIconOfSize:forKey:addBaseIcon:] (self=0x555556e63228, _cmd=<optimized out>, size=48, key=0x555556efd998, 
    baseIcon=0x0) at FSNodeRepIcons.m:323
#3  0x00007ffff7f7379f in -[FSNodeRep(Icons) iconOfSize:forNode:] (
    self=0x555556e63228, _cmd=<optimized out>, size=48, node=<optimized out>)
    at FSNodeRepIcons.m:185
#4  0x00007ffff7f83f81 in -[FSNIcon initForNode:nodeInfoType:extendedType:iconSize:iconPosition:labelFont:textColor:gridIndex:dndSource:acceptDnd:slideBack:] (
    self=0x555557050248, _cmd=<optimized out>, anode=<optimized out>, 
    type=FSNInfoNameType, exttype=0x0, isize=<optimized out>, ipos=1, 
    lfont=0x5555563d2dc8, tcolor=0x555555eefa68, gindex=0, dndsrc=0 '\000', 
    dndaccept=0 '\000', slback=0 '\000') at FSNIcon.m:197
#5  0x00005555555c4811 in -[DockIcon initForNode:appName:iconSize:] (
    self=0x555557050248, _cmd=<optimized out>, anode=0x55555704fe48, 
    aname=<optimized out>, isize=48) at Desktop/Dock/DockIcon.m:55
#6  0x00005555555c17e6 in -[Dock createTrashIcon] (self=0x555557004698, 
    _cmd=<optimized out>) at Desktop/Dock/Dock.m:169
--Type <RET> for more, q to quit, c to continue without paging--

#7  0x00005555555c1609 in -[Dock initForManager:] (self=0x555557004698, 
    _cmd=<optimized out>, mngr=<optimized out>) at Desktop/Dock/Dock.m:133
#8  0x00005555555b7b08 in -[GWDesktopManager init] (self=0x555556fcd7d8, 
    _cmd=<optimized out>) at Desktop/GWDesktopManager.m:117
#9  0x00007ffff7ed8abc in objc_alloc_init ()
   from /usr/GNUstep/System/Library/Libraries/libobjc.so.4.6
#10 0x00005555555b76cd in +[GWDesktopManager desktopManager] (
    self=<optimized out>, _cmd=<optimized out>)
    at Desktop/GWDesktopManager.m:48
#11 0x00005555555ab793 in -[GWorkspace applicationWillFinishLaunching:] (
    self=0x555555aa85a8, _cmd=<optimized out>, aNotification=<optimized out>)
    at GWorkspace.m:454
#12 0x00007ffff72cc33b in -[NSObject performSelector:withObject:] (
    self=0x555555aa85a8, 
    _cmd=0x7ffff7609f48 <.objc_selector_performSelector:withObject:_320:8:1624>, 
    aSelector=0x7ffff7e29bf8 <.objc_selector_applicationWillFinishLaunching:_>, 
    anObject=0x555555b54ec8) at NSObject.m:1993
#13 0x00007ffff72bc404 in -[NSNotificationCenter _postAndRelease:] (
    self=0x5555559a4238, 
    _cmd=0x7ffff76131d8 <.objc_selector__postAndRelease:_v240:816>, 
    notification=0x555555b54ec8) at NSNotificationCenter.m:1220
#14 0x00007ffff72bca3f in -[NSNotificationCenter postNotificationName:object:use--Type <RET> for more, q to quit, c to continue without paging--

rInfo:] (self=0x5555559a4238, 
    _cmd=0x7ffff760a6f8 <.objc_selector_postNotificationName:object:userInfo:_v400:8162432>, 
    name=0x7ffff7e58898 <.objc_str_NSApplicationWillFinishLaunchingNotification>, object=0x555555b4d538, info=0x0) at NSNotificationCenter.m:1295
#15 0x00007ffff72bc965 in -[NSNotificationCenter postNotificationName:object:]
    (self=0x5555559a4238, 
    _cmd=0x7ffff7e293b8 <.objc_selector_postNotificationName:object:_v320:81624>, 
    name=0x7ffff7e58898 <.objc_str_NSApplicationWillFinishLaunchingNotification>, object=0x555555b4d538) at NSNotificationCenter.m:1275
#16 0x00007ffff7a1d36e in -[NSApplication finishLaunching] (
    self=0x555555b4d538, 
    _cmd=0x7ffff7e29688 <.objc_selector_finishLaunching_v160:8>)
    at NSApplication.m:1018
#17 0x00007ffff7a1eb9e in -[NSApplication run] (self=0x555555b4d538, 
    _cmd=0x55555563bf40 <objc_selector_run_v160:8>) at NSApplication.m:1564
#18 0x00005555555a8491 in main (argc=<optimized out>, argv=<optimized out>, 
    env=<optimized out>) at main.m:38
(gdb) 
@rmottola
Copy link
Member

@IOOI-SqAR please tell more about "fresh gnustep install". All GNUstep and GWorkspace built from sources? releases or GIT versions? any peculiar configurations? themes?

What configure options for gworkspace? metadata?

I even recently did a complete fresh install on Devuan and had no issues. Apparently there is an issue getting an icon or something goes wrong on resize. I'll have a look a the code.

@IOOI-SqAR
Copy link
Author

Hi Riccardo!

Fresh install means I used just curl https://raw.githubusercontent.com/gnustep/tools-scripts/master/gnustep-web-install-dev | bash from our homepage. So to say I was dogfooding our own stuff to install GNUstep. No special configuration. This script checks out the current master of all our repos and builds it using ng-gnu-gnu. Then I did:

cd apps-gworkspace/
./configure
sudo -E make install

so nothing special. Everything should be set to its default settings, current source from HEAD.

HTH,

Lars

@rmottola
Copy link
Member

@IOOI-SqAR Lars, obviosuly I do not get this error. Checking the code, it appears to get an icon both from the cache as from NSWorkspace. You get an interesting warning for "/home/lars/.Trash"
Do you have enabled the display of hidden files and dirs?

Please update, I made the code more robust and the debugging more helpful.
It will perhaps not crash, but the debug output should still come out.
Then, please put a breakpoint (or walk the stack up) to the NSLog, FSNodeRepIcons.m:174 and there print out "ws". I want to see if the shared NSWorkspace is correctly initialised or not. It being nil could explain not getting the icon.

@rmottola
Copy link
Member

Sorry, I had a partial commit, so build broke.. either you revert it as a test or directly update, where I make sure to get always NSWorkspace without caching it on an IVAR.

@IOOI-SqAR
Copy link
Author

Hi Riccardo

@IOOI-SqAR Lars, obviosuly I do not get this error. Checking the code, it appears to get an icon both from the cache as from NSWorkspace. You get an interesting warning for "/home/lars/.Trash" Do you have enabled the display of hidden files and dirs?

Not that I am aware of. I couldn't get to the point where I can set such things (Assuming it is a GWorkspace setting).

Please update, I made the code more robust and the debugging more helpful. It will perhaps not crash, but the debug output should still come out. Then, please put a breakpoint (or walk the stack up) to the NSLog, FSNodeRepIcons.m:174 and there print out "ws". I want to see if the shared NSWorkspace is correctly initialised or not. It being nil could explain not getting the icon.

Currently I no longer get the crash. However, GWorkspace is in some strange state:

lars@Ubuntu-2404-VirtualBox:~$ GWorkspace 
2024-10-15 03:10:25.675 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.681 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.682 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.966 fswatcher[2763:2763] register client 2
2024-10-15 03:10:26.029 GWorkspace[2671:2671] no icon in cache for key /home/lars/.Trash and no WS icon for /home/lars/.Trash
2024-10-15 03:10:26.029 GWorkspace[2671:2671] Warning: No icon found for /home/lars/.Trash
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.531 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Failed to load Gorm
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.811 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Failed to load Gorm
2024-10-15 03:10:26.815 GWorkspace[2671:2671] Preferences: failed to load PrefWindow!
2024-10-15 03:10:27.386 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:27.389 GWorkspace[2671:2671] Problem posting <GSNotification: 0x5ff17ac7a968> Name: NSApplicationWillFinishLaunchingNotification Object: <NSApplication: 0x5ff17acb0588> Info: (null): <NSException: 0x5ff17cfd3a38> NAME:NSInvalidArgumentException REASON:Tried to add nil value for key 'HomeDirectory' to dictionary INFO:{}
2024-10-15 03:10:28.035 GWorkspace[2671:2671] Unable to obtain lock (null)
2024-10-15 03:13:46.348 GWorkspace[2671:2671] no image found for HomeDirectory

VirtualBox_Ubuntu 24 04_15_10_2024_03_15_43

@IOOI-SqAR
Copy link
Author

Please update, I made the code more robust and the debugging more helpful. It will perhaps not crash, but the debug output should still come out. Then, please put a breakpoint (or walk the stack up) to the NSLog, FSNodeRepIcons.m:174 and there print out "ws". I want to see if the shared NSWorkspace is correctly initialised or not. It being nil could explain not getting the icon.

Riccardo, here you go:

2024-10-15 03:34:23.697 GWorkspace[2861:2861] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:34:23.699 GWorkspace[2861:2861] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:34:23.700 GWorkspace[2861:2861] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
[Detaching after fork from child process 2867]
2024-10-15 03:34:23.956 fswatcher[2867:2867] register client 2

Breakpoint 1, -[FSNodeRep(Icons) iconOfSize:forNode:] (self=0x555556e81648, 
    _cmd=<optimized out>, size=48, node=0x555557067cb8) at FSNodeRepIcons.m:174
174	                  NSLog(@"no icon in cache for key %@ and no WS icon for %@", key, nodepath);
(gdb) po ws
No symbol "ws" in current context.

@rmottola
Copy link
Member

Breakpoint 1, -[FSNodeRep(Icons) iconOfSize:forNode:] (self=0x555556e81648,
_cmd=, size=48, node=0x555557067cb8) at FSNodeRepIcons.m:174
174 NSLog(@"no icon in cache for key %@ and no WS icon for %@", key, nodepath);
(gdb) po ws
No symbol "ws" in current context.

Indeed, there isn't the symbol anymore, I made the code more dynamic, but safer. Maybe a tad slower, but no init problems anymore.

@rmottola
Copy link
Member

Hi Riccardo

@IOOI-SqAR Lars, obviosuly I do not get this error. Checking the code, it appears to get an icon both from the cache as from NSWorkspace. You get an interesting warning for "/home/lars/.Trash" Do you have enabled the display of hidden files and dirs?

Not that I am aware of. I couldn't get to the point where I can set such things (Assuming it is a GWorkspace setting).

There is a global setting, I don't remember the name, I set it with SystemPreferences (should affect file panels too)

Currently I no longer get the crash. However, GWorkspace is in some strange state:

lars@Ubuntu-2404-VirtualBox:~$ GWorkspace 
2024-10-15 03:10:25.675 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.681 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.682 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.966 fswatcher[2763:2763] register client 2
2024-10-15 03:10:26.029 GWorkspace[2671:2671] no icon in cache for key /home/lars/.Trash and no WS icon for /home/lars/.Trash
2024-10-15 03:10:26.029 GWorkspace[2671:2671] Warning: No icon found for /home/lars/.Trash
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.531 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Failed to load Gorm
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.811 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Failed to load Gorm
2024-10-15 03:10:26.815 GWorkspace[2671:2671] Preferences: failed to load PrefWindow!
2024-10-15 03:10:27.386 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:27.389 GWorkspace[2671:2671] Problem posting <GSNotification: 0x5ff17ac7a968> Name: NSApplicationWillFinishLaunchingNotification Object: <NSApplication: 0x5ff17acb0588> Info: (null): <NSException: 0x5ff17cfd3a38> NAME:NSInvalidArgumentException REASON:Tried to add nil value for key 'HomeDirectory' to dictionary INFO:{}
2024-10-15 03:10:28.035 GWorkspace[2671:2671] Unable to obtain lock (null)
2024-10-15 03:13:46.348 GWorkspace[2671:2671] no image found for HomeDirectory

This is not a specific GWorkspace issue, but I think a build issue.

I think you have a build/version mismatch. This usually happens with an unclean build (mix of library version) or mix of compiler versions, runtimes... maybe you hacked and brought things this way or there is an issue with the script you are using.
Uninstall, clean, reconfigure, build base, gui, back, GWorkspace and see. If you installed PDFKit do that too.

Try other apps if they work?

@IOOI-SqAR
Copy link
Author

Hi Riccardo

@IOOI-SqAR Lars, obviosuly I do not get this error. Checking the code, it appears to get an icon both from the cache as from NSWorkspace. You get an interesting warning for "/home/lars/.Trash" Do you have enabled the display of hidden files and dirs?

Not that I am aware of. I couldn't get to the point where I can set such things (Assuming it is a GWorkspace setting).

There is a global setting, I don't remember the name, I set it with SystemPreferences (should affect file panels too)

Currently I no longer get the crash. However, GWorkspace is in some strange state:

lars@Ubuntu-2404-VirtualBox:~$ GWorkspace 
2024-10-15 03:10:25.675 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.681 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.682 GWorkspace[2671:2671] File NSData.m: 279. In BOOL readContentsOfFile(NSString *, void **, off_t *, NSZone *) Open ((null)) attempt failed - bad path
2024-10-15 03:10:25.966 fswatcher[2763:2763] register client 2
2024-10-15 03:10:26.029 GWorkspace[2671:2671] no icon in cache for key /home/lars/.Trash and no WS icon for /home/lars/.Trash
2024-10-15 03:10:26.029 GWorkspace[2671:2671] Warning: No icon found for /home/lars/.Trash
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.531 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.541 GWorkspace[2671:2671] Failed to load Gorm
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 03:10:26.811 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Exception occurred while loading model: Tried to add nil value for key 'HomeDirectory' to dictionary
2024-10-15 03:10:26.814 GWorkspace[2671:2671] Failed to load Gorm
2024-10-15 03:10:26.815 GWorkspace[2671:2671] Preferences: failed to load PrefWindow!
2024-10-15 03:10:27.386 GWorkspace[2671:2671] no image found for HomeDirectory
2024-10-15 03:10:27.389 GWorkspace[2671:2671] Problem posting <GSNotification: 0x5ff17ac7a968> Name: NSApplicationWillFinishLaunchingNotification Object: <NSApplication: 0x5ff17acb0588> Info: (null): <NSException: 0x5ff17cfd3a38> NAME:NSInvalidArgumentException REASON:Tried to add nil value for key 'HomeDirectory' to dictionary INFO:{}
2024-10-15 03:10:28.035 GWorkspace[2671:2671] Unable to obtain lock (null)
2024-10-15 03:13:46.348 GWorkspace[2671:2671] no image found for HomeDirectory

This is not a specific GWorkspace issue, but I think a build issue.

I think you have a build/version mismatch. This usually happens with an unclean build (mix of library version) or mix of compiler versions, runtimes... maybe you hacked and brought things this way or there is an issue with the script you are using. Uninstall, clean, reconfigure, build base, gui, back, GWorkspace and see. If you installed PDFKit do that too.

Try other apps if they work?

Hi Riccardo,

it could well be, that I have a somewhat broken GNUstep install, although I did nothing special here: Gorm also has issues:

lars@Ubuntu-2404-VirtualBox:~/GNUstep-shared/gnustep/apps-gorm$ Gorm 
2024-10-15 10:31:28.243 Gorm[4914:4914] Warning: [NSBundle+bundleForClass:] unable to determine version of library '/usr/GNUstep/System/Library/Libraries/libgnustep-gui.so.0' containing 'NSApplication' for executable '/usr/GNUstep/Local/Applications/Gorm.app/Gorm'
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 10:31:36.713 Gorm[4914:4914] ClassInformation.plist missing from resources

What did I do to install GNUstep? Not much, just did a fresh install of Ubuntu 24.04 from ubuntu-24.04.1-desktop-amd64.iso into VirtualBox, then installed manually some dependencies for the VirtualBox Guest Additions and curl as well as git, set up the GitHub ssh-key stuff, enabled the root user (setting the root user password since root is usually not enabled in Ubuntu) and created a shared folder between my Host (macOS 14.7 Sonoma) and the Ubuntu VM. Finally I installed GNUstep using the script from our homepage, nothing special, no hackery:

# go to https://ubuntu.com/download/desktop and download ubuntu-24.04.1-desktop-amd64.iso

# Set up the VM in Vbox

# Install tools to enable Guest Additions Install:

sudo apt-get update
sudo apt-get install bzip2
sudo apt-get install gcc
sudo apt-get install make
sudo apt-get install perl

# Run autorun.sh from Guest Additions CD image

# needed for running gnustep-web-install-dev from web
sudo apt-get install curl
sudo apt-get install git

# needed for github access
cd ~/.ssh
touch id_rsa
vi id_rsa 
# paste the private github key, save and exit

touch id_rsa.pub
vi id_rsa.pub
# paste the public github key, save and exit

chmod 600 ~/.ssh/*

ssh-add ~/.ssh/id_rsa

# set root user password. Currently needed for gnustep-web-install-dev
sudo su -c passwd

# optional: install ntp to avoid clock skew
sudo apt-get install ntp

# optional: create shared folder between host and guest (GNUstep-shared)
sudo adduser lars vboxsf
sudo chmod 755 GNUstep-shared
cd ~/GNUstep-shared/

# finally install GNUstep
curl https://raw.githubusercontent.com/gnustep/tools-scripts/master/gnustep-web-install-dev | bash

imho the script from our homepage should better work, since it is prominently presented at our homepage and maybe the first contact with GNUstep for some users which might be all new to GNUstep and might have no experience to fix occurring problems.

Kind regards!

@rmottola
Copy link
Member

Hi Lars,

lars@Ubuntu-2404-VirtualBox:~/GNUstep-shared/gnustep/apps-gorm$ Gorm 
2024-10-15 10:31:28.243 Gorm[4914:4914] Warning: [NSBundle+bundleForClass:] unable to determine version of library '/usr/GNUstep/System/Library/Libraries/libgnustep-gui.so.0' containing 'NSApplication' for executable '/usr/GNUstep/Local/Applications/Gorm.app/Gorm'
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 10:31:36.713 Gorm[4914:4914] ClassInformation.plist missing from resources

This is somehow the "proof" that your installation is not working. What you see is not a GWorkspace issue, but an issue of your install.
I'll keep this bug open for a while, if you are able to sort out this issue and retest.

imho the script from our homepage should better work, since it is prominently presented at our homepage and maybe the first contact with GNUstep for some users which might be all new to GNUstep and might have no experience to fix occurring problems.

I would not put it that prominent, but other wanted it. I never trust scripts and do everything manually since 20 years, it is not hat hard and I can verify each step.
I think it is better to open a different bug or ask on the mailing list until you get apps working, then get back to GWorkspace.
Have you tried wiping out and start over?
If you have the patience on the same VM to setup things manually, you could try redoing everything yourself (you just need the 4 core packages to test Gorm and GWorkspace) or even try the GCC runtime. This would test if there is something peculiar in your installation. I see the scripts have gcc vs clang, you could try that although I don't know how to do that. Please open a bug there.

@IOOI-SqAR
Copy link
Author

Hi Lars,

lars@Ubuntu-2404-VirtualBox:~/GNUstep-shared/gnustep/apps-gorm$ Gorm 
2024-10-15 10:31:28.243 Gorm[4914:4914] Warning: [NSBundle+bundleForClass:] unable to determine version of library '/usr/GNUstep/System/Library/Libraries/libgnustep-gui.so.0' containing 'NSApplication' for executable '/usr/GNUstep/Local/Applications/Gorm.app/Gorm'
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSFormCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
Calling [NSButtonCell -state] with incorrect signature.  Method has q16@0:8 (q16@0:8), selector has Q16@0:8
2024-10-15 10:31:36.713 Gorm[4914:4914] ClassInformation.plist missing from resources

This is somehow the "proof" that your installation is not working. What you see is not a GWorkspace issue, but an issue of your install. I'll keep this bug open for a while, if you are able to sort out this issue and retest.

o.k. thanks for that.

imho the script from our homepage should better work, since it is prominently presented at our homepage and maybe the first contact with GNUstep for some users which might be all new to GNUstep and might have no experience to fix occurring problems.

I would not put it that prominent, but other wanted it. I never trust scripts and do everything manually since 20 years, it is not hat hard and I can verify each step.

Well, it's not hard for you since you know the installation process like the back of your hand. But others who aren't GNUstep developers now might find this process somewhat complicated. To widen the audience of GNUstep we need such scripts IMHO.

I think it is better to open a different bug or ask on the mailing list until you get apps working, then get back to GWorkspace. Have you tried wiping out and start over?

Well, of course! One of the reasons I am doing this in a Virtual Box VM is, that I easily can go back to old snapshots.

If you have the patience on the same VM to setup things manually, you could try redoing everything yourself (you just need the 4 core packages to test Gorm and GWorkspace) or even try the GCC runtime. This would test if there is something peculiar in your installation. I see the scripts have gcc vs clang, you could try that although I don't know how to do that. Please open a bug there.

Done:

gnustep/tools-scripts#18
gnustep/tools-scripts#19
gnustep/tools-scripts#20
gnustep/tools-scripts#21

Kind regards,

Lars

@rmottola
Copy link
Member

@IOOI-SqAR did you do further work on this? did you attempt to rebuild a whole environment on your setup with the GCC runtime? We need to do some differential analysis here.

@rmottola
Copy link
Member

I am tempted to close this. I successfully compile GWorkspace on Clang/libobjc2 and gcc runtimes on different architectures. I believe the issue is in your scripts and setups for which have separate issues.

@IOOI-SqAR
Copy link
Author

@rmottola Cause for this was a broken GNUstep installation, Moral of the story: Never check out GNUstep sources to a Virtual Box shared folder.

You can close this now, Thanks again for your help in the cause!

Lars

@rmottola
Copy link
Member

Fine! we found other stuff in the trip, always good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants