aboutsummaryrefslogtreecommitdiff
path: root/extra/pax/build
blob: 4c16b29a2e2f1259e15a4581213ed3073ee450c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh -e

sed -i '1i#include <sys/types.h>' pax.h compat.h

TARGET_OS=Linux \
CC="${CC:-cc}" \
CFLAGS="$CFLAGS -DGNU_SOURCE" \
LDFLAGS="$LDFLAGS -static" \
LIBS=-lfts \
    sh ./Build.sh -r

install -Dm755 pax "$1/usr/bin/pax"
ln -sf pax "$1/usr/bin/paxtar"
ln -sf pax "$1/usr/bin/paxcpio"

install -Dm644 pax.1  "$1/usr/share/man/man1/pax.1"
install -Dm644 tar.1  "$1/usr/share/man/man1/paxtar.1"
install -Dm644 cpio.1 "$1/usr/share/man/man1/paxcpio.1"