aboutsummaryrefslogtreecommitdiff
path: root/utils/remap.sh
Commit message (Collapse)AuthorAgeFilesLines
* utils/settrans: improve --chroot functionalityJustus Winter2016-02-051-8/+6
| | | | | | | | | | | | | | | | | Add an option '--chroot-chdir' to settrans and make it chdir to this directory before executing the target program. Also, look up the executable in PATH. With these changes we no longer need to use the shell inside the chroot in the convenience scripts, and hence do not require it to be installed inside the chroot. * utils/fakeroot.sh: Simplify using the new option. * utils/remap.sh: Likewise. * utils/settrans.c (OPT_CHROOT_CHDIR): New constant. (options): New option 'chroot-chdir'. (main): Handle new option. Search for target executable in PATH. * utils/fakeauth.c (main): Likewise.
* Fix fakeroot and remap parsing corner casesSamuel Thibault2014-02-251-7/+2
| | | | | | | | | | Fix case when $PWD contains spaces. Pass directly arguments to command, to directly avoid escaping issues. Based on suggestion by Ivan Shmakov <oneingray@gmail.com> * utils/fakeroot.sh (TARGET): Do not define. (sh): Rather pass PWD and commandline as parameters. * utils/remap.sh: Likewise.
* utils: escape arguments in remap.shJustus Winter2013-08-251-1/+7
| | | | | | | | | | | | | | | | remap.sh uses /bin/sh to first change the working directory and then execute the given program in the remap context. But the arguments given on the command line were not properly escaped: % '/bin/sh' '-c' 'echo $0' /bin/sh % remap '/bin/sh' '-c' 'echo $0' <empty line> % remap-fixed '/bin/sh' '-c' 'echo $0' /bin/sh * utils/remap.sh: Escape arguments handed to /bin/sh so that they are not evaluated prematurely.
* Fix remap invocationSamuel Thibault2013-03-261-2/+4
| | | | | | * utils/remap.sh (REMAPPED): Default to empty. (while): Break as soon as there are no arguments any more. Do not break on mapping parameters
* Add remap translatorSamuel Thibault2013-02-261-0/+64
* trans/remap.c: New file. * trans/Makefile (targets): Add remap. (SRCS): Add remap.c. (remap): Add rule. * utils/remap.sh: New script. * utils/Makefile (targets): Add remap. (special-targets): Add remap. (SRCS): Add remap.sh. * NEWS: Advertise new translator