[_pbs] use hardcoded @GNUSTEP_INSTALL_PREFIX only for

non-GNUstep foundation library.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@11599 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
FredKiefer 2001-12-02 11:44:34 +00:00
parent 2cf38b74c4
commit 26d29992fe

View file

@ -41,6 +41,7 @@
#include <Foundation/NSNotification.h>
#include <Foundation/NSException.h>
#include <Foundation/NSLock.h>
#include <Foundation/NSPathUtilities.h>
#include <Foundation/NSPortNameServer.h>
#include <Foundation/NSProcessInfo.h>
#include <Foundation/NSSerialization.h>
@ -52,9 +53,6 @@
#include <gnustep/gui/GSPasteboardServer.h>
#define stringify_it(X) #X
#define prog_path(X) stringify_it(X) "/Tools/gpbs"
@interface NSPasteboard (Private)
+ (id<GSPasteboardSvr>) _pbs;
+ (NSPasteboard*) _pasteboardWithTarget: (id<GSPasteboardObj>)aTarget
@ -143,8 +141,17 @@ static NSMapTable *mimeMap = NULL;
static NSString *cmd = nil;
if (cmd == nil)
cmd = [NSString stringWithCString:
prog_path(GNUSTEP_INSTALL_PREFIX)];
{
#ifdef GNUSTEP_BASE_LIBRARY
cmd = RETAIN([[NSSearchPathForDirectoriesInDomains(
GSToolsDirectory, NSSystemDomainMask, YES) objectAtIndex: 0]
stringByAppendingPathComponent: @"gpbs"]);
#else
cmd = RETAIN([[@GNUSTEP_INSTALL_PREFIX
stringByAppendingPathComponent: @"Tools"]
stringByAppendingPathComponent: @"gpbs"]);
#endif
}
[NSTask launchedTaskWithLaunchPath: cmd arguments: nil];
[NSTimer scheduledTimerWithTimeInterval: 5.0
invocation: nil