diff --git a/Makefile b/Makefile index eb4283d283..b52143b773 100644 --- a/Makefile +++ b/Makefile @@ -24,17 +24,14 @@ ${NAME}: ${BUILD-DIR} .PHONY: clean clean: -ifneq ("$(wildcard ${BUILD-DIR})","") - meson compile --clean -C ${BUILD-DIR} -endif - -.PHONY: purge -purge: ifneq ("$(wildcard ${BUILD-DIR})","") rm -rf ${BUILD-DIR} meson subprojects purge --confirm endif +.PHONY: purge +purge: clean + .PHONY: install install: ${NAME} meson install -C ${BUILD-DIR} --skip-subprojects @@ -58,7 +55,7 @@ test-strict: ${NAME} .PHONY: rpm rpm: - meson ${BUILD-DIR} \ + meson setup ${BUILD-DIR} \ -Dudevrulesdir=$(shell rpm --eval '%{_udevrulesdir}') \ -Dsystemddir=$(shell rpm --eval '%{_unitdir}') \ -Ddocs=man -Ddocs-build=true @@ -66,13 +63,17 @@ rpm: .PHONY: debug debug: - meson ${BUILD-DIR} --buildtype=debug - ninja -C ${BUILD-DIR} + meson setup ${BUILD-DIR} --buildtype=debug + meson compile -C ${BUILD-DIR} .PHONY: static static: - meson ${BUILD-DIR} --buildtype=release \ - --default-library=static -Dc_link_args="-static" \ + meson setup ${BUILD-DIR} --buildtype=release \ --wrap-mode=forcefallback \ - -Dlibnvme:tests=false -Dlibnvme:keyutils=disabled - ninja -C ${BUILD-DIR} + --default-library=static \ + -Dc_link_args="-static" \ + -Dlibnvme:keyutils=disabled \ + -Dlibnvme:liburing=disabled \ + -Dlibnvme:python=disabled \ + -Dlibnvme:openssl=disabled + meson compile -C ${BUILD-DIR}