diff options
author | midipix <writeonce@midipix.org> | 2018-12-09 23:06:10 -0500 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2018-12-10 08:34:47 -0500 |
commit | dc8af219e070cffa33832582ad2d7a20c2cf2e17 (patch) | |
tree | 93c8d4cf6919a9532439ab0e4d1e72c8c366cbed | |
parent | 7466577e75270644f8675ccdb333713cba731dfc (diff) | |
download | sbpython2-dc8af219e070cffa33832582ad2d7a20c2cf2e17.tar.bz2 sbpython2-dc8af219e070cffa33832582ad2d7a20c2cf2e17.tar.xz |
project: cfgdefs: properly detect OPENSSL_VERSION_1_1.
-rw-r--r-- | profiles/osapi/midipix.h | 3 | ||||
-rw-r--r-- | project/config/cfgdefs.sh | 9 |
2 files changed, 9 insertions, 3 deletions
diff --git a/profiles/osapi/midipix.h b/profiles/osapi/midipix.h index a33a5e1..bf94a2b 100644 --- a/profiles/osapi/midipix.h +++ b/profiles/osapi/midipix.h @@ -1,9 +1,6 @@ #ifndef PY_OSAPI_MIDIPIX_H #define PY_OSAPI_MIDIPIX_H -/* interfaces */ -#define OPENSSL_VERSION_1_1 1 - /* os-specific headers */ #define HAVE_ALLOCA_H 1 #define HAVE_DIRENT_H 1 diff --git a/project/config/cfgdefs.sh b/project/config/cfgdefs.sh index a818f0c..1790aab 100644 --- a/project/config/cfgdefs.sh +++ b/project/config/cfgdefs.sh @@ -64,6 +64,15 @@ $mb_cfgdefs_cc $mb_cfgdefs_cflags -E -xc - \ printf 'CFLAGS_CONFIG\t\t+= -DHAVE_NO_STROPTS_H\n' \ >> $mb_pwd/cfgdefs.mk +# openssl 1.1 or newer or a compatible libressl +printf 'void * addr = &X509_NAME_ENTRY_set;' \ + | $mb_cfgdefs_cc $mb_cfgdefs_cflags \ + --include=openssl/x509.h -S -xc - -o - \ + > /dev/null 2>/dev/null && \ + printf 'CFLAGS_CONFIG\t\t+= -DOPENSSL_VERSION_1_1\n' \ + >> $mb_pwd/cfgdefs.mk + + # system tests: (native) pycompile printf '\n\n#system tests: (native) pycompile\n' >> $mb_pwd/cfgdefs.mk |