FreeBSD/iocage/Makefile

25 lines
788 B
Makefile
Raw Normal View History

2021-04-17 11:05:38 -07:00
ZPOOL=""
SERVER=""
2022-04-19 13:38:56 -07:00
PYTHON?=/usr/local/bin/python3.8
2021-04-17 11:05:38 -07:00
depends:
@(pkg -vv | grep -e "url.*/latest") > /dev/null 2>&1 || (echo "It is advised pkg url is using \"latest\" instead of \"quarterly\" in /etc/pkg/FreeBSD.conf.";)
2022-04-19 13:38:56 -07:00
@test -s ${PYTHON} || (echo "Python binary ${PYTHON} not found, iocage will install python38"; pkg install -q -y python38)
pkg install -q -y py38-libzfs
2021-04-17 11:05:38 -07:00
${PYTHON} -m ensurepip
${PYTHON} -m pip install -Ur requirements.txt
install: depends
${PYTHON} -m pip install -U .
uninstall:
${PYTHON} -m pip uninstall -y iocage-lib iocage-cli
test:
pytest --zpool $(ZPOOL) --server $(SERVER)
help:
@echo " install"
@echo " Installs iocage"
@echo " uninstall"
@echo " Removes iocage"
@echo " test"
@echo " Run unit tests with pytest"