summaryrefslogtreecommitdiff
path: root/prom-exporter-mikrotik/Makefile
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2021-07-30 00:46:16 +0200
committerChristian Pointner <equinox@spreadspace.org>2021-07-30 00:46:16 +0200
commit9fa0e3b140b2f1a790229da3534569fe9f8e0ce0 (patch)
treeacf17c668d9cfd83f1134300795d3d54154f200b /prom-exporter-mikrotik/Makefile
parentadd mikrotik exporter (diff)
mikrotik fix version handling
Diffstat (limited to 'prom-exporter-mikrotik/Makefile')
-rw-r--r--prom-exporter-mikrotik/Makefile8
1 files changed, 4 insertions, 4 deletions
diff --git a/prom-exporter-mikrotik/Makefile b/prom-exporter-mikrotik/Makefile
index 0604247..50726e1 100644
--- a/prom-exporter-mikrotik/Makefile
+++ b/prom-exporter-mikrotik/Makefile
@@ -5,15 +5,15 @@ GITHUB_BASEURL := "https://github.com/nshttpd/mikrotik-exporter/releases/downloa
all: i386/mikrotik_exporter amd64/mikrotik_exporter
-%/mikrotik_exporter: mikrotik-exporter_linux_%
+%/mikrotik_exporter: mikrotik-exporter_linux_%_$(VERSION)
mkdir -p $(shell echo $@ | sed 's#/.*##')
cp $< $@
-mikrotik-exporter_linux_%:
- wget -nc "$(GITHUB_BASEURL)/$(VERSION)/$(shell echo $@ | sed s/i386/386/)" -O "$@"
+mikrotik-exporter_linux_%_$(VERSION):
+ wget -nc "$(GITHUB_BASEURL)/$(VERSION)/$(shell echo $@ | sed s/i386/386/ | sed 's/_$(VERSION)//')" -O "$@"
sha256sum -c --ignore-missing sha256sums.txt
clean:
rm -rf i386
rm -rf amd64
- rm -f mikrotik-exporter_linux-*
+ rm -f mikrotik-exporter_linux_*