aboutsummaryrefslogtreecommitdiff
path: root/install.do
diff options
context:
space:
mode:
authormerakor <cem@ckyln.com>2020-12-27 13:51:37 +0000
committermerakor <cem@ckyln.com>2020-12-27 13:51:37 +0000
commit0ffdfa53151ab7844edcff52d361bc9f137c4654 (patch)
tree18359249f76b7c6963dbb529ed87af476a8f0793 /install.do
parent05b0ba223335dfa01eefcd46f0498e6a93517048 (diff)
downloadcpt-0ffdfa53151ab7844edcff52d361bc9f137c4654.tar.gz
tools: add install.sh
FossilOrigin-Name: ba9f9fd3cd76c916c02529ef75189536fe0e3f35e0af65b2c22a268b19878d42
Diffstat (limited to 'install.do')
-rw-r--r--install.do20
1 files changed, 6 insertions, 14 deletions
diff --git a/install.do b/install.do
index ae82131..dcab154 100644
--- a/install.do
+++ b/install.do
@@ -1,25 +1,17 @@
. ./config.rc
redo all
+PHONY
+
+INSTALLSH=./tools/install.sh
# Install executables.
-mkdir -p "${DESTDIR}${BINDIR}"
-getbin | while read -r file; do
- cp "$file" "${DESTDIR}${BINDIR}/${file##*/}"
- chmod 755 "${DESTDIR}${BINDIR}/${file##*/}"
-done
+"$INSTALLSH" -Dm755 -t "$DESTDIR$BINDIR" $(getbin)
# Install manual pages.
-mkdir -p "${DESTDIR}${MAN1}"
-for man in man/*.1; do
- cp "$man" "${DESTDIR}${MAN1}/${man##*/}"
- chmod 644 "${DESTDIR}${MAN1}/${man##*/}"
-done
+"$INSTALLSH" -Dm644 -t "$DESTDIR$MAN1" man/*.1
# Install the documentation info page.
# We don't want to bother if the info page wasn't created, just exit without an
# error.
[ -f docs/cpt.info ] || exit 0
-
-mkdir -p "${DESTDIR}${INFODIR}"
-cp docs/cpt.info "${DESTDIR}${INFODIR}/cpt.info"
-chmod 644 "${DESTDIR}${INFODIR}/cpt.info"
+"$INSTALLSH" -Dm644 docs/cpt.info "$DESTDIR$INFODIR/cpt.info"