forked from mirrors/kore
Allow building with python3.8
This commit is contained in:
parent
55f5b34dd9
commit
ec249390b1
4
Makefile
4
Makefile
|
@ -88,8 +88,8 @@ endif
|
||||||
|
|
||||||
ifneq ("$(PYTHON)", "")
|
ifneq ("$(PYTHON)", "")
|
||||||
S_SRC+=src/python.c
|
S_SRC+=src/python.c
|
||||||
KORE_PYTHON_LIB?=$(shell python3-config --ldflags)
|
KORE_PYTHON_LIB?=$(shell ./misc/python3-config.sh --ldflags)
|
||||||
KORE_PYTHON_INC?=$(shell python3-config --includes)
|
KORE_PYTHON_INC?=$(shell ./misc/python3-config.sh --includes)
|
||||||
LDFLAGS+=$(KORE_PYTHON_LIB)
|
LDFLAGS+=$(KORE_PYTHON_LIB)
|
||||||
CFLAGS+=$(KORE_PYTHON_INC) -DKORE_USE_PYTHON
|
CFLAGS+=$(KORE_PYTHON_INC) -DKORE_USE_PYTHON
|
||||||
FEATURES+=-DKORE_USE_PYTHON
|
FEATURES+=-DKORE_USE_PYTHON
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ $# -ne 1 ]; then
|
||||||
|
echo "python3-flags.sh [--ldflags|--includes]"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
python3-config $1 --embed > /dev/null 2>&1
|
||||||
|
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
python3-config $1 --embed
|
||||||
|
else
|
||||||
|
python3-config $1
|
||||||
|
fi
|
|
@ -144,7 +144,7 @@ version(void)
|
||||||
printf("single ");
|
printf("single ");
|
||||||
#endif
|
#endif
|
||||||
#if defined(KORE_USE_PYTHON)
|
#if defined(KORE_USE_PYTHON)
|
||||||
printf("python ");
|
printf("python-%s ", PY_VERSION);
|
||||||
#endif
|
#endif
|
||||||
printf("\n");
|
printf("\n");
|
||||||
exit(0);
|
exit(0);
|
||||||
|
|
Loading…
Reference in New Issue