mirror of
https://codeberg.org/librewolf/source.git
synced 2024-12-22 13:43:04 -05:00
40 lines
1,000 B
Text
40 lines
1,000 B
Text
.PHONY : all clean veryclean pub shell
|
|
|
|
version_file=../../version
|
|
version:=$(shell cat $(version_file))
|
|
|
|
tag=librewolf/bs4-buildenv-$(distro)
|
|
|
|
build-artifact=librewolf-$(version).en-US.linux-x86_64.tar.bz2
|
|
output=librewolf-$(version).en-US.$(distro).x86_64.deb
|
|
|
|
all : $(output)
|
|
|
|
clean :
|
|
$(rm) -rf work
|
|
|
|
veryclean : clean
|
|
rm -f $(build-artifact) $(output)
|
|
|
|
# pub
|
|
pub : $(output)
|
|
-mkdir -p ../../pub/librewolf/librewolf-$(version)
|
|
cp -v $(output) ../../pub/librewolf/librewolf-$(version)
|
|
|
|
$(output) : work
|
|
$(docker) run --rm --privileged -v $(shell pwd)/work:/work:rw $(tag) bash build-deb.sh $(version)
|
|
cp -v work/librewolf.deb $(output)
|
|
|
|
work : $(build-artifact)
|
|
$(rm) -rf work
|
|
mkdir work
|
|
(cd work && tar xf ../$(build-artifact))
|
|
cp -v ../../assets/build-deb.sh work
|
|
|
|
$(build-artifact) :
|
|
@(echo "Error: Please use 'make $(distro)' at top-level to build first." && false)
|
|
|
|
|
|
shell : work
|
|
$(docker) pull $(tag)
|
|
$(docker) run -it --rm --privileged -v $(shell pwd)/work:/work:rw $(tag) bash
|