#770950 fakeroot: option -l : export the name of the library in an environment variable

Package:
fakeroot
Source:
fakeroot
Description:
tool for simulating superuser privileges
Submitter:
jhcha54008
Date:
2014-11-26 05:12:33 UTC
Severity:
wishlist
#770950#5
Date:
2014-11-25 14:31:43 UTC
From:
To:
Dear Maintainer,

It may be useful to export the argument of option -l,--lib in an
environment variable (see the patch below).

Regards,
JH Chatenet

diff -Naur a/usr/bin/fakeroot-sysv b/usr/bin/fakeroot-sysv
--- a/usr/bin/fakeroot-sysv	2014-11-17 23:21:53.000000000 +0100
+++ b/usr/bin/fakeroot-sysv	2014-11-17 23:25:26.000000000 +0100
@@ -68,6 +68,8 @@
     -l|--lib)
        shift
        LIB=`eval echo "$1"`
+       FAKEROOT_ALT_LIB="$LIB"
+       export FAKEROOT_ALT_LIB
        PATHS=
        ;;
     -f|--faked)

#770950#10
Date:
2014-11-25 13:34:38 UTC
From:
To:
Any particular reason why?
#770950#15
Date:
2014-11-25 22:38:12 UTC
From:
To:
Le mardi 25 novembre à 13h 34mn 38s (+0000), Clint Adams a écrit :
(and LD_PRELOAD) to discover that fakeroot and fakechroot were called
in the wrong order - and possibly correct it.

From fakechroot manpage :
"It is important to start fake environment in proper
 order. fakeroot should be started inside fakechroot"

However, it is sometimes convenient to use the other order (e.g. debirf).
One may reorder LD_LIBRARY_PATH so that libfakeroot leads. (But the name of
the fakeroot wrapper library is needed. It may be anything if option --lib
is in use)

Regards,
JH Chatenet

#770950#20
Date:
2014-11-26 05:11:36 UTC
From:
To:
Gotcha.  This seems reasonable.