diff --git a/OpenChange/GNUmakefile b/OpenChange/GNUmakefile index afed24ce2..03002e1c1 100644 --- a/OpenChange/GNUmakefile +++ b/OpenChange/GNUmakefile @@ -26,7 +26,16 @@ BUNDLE_INSTALL_DIR = $(SOGO_LIBDIR) UNRTF_DIR = unrtf-$(UNRTF_VERSION) -SAMBA_PRIVATE_DIR = $(shell ./samba-get-config.py "private dir") +PYTHON = /usr/bin/python +PYTHON_IS_GOOD = $(shell $(PYTHON) -c 'from sys import version_info; a=version_info; print a.major == 2 and a.minor >= 6') +ifeq (${PYTHON_IS_GOOD},False) +PYTHON = /usr/bin/python2.6 +endif + +all:: + @echo " Python executable: ${PYTHON}" + +SAMBA_PRIVATE_DIR = $(shell $(PYTHON) ./samba-get-config.py "private dir") $(SOGOBACKEND)_SUBPROJECTS += $(UNRTF_DIR)/src diff --git a/OpenChange/GNUmakefile.preamble b/OpenChange/GNUmakefile.preamble index 74046108b..27b4b5692 100644 --- a/OpenChange/GNUmakefile.preamble +++ b/OpenChange/GNUmakefile.preamble @@ -2,4 +2,4 @@ all:: MAPIStorePropertySelectors.m MAPIStorePropertySelectors.h MAPIStorePropertySelectors.m MAPIStorePropertySelectors.h: gen-property-selectors.py code-MAPIStorePropertySelectors.m code-MAPIStorePropertySelectors.h @echo " Auto-generating MAPIStorePropertySelectors.[hm]..." - @./gen-property-selectors.py -o MAPIStorePropertySelectors $(LIBMAPISTORE_CFLAGS) + @$(PYTHON) ./gen-property-selectors.py -o MAPIStorePropertySelectors $(LIBMAPISTORE_CFLAGS)