-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
55 lines (43 loc) · 1.69 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# Makefile for building linux packages for elasticsearch_exporter
export PACKAGE_DESCRIPTION := Prometheus Elasticsearch metrics exporter for apptuit.ai
export SRC_PACKAGE_NAME := ${PACKAGE_MODULE}
export PACKAGE_NAME := elasticsearch-exporter
export DEB_PACKAGE_NAME := ${PACKAGE_NAME}
export RPM_PACKAGE_NAME := ${PACKAGE_NAME}
export PACKAGE_LICENSE := Apache-2.0
export DEB_TARGET_amd64_ARCH := amd64
export DEB_TARGET_arm64_ARCH := arm64
export DEB_TARGET_armv7_ARCH := armhf
export DEB_TARGET_ppc64le_ARCH := ppc64el
export DEB_TARGET_mips64le_ARCH := mips64el
export RPM_TARGET_amd64_ARCH := x86_64
export RPM_TARGET_arm64_ARCH := aarch64
export RPM_TARGET_armv7_ARCH := armv7
export RPM_TARGET_ppc64_ARCH := ppc64
export RPM_TARGET_ppc64le_ARCH := ppc64le
export GIT_VERSION := \
$(shell git rev-list --pretty=format:%h HEAD --max-count=1 | sed 1d || echo unknown)
export GIT_FULLSHA1 := \
$(shell git rev-list --pretty=format:%H HEAD --max-count=1 | sed 1d || echo unknown)
export GIT_SHORTSHA1 := \
$(shell git rev-list --pretty=format:%h HEAD --max-count=1 | sed 1d || echo unknown)
all: deb rpm
deb:
make 'DEB_SRC_ARCH=amd64' -C deb/
make 'DEB_SRC_ARCH=arm64' -C deb/
make 'DEB_SRC_ARCH=armv7' -C deb/
make 'DEB_SRC_ARCH=ppc64le' -C deb/
make 'DEB_SRC_ARCH=mips64le' -C deb/
rpm:
make 'RPM_SRC_ARCH=amd64' -C rpm/
make 'RPM_SRC_ARCH=arm64' -C rpm/
make 'RPM_SRC_ARCH=armv7' -C rpm/
make 'RPM_SRC_ARCH=ppc64' -C rpm/
make 'RPM_SRC_ARCH=ppc64le' -C rpm/
lint:
make 'DEB_SRC_ARCH=amd64' -C deb/ lint
make 'DEB_SRC_ARCH=arm64' -C deb/ lint
make 'DEB_SRC_ARCH=armv7' -C deb/ lint
make 'DEB_SRC_ARCH=ppc64le' -C deb/ lint
make 'DEB_SRC_ARCH=mips64le' -C deb/ lint
.PHONY: all deb rpm lint