install.do: stub /usr/bin programs: be smarter about finding the libdir.
We were hardcoding the absolute $LIBDIR location, which sounds smart, but not if you're doing "make install" into a temp dir that will end up somewhere else later. Instead, look for ../lib/redo/ from wherever the binary is installed.
This commit is contained in:
parent
3dd8d081be
commit
5f9b6eeaf4
1 changed files with 3 additions and 2 deletions
|
|
@ -33,8 +33,9 @@ for d in redo redo-ifchange redo-ifcreate redo-always redo-stamp redo-oob; do
|
||||||
fix=$(echo $d | sed 's,-,_,g')
|
fix=$(echo $d | sed 's,-,_,g')
|
||||||
cat >install.wrapper <<-EOF
|
cat >install.wrapper <<-EOF
|
||||||
#!/usr/bin/python
|
#!/usr/bin/python
|
||||||
import sys;
|
import sys, os;
|
||||||
sys.path.insert(0, '$LIBDIR')
|
exedir = os.path.dirname(os.path.abspath(sys.argv[0]))
|
||||||
|
sys.path.insert(0, os.path.join(exedir, '../lib/redo'))
|
||||||
import $fix
|
import $fix
|
||||||
EOF
|
EOF
|
||||||
$INSTALL -m 0755 install.wrapper $BINDIR/$d
|
$INSTALL -m 0755 install.wrapper $BINDIR/$d
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue