4 * Copyright (c) Tuomo Valkonen 1999-2007.
6 * You may distribute and modify this library under the terms of either
7 * the Clarified Artistic License or the GNU LGPL, version 2.1 or later.
15 static char *the_prefix
=NULL
;
17 void prefix_set(const char *binloc
, const char *dflt
)
23 die(TR("This relocatable binary should be started with an absolute path."));
26 if(binloc
[i
-1]!=dflt
[j
-1])
32 the_prefix
=scopyn(binloc
, i
);
37 char *prefix_add(const char *s
)
42 return scat3(the_prefix
, "/", s
);
46 bool prefix_wrap_simple(bool (*fn
)(const char *s
), const char *s
)
53 char *s2
=prefix_add(s
);