support configs for several python versions
This commit is contained in:
@ -1,13 +1,21 @@
|
|||||||
PYMODULE ?= YES
|
|
||||||
|
|
||||||
ifneq ($(T_A),)
|
ifneq ($(T_A),)
|
||||||
|
|
||||||
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.$(EPICS_HOST_ARCH).Common
|
PYMODULE ?= YES
|
||||||
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.Common.$(T_A)
|
|
||||||
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY.$(EPICS_HOST_ARCH).$(T_A)
|
ifeq ($(PY_VER),)
|
||||||
|
$(error Must set PY_VER to select a python version)
|
||||||
|
endif
|
||||||
|
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY$(PY_VER).$(EPICS_HOST_ARCH).Common
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY$(PY_VER).Common.$(T_A)
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_PY$(PY_VER).$(EPICS_HOST_ARCH).$(T_A)
|
||||||
|
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY$(PY_VER).$(EPICS_HOST_ARCH).Common
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY$(PY_VER).Common.$(T_A)
|
||||||
|
-include $(dir $(lastword $(MAKEFILE_LIST)))/os/CONFIG_SITE_PY$(PY_VER).$(EPICS_HOST_ARCH).$(T_A)
|
||||||
|
|
||||||
ifneq ($(PY_OK),YES)
|
ifneq ($(PY_OK),YES)
|
||||||
$(error Unable to get generated python configuration)
|
$(error No usable configuration for python$(PY_VER))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
PYTHON ?= python$(PY_VER)
|
PYTHON ?= python$(PY_VER)
|
||||||
|
@ -32,6 +32,9 @@ CHECK_RELEASE = YES
|
|||||||
# take effect.
|
# take effect.
|
||||||
#IOCS_APPL_TOP = </IOC/path/to/application/top>
|
#IOCS_APPL_TOP = </IOC/path/to/application/top>
|
||||||
|
|
||||||
|
# Default python version.
|
||||||
|
PY_VER=2.7
|
||||||
|
|
||||||
# Module will be build against this version of the
|
# Module will be build against this version of the
|
||||||
# Python interpreter
|
# Python interpreter
|
||||||
PYTHON ?= python
|
#PYTHON = python$(PY_VER)
|
||||||
|
@ -2,15 +2,20 @@ TOP=..
|
|||||||
|
|
||||||
include $(TOP)/configure/CONFIG
|
include $(TOP)/configure/CONFIG
|
||||||
|
|
||||||
|
ifeq ($(PY_VER),)
|
||||||
|
$(error Must set PY_VER to select a python version)
|
||||||
|
endif
|
||||||
|
PYTHON ?= python$(PY_VER)
|
||||||
|
|
||||||
TARGETS = $(CONFIG_TARGETS)
|
TARGETS = $(CONFIG_TARGETS)
|
||||||
|
|
||||||
ifdef T_A
|
ifdef T_A
|
||||||
CONFIGS = CONFIG_PY RULES_PY os/CONFIG_PY.Common.$(T_A)
|
CONFIGS = CONFIG_PY RULES_PY os/CONFIG_PY$(PY_VER).Common.$(T_A)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
include $(TOP)/configure/RULES
|
include $(TOP)/configure/RULES
|
||||||
|
|
||||||
os/CONFIG_PY.Common.%: $(TOP)/makehelper.py
|
os/CONFIG_PY$(PY_VER).Common.$(T_A): $(TOP)/makehelper.py
|
||||||
[ -d $(dir $@) ] || $(MKDIR) $(dir $@)
|
[ -d $(dir $@) ] || $(MKDIR) $(dir $@)
|
||||||
$(PYTHON) $< $@
|
$(PYTHON) $< $@
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user