Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Fresh install - issues with missing GNUstep/Library

4 views
Skip to first unread message

Riccardo Mottola

unread,
Jun 16, 2020, 6:45:04 AM6/16/20
to Discussion list for the GNUstep programming environment
Hi,

I did a total fresh install of GNUstep (had to reinstall everything on
my Raspberry).
For simplicity I used xlib, I only need a minimal GUI.

I get this trace when starting ProjectCenter:

pi@RaspberryPI1 ~/code/apps-projectcenter $ ProjectCenter
2020-06-16 09:00:46.810 ProjectCenter[28356:28356] styleoffsets ...
guessing offsets
2020-06-16 09:00:46.829 ProjectCenter[28356:28356] styleoffsets ...
guessing offsets
2020-06-16 09:00:46.974 ProjectCenter[28356:28356] Unsupported context
depth 24
2020-06-16 09:00:47.413 ProjectCenter[28356:28356] Library directory
'/home/pi/GNUstep/Library' not available!
2020-06-16 09:00:47.416 ProjectCenter[28356:28356] File NSData.m: 287.
In readContentsOfFile Open ((null)) attempt failed - bad path
2020-06-16 09:00:47.418 ProjectCenter[28356:28356] No font cache
available - building new one - this may take several seconds (or minutes
on a slow machine with lots of fonts)
2020-06-16 09:00:47.422 ProjectCenter[28356:28356] Running
/GNUstep/System/Tools/font_cacher
ProjectCenter: Uncaught exception NSInvalidArgumentException, reason:
Tried to init array with nil object


I think the depth24 context is not relevant (although, Fred... nothing
strange in this setup, the display is exported)

I think the whole failure is that the user has no gnustep preference
directory.
usually no font_cacher is run either, xlib only and perhaps only on
remote display?

Maybe it fails because *both* GNUstep and GNUstep/Library have to be
created (whole path).

I suppose it should be created automatically?
I created manually GNUstep/Library and font cacher started withoutissuesl.

Riccardo

Fred Kiefer

unread,
Jun 17, 2020, 1:15:22 PM6/17/20
to Discussion list for the GNUstep programming environment
In font_cache we have this code:


paths = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory,
NSUserDomainMask, YES);
if ((paths != nil) && ([paths count] > 0))
{
path = [paths objectAtIndex: 0];
}
else
{
NSLog(@" No valid path for cached information exists. You ");
NSLog(@" should create ~/GNUstep/Library by hand");
return nil;
}

This makes it unlikely that the failure was in font_cache. More likely other code in the library tried to access this directory. A stacktrace of the exception would have helped.

Fred

Riccardo Mottola

unread,
Jun 18, 2020, 4:21:20 AM6/18/20
to Discussion list for the GNUstep programming environment
Hi,

Fred Kiefer wrote:
>> Maybe it fails because*both* GNUstep and GNUstep/Library have to be created (whole path).
>>
>> I suppose it should be created automatically?
>> I created manually GNUstep/Library and font cacher started withoutissuesl.
>>
>> Riccardo
>>
>
> In font_cache we have this code:
>
>
> paths = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory,
> NSUserDomainMask, YES);
> if ((paths != nil) && ([paths count] > 0))
> {
> path = [paths objectAtIndex: 0];
> }
> else
> {
> NSLog(@" No valid path for cached information exists. You ");
> NSLog(@" should create ~/GNUstep/Library by hand");
> return nil;
> }
>
> This makes it unlikely that the failure was in font_cache. More likely other code in the library tried to access this directory. A stacktrace of the exception would have helped.


Actually the issue is exactly there. I was confused, because there is a
"twin" code in XGFontManager, but font_cacher gets run first.

Essentially your warnings about creating it never exectues.
NSSearchPathForDirectoriesInDomains returns the paths even if they do
not exist.
I added some code to extra-check, create it (and recheck if it fails...
just in case).

It is good to be kind to new users.

Riccardo

0 new messages