aboutsummaryrefslogtreecommitdiffstats
path: root/bin/install
blob: 5cb4071748f8bcd1baa1222cc5ecf6865e49c7fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh

. $(dirname $0)/wrapper.sh

saved=""
while getopts dbCcMpSsvB:f:g:m:o:t:D opt; do
    case "$opt" in
        s)
            # Ignore strip argument
            ;;
        B|f|g|m|o|t)
            save "-$opt"
            save "$OPTARG"
            ;;
        D)
            createleading="1"
            ;;
        \?)
            exit 1
            ;;
        *)
            save "-$opt"
            ;;
    esac
done
shift $(($OPTIND - 1))
for arg; do
    save "$arg"
done

if [ $# -eq 2 -a -n "$createleading" ]; then
    install -d $(dirname $2)
fi

exec_real