summary refs log tree commit diff
path: root/Makefile
diff options
context:
space:
mode:
authorArun Isaac2023-01-23 00:49:13 +0000
committerArun Isaac2023-01-23 00:49:13 +0000
commite7e13aa0749e408cc80c71f5f2d4e37c9c9ec1ea (patch)
tree6b4d61871fa065acb008a4466469e1ab57e0dfaa /Makefile
parent4411ea8ad6fe12158d871669b217ecc62fd3a535 (diff)
downloadtissue-e7e13aa0749e408cc80c71f5f2d4e37c9c9ec1ea.tar.gz
tissue-e7e13aa0749e408cc80c71f5f2d4e37c9c9ec1ea.tar.lz
tissue-e7e13aa0749e408cc80c71f5f2d4e37c9c9ec1ea.zip
Makefile: Use install instead of cp and mkdir.
The --parents flag of cp is not portable to macOS. Besides, install
correctly replaces destination files when they already exist.

* Makefile (install): Use install instead of cp and mkdir.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 6 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 3e8359b..640e24f 100644
--- a/Makefile
+++ b/Makefile
@@ -54,9 +54,12 @@ check:
 
 install:
 	install -D $(scripts) --target-directory $(bindir)
-	mkdir -p $(scmdir) $(godir)
-	cp --parents -vr $(sources) $(scmdir)
-	cp --parents -vr $(objects) $(godir)
+	for source in $(sources); do \
+		install -D $$source $(scmdir)/$$source; \
+	done
+	for object in $(objects); do \
+		install -D $$object $(godir)/$$object; \
+	done
 
 clean:
 	rm -f $(objects)