void-mklive/Makefile

38 lines
790 B
Makefile
Raw Normal View History

GITVER := $(shell git rev-parse --short HEAD)
2013-09-29 10:26:53 +02:00
VERSION = 0.22
SHIN += $(shell find -type f -name '*.sh.in')
SCRIPTS += $(SHIN:.sh.in=.sh)
2017-08-13 23:44:29 -07:00
DATE=$(shell date "+%Y%m%d")
T_IMAGES=rpi{,2,3}{,-musl} beaglebone{,-musl} cubieboard2{,-musl} odroid-c2{,-musl} usbarmory{,-musl}
T_ARCHS=i686 x86_64{,-musl} armv{6,7}l{,-musl}
ARCHS=$(shell echo $(T_ARCHS))
IMAGES=$(shell echo $(T_IMAGES))
ALL_ROOTFS=$(foreach arch,$(ARCHS),void-$(arch)-ROOTFS-$(DATE).tar.xz)
SUDO := sudo
%.sh: %.sh.in
sed -e "s|@@MKLIVE_VERSION@@|$(VERSION) $(GITVER)|g" $^ > $@
2014-01-11 18:51:47 +01:00
chmod +x $@
all: $(SCRIPTS)
2017-08-13 23:44:29 -07:00
clean:
rm -v *.sh
images:
echo $(IMAGES)
rootfs-all: $(ALL_ROOTFS)
rootfs-all-print:
echo $(ALL_ROOTFS)
void-%-ROOTFS-$(DATE).tar.xz:
$(SUDO) ./mkrootfs.sh $*
.PHONY: clean rootfs-all rootfs-all-print