]> git.saurik.com Git - apple/shell_cmds.git/blame - xcodescripts/install-files.sh
shell_cmds-207.11.1.tar.gz
[apple/shell_cmds.git] / xcodescripts / install-files.sh
CommitLineData
1e9ba8f2
A
1#!/bin/sh
2set -e -x
3
4BINDIR="$DSTROOT"/usr/bin
5LIBEXECDIR="$DSTROOT"/usr/libexec
6MANDIR="$DSTROOT"/usr/share/man
7PAMDIR="$DSTROOT"/private/etc/pam.d
8
9ln -f "$BINDIR/hexdump" "$BINDIR/od"
10ln -f "$BINDIR/id" "$BINDIR/groups"
11ln -f "$BINDIR/id" "$BINDIR/whoami"
12ln -f "$BINDIR/w" "$BINDIR/uptime"
13ln -f "$DSTROOT/bin/test" "$DSTROOT/bin/["
14
15install -d -o root -g wheel -m 0755 "$BINDIR"
16install -d -o root -g wheel -m 0755 "$MANDIR"/man1
17install -d -o root -g wheel -m 0755 "$MANDIR"/man8
18
19install -c -o root -g wheel -m 0755 "$SRCROOT"/alias/generic.sh "$BINDIR"/alias
20install -c -o root -g wheel -m 0644 "$SRCROOT"/alias/builtin.1 "$MANDIR"/man1
21
22set +x
23for builtin in `cat "$SRCROOT/xcodescripts/builtins.txt"`; do
24 echo ... linking $builtin
25 ln -f "$BINDIR"/alias "$BINDIR/$builtin"
26done
27
28for manpage in `cat "$SRCROOT/xcodescripts/builtins-manpages.txt"`; do
29 echo ... linking $manpage
30 echo ".so man1/builtin.1" > "$MANDIR/man1/$manpage"
31done
32set -x
33
34# Skip locate and su targets for iOS
35if [ "$TARGET_NAME" = "All_iOS" ]; then
36 exit 0
37fi
38
39install -d -o root -g wheel -m 0755 "$LIBEXECDIR"
40install -c -o root -g wheel -m 0755 "$SRCROOT"/locate/locate/updatedb.sh \
41 "$LIBEXECDIR"/locate.updatedb
42install -c -o root -g wheel -m 0644 "$SRCROOT"/locate/locate/locate.updatedb.8 \
43 "$MANDIR"/man8
44install -c -o root -g wheel -m 0755 "$SRCROOT"/locate/locate/concatdb.sh \
45 "$LIBEXECDIR"/locate.concatdb
46echo ".so man8/locate.updatedb.8" > "$MANDIR"/man8/locate.concatdb.8
47install -c -o root -g wheel -m 0755 "$SRCROOT"/locate/locate/mklocatedb.sh \
48 "$LIBEXECDIR"/locate.mklocatedb
49echo ".so man8/locate.updatedb.8" > "$MANDIR"/man8/locate.mklocatedb.8
50
51install -d -o root -g wheel -m 0755 "$PAMDIR"
52install -c -o root -g wheel -m 0644 "$SRCROOT"/su/su.pam "$PAMDIR"/su
deb63bfb
A
53
54install -d -o root -g wheel -m 0755 "$DSTROOT"/AppleInternal/Tests/shell_cmds
55install -o root -g wheel -m 0644 "$SRCROOT"/tests/regress.m4 "$DSTROOT"/AppleInternal/Tests/shell_cmds
56
57install -d -o root -g wheel -m 0755 "$DSTROOT"/AppleInternal/CoreOS/BATS/unit_tests
58install -o root -g wheel -m 0644 "$SRCROOT"/tests/shell_cmds.plist "$DSTROOT"/AppleInternal/CoreOS/BATS/unit_tests