| 1 |
#!/usr/bin/make -f |
| 2 |
|
| 3 |
%: |
| 4 |
dh $@ --with=golang --buildsystem=golang |
| 5 |
|
| 6 |
override_dh_auto_install: |
| 7 |
mv obj-$(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)/bin/sql_exporter \ |
| 8 |
obj-$(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)/bin/prometheus-sql-exporter |
| 9 |
dh_auto_install -- --no-source |
| 10 |
|
| 11 |
override_dh_installman: |
| 12 |
PATH=$(PATH):obj-$(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)/bin \ |
| 13 |
help2man --no-discard-stderr --no-info \ |
| 14 |
--name "SQL Exporter for Prometheus" \ |
| 15 |
--version-string=$(shell dpkg-parsechangelog -S Version) \ |
| 16 |
prometheus-sql-exporter > prometheus-sql-exporter.1 |
| 17 |
# remove stray "maxprocs: Leaving GOMAXPROCS=20: CPU quota undefined" message |
| 18 |
sed -i -e '/GOMAXPROCS/d' prometheus-sql-exporter.1 |
| 19 |
dh_installman |