summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@open-infrastructure.net>2023-02-02 13:25:39 +0000
committerDaniel Baumann <daniel.baumann@open-infrastructure.net>2024-08-29 16:19:01 +0000
commitdb8b3d969ab45c7be85488bf73b36e0b04d8869a (patch)
treeea5ccf9b2ed09141d8d5ded4ebbba4198f54477f /Makefile
parentAdding todo file (FIXME). (diff)
downloadcompute-tools-db8b3d969ab45c7be85488bf73b36e0b04d8869a.tar.xz
compute-tools-db8b3d969ab45c7be85488bf73b36e0b04d8869a.zip
Adding initial compute-tools python module.
Signed-off-by: Daniel Baumann <daniel.baumann@open-infrastructure.net>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile18
1 files changed, 18 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index caae1e1..22bb719 100644
--- a/Makefile
+++ b/Makefile
@@ -33,6 +33,10 @@ test:
@echo -n "Checking for syntax errors with sh... "
@for SCRIPT in $(SCRIPTS); \
do \
+ if grep -qs /usr/bin/python3 $${SCRIPT}; \
+ then \
+ continue; \
+ fi; \
sh -n $${SCRIPT}; \
echo -n "."; \
done
@@ -43,6 +47,10 @@ test:
then \
for SCRIPT in $(SCRIPTS); \
do \
+ if grep -qs /usr/bin/python3 $${SCRIPT}; \
+ then \
+ continue; \
+ fi; \
checkbashisms -f -x $${SCRIPT}; \
echo -n "."; \
done; \
@@ -57,6 +65,10 @@ test:
then \
for SCRIPT in $(SCRIPTS); \
do \
+ if grep -qs /usr/bin/python3 $${SCRIPT}; \
+ then \
+ continue; \
+ fi; \
shellcheck $${SCRIPT} || true; \
echo -n "."; \
done; \
@@ -83,6 +95,9 @@ install: build
mkdir -p $(DESTDIR)/usr/libexec
cp -r libexec/* $(DESTDIR)/usr/libexec
+ mkdir -p $(DESTDIR)/usr/lib/python3/dist-packages
+ cp -r python3/* $(DESTDIR)/usr/lib/python3/dist-packages
+
mkdir -p $(DESTDIR)/usr/share/$(SOFTWARE)
cp -r VERSION.txt $(DESTDIR)/usr/share/$(SOFTWARE)
cp -r share/config share/hooks share/keys share/build-scripts share/get-scripts $(DESTDIR)/usr/share/$(SOFTWARE)
@@ -204,6 +219,9 @@ uninstall:
rm -rf $(DESTDIR)/usr/share/$(SOFTWARE)
rmdir --ignore-fail-on-non-empty --parents $(DESTDIR)/usr/share || true
+ rm -rf $(DESTDIR)/usr/lib/python3/dist-packages/compute_tools
+ rmdir --ignore-fail-on-non-empty --parents $(DESTDIR)/usr/lib/python3/dist-packages
+
rm -rf $(DESTDIR)/usr/libexec/$(PROGRAM)
rmdir --ignore-fail-on-non-empty --parents $(DESTDIR)/usr/libexec || true