[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GNUstep.sh / env sanity patches

From: Nicola Pero
Subject: Re: GNUstep.sh / env sanity patches
Date: Thu, 19 Aug 2004 17:27:07 +0100 (BST)

> > I was saying that it's not possible to rely on relative paths to 
> > locate resources ... since people can install applications wherever 
> > they want, the resources those applications need won't be in fixed 
> > locations relative to the applications.
> While this is correct for system provided resources, it isn't true for 
> resources bundled with the (set of) application(s).
> Enabling drag & drop installation of applications is a great user 
> benefit, IMHO. This requires putting resources into some sort of bundle 
> together with the application. Apple uses this 
> "@executable_path/path/to/resource" hack to achieve this goal.
> So, GNUstep should have some equivalent, perhaps better designed, 
> functionality. The developer should be free in the choice wether to use 
> absolute or relative paths when locating resources.
> Another idea whould be to include the application/framework/whatever 
> bundle into the standard search path. An application whould have to set 
> an individual LD_LIBRARY_PATH at launch time, then.

We already have a script which does sort of that.

To have very easy drop-in of libraries and frameworks into application
bundles, we probably mostly need to ... choose a location inside the
application bundle where you are supposed to drop your libraries (and/or
symlinks to your frameworks).

I can then change openapp/the application wrapper script to automatically
add that directory to LD_LIBRARY_PATH before running the application.

So if you have an application, you link it against library XX, then you
want to bundle library XX with the application, you'd only have to drop it
into the application bundle in the special location/directory we choose
for bundled libraries.

Would that be a good idea ?


Presumably that could be extended so that if our workspace
manager/gnustep-* can execute applications and it doesn't go through the
application wrapper script, it might be possible to modify them to do the
same and add our drop-in library directory to the LD_LIBRARY_PATH used
when running the application.

Another option would be, on certain platforms, when possible, to hardcode
a (relative) hint to that directory for the linker in the executable, Then
you don't need any LD_LIBRARY_PATH setting.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]