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