3
0
Fork 0
forked from mirrors/nixpkgs

Create wrapper directory outside of /bin/ for FHS chroots to be closer to FHS

This commit is contained in:
Michael Raskin 2014-09-02 01:45:15 +04:00
parent 2a1a814e53
commit 9deb7f8aae

View file

@ -97,9 +97,9 @@ filterExisting() {
wrapProgram() {
local prog="$1"
local progBasename=$(basename $prog)
local hiddenDir=$(dirname $prog)/.$progBasename-wrapped-bin
local hidden=$hiddenDir/$progBasename
mkdir $hiddenDir
local hiddenDir="$(dirname $prog)/../wrapped-bin/.$progBasename-wrapped-bin"
mkdir -p $hiddenDir
local hidden="$(cd "$hiddenDir"; pwd)/$progBasename"
mv $prog $hidden
makeWrapper $hidden $prog "$@"
}