Gentoo Archives: gentoo-dev

From: George Shapovalov <georges@×××××××××××.edu>
To: gentoo-dev@g.o
Subject: Re: [gentoo-dev] <foo>-config scripts.
Date: Sat, 13 Apr 2002 15:26:03
Message-Id: 200204131318.08788.georges@its.caltech.edu
In Reply to: Re: [gentoo-dev] -config scripts. by Terje Kvernes
1 On Saturday 13 April 2002 13:06, Terje Kvernes wrote:
2 > George Shapovalov <georges@×××××××××××.edu> writes:
3 > > Just a quick thought:
4 >
5 > the same thing happens. `ggz-config --data` returns
6 > '/usr/share/ggz' whenever it is called. it does _not_ care about
7 > $prefix or DESTDIR or anything at all. :/
8 Too bad :(. However this brings me to the idea. May be it is worth updating
9 sandbox functionality so that not only it catches all such attempts but also
10 (if for example sandbox-redirect is set or something) redirects write attempt
11 to the proper place.
12 The rationale:
13 There will always be outright broken packages which will not honor any
14 redirection flags passed to make or configure.
15 I realize this is not gonna be trivial and will probably not be done in a
16 close future.
17
18 Right now I do not see very clean solution other then to do some sed'ing
19 (to add ${D} to the output of /usr/bin/ggz-config).
20 I do not see Makefile.in or Makefile so I cannot be more specific (and I am
21 not very proficient with sed either), but something along the lines of:
22
23 sed -e "s:`/usr/bin/ggz-config':${D}`/usr/bin/ggz-config`:" Makefile.orig
24 >Makefile
25
26 might work (depending on what ggz-config returns of course).
27 (Actually you will need to check if ${D} is passed to Makefile and then either
28 add ${D} or its value).
29 And I agree that patching is not a very good idea. Using sed seems cleaner to
30 me in this situation.
31
32 George