# BUILD_CONF must be specified relative to the repo root or must be an absolute path # BUILD_CONF defaults to ./build.conf REPO_ROOT_REL:=$(dir $(lastword $(MAKEFILE_LIST))) ifndef BUILD_CONF BUILD_CONF=$(REPO_ROOT_REL)/build.conf -include $(BUILD_CONF) else BUILD_CONF_EFF=$(BUILD_CONF) ifeq ($(dir $(BUILD_CONF)),./) BUILD_CONF_EFF=$(REPO_ROOT_REL)/$(BUILD_CONF) endif ifeq ($(wildcard $(BUILD_CONF_EFF)),) $(info BUILD_CONF must be specified relative to the repo root or must be an absolute path) $(error file specified using BUILD_CONF ($(BUILD_CONF)) not found) endif include $(BUILD_CONF_EFF) endif # Build config Defaults PREFIX?=$(HOME) DEBUG?=debug # Constants BUILD_DIR = ./build DIST_DIR = ./dist VERSION_FILE = ./src/pEp/__version__.py BUILD_INPLACE = ./src/pEp/_pEp.cpython-* PYTHON_ARTIFACTS += ./.eggs PYTHON_ARTIFACTS += ./src/pEp.egg-info PYTHON_ARTIFACTS += ./.pytest_cache VENV_DIR = ./_venv ifeq ($(DEBUG),debug) DEBUG_OPT+=--debug endif ifneq ($(PREFIX),) PREFIX_OPT += --prefix=$(PREFIX) endif