Files
pyDevSup/configure/CONFIG_PY
2018-11-02 16:47:57 -07:00

54 lines
1.3 KiB
Plaintext

ifneq ($(T_A),)
PYMODULE ?= YES
ifeq ($(PYTHON),)
$(error Must set PYTHON to select a python version)
endif
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.$(EPICS_HOST_ARCH).Common
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.Common.$(T_A)
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.$(EPICS_HOST_ARCH).$(T_A)
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY.$(EPICS_HOST_ARCH).Common
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY.Common.$(T_A)
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY.$(EPICS_HOST_ARCH).$(T_A)
ifneq ($(PY_OK),YES)
$(error No usable configuration for $(PYTHON))
endif
SHRLIB_DEPLIB_DIRS += $(PY_LIBDIRS)
PROD_DEPLIB_DIRS += $(PY_LIBDIRS)
INCLUDES += $(PY_INCDIRS:%=-I%)
ifeq ($(HAVE_NUMPY),YES)
TARGET_CPPFLAGS += -DHAVE_NUMPY
else
$(error numpy required)
endif
#LIB_SYS_LIBS += python$(PY_LD_VER)
#PROD_SYS_LIBS += python$(PY_LD_VER)
PY_INSTALL_DIR = $(INSTALL_LOCATION)/python$(PY_LD_VER)/$(T_A)
ifneq ($(PYMODULE),NO)
# Python loadables have no prefix (eg 'pymod.so')
# and are installed alongsize .py files
LOADABLE_SHRLIB_PREFIX =
INSTALL_SHRLIB = $(PY_INSTALL_DIR)
ifeq ($(OS_CLASS),Darwin)
# need -undefined dynamic_lookup
LOADABLE_SHRLIB_LDFLAGS = -bundle -flat_namespace -undefined dynamic_lookup
LOADABLE_SHRLIB_SUFFIX = .so
endif
endif
endif