Sujet : Can't build TclTLS 2.0b1
De : nospam.nurdglaw (at) *nospam* gmail.com (Alan Grunwald)
Groupes : comp.lang.tclDate : 04. Jul 2025, 23:40:35
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <1049lbt$12gnk$1@dont-email.me>
User-Agent : Mozilla Thunderbird
I replied to the announcement of this release back in February to say that I couldn't build it, but I seem to have given up after a couple of very useful suggestions from the author.
After seeing the announcement of Tcl 9.0.2 earlier this week, I am trying again...
I'm running Linux Mint, 64-bit. I have built Tcl 9.0.2 in /opt/tcl9.0.2 and it seems to be working fine, so it's just(?!) a question of rebuilding the external and homebrew packages that the half-dozen scripts I use regularly rely on.
I've downloaded tcltls-2.0b1.tar.gz (to Downloads) and untarred it (to Downloads/tcltls-2.0b1)
Using my preferred workflow, I'm sitting in my home directory (the parent of Downloads) and have typed
(cd Downloads/tcltls-2.0b1; ./configure --enable-64bit --prefix=/opt/tcl9.0.2 --with-tcl=/opt/tcl9.0.1/lib --with-openssl-includedir=/usr/include)
followed by
(cd Downloads/tcltls-2.0b1; make)
This fails quickly with a compilation error:
./generic/tlsBIO.c: In function ‘BioOutput’:
./generic/tlsBIO.c:117:32: error: ‘BIO_FLAGS_IN_EOF’ undeclared (first use in this function); did you mean ‘BIO_FLAGS_READ’?
117 | BIO_set_flags(bio, BIO_FLAGS_IN_EOF);
| ^~~~~~~~~~~~~~~~
The compilation command was
gcc -DPACKAGE_NAME=\"tls\" -DPACKAGE_TARNAME=\"tls\" -DPACKAGE_VERSION=\"2.0b1\" -DPACKAGE_STRING=\"tls\ 2.0b1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DBUILD_tls=/\*\*/ -DHAVE_STDIO_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_STRINGS_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_UNISTD_H=1 -DSTDC_HEADERS=1 -DUSE_THREAD_ALLOC=1 -D_REENTRANT=1 -D_THREAD_SAFE=1 -DTCL_THREADS=1 -DUSE_TCL_STUBS=1 -DUSE_TCLOO_STUBS=1 -DMODULE_SCOPE=extern\ __attribute__\(\(__visibility__\(\"hidden\"\)\)\) -DHAVE_HIDDEN=1 -DHAVE_CAST_TO_UNION=1 -DHAVE_STDBOOL_H=1 -DTCL_WIDE_INT_IS_LONG=1 -DTCL_CFG_OPTIMIZED=1 -DUSE_TCL_STUBS=1 -DNO_SSL3=1 -D_FORTIFY_SOURCE=2 -fstack-protector-all -fno-strict-overflow -I/usr/include -Wno-deprecated-declarations -I/usr/include -I"/opt/tcl9.0.2/include" -I. -O2 -fomit-frame-pointer -DNDEBUG -Wall -fPIC -pipe -m64 -O2 -fomit-frame-pointer -DNDEBUG -Wall -fPIC -c `echo ./generic/tlsBIO.c` -o tlsBIO.o
Now, line 30 of Downloads/tcltls-2.0b1/generic/tlsBIO.c is
#include <openssl/bio.h>
and line 209 of /usr/include/openssl/bio.h is
# define BIO_FLAGS_IN_EOF 0x800
What's going on?
Following the advice in February, I believe I am now putting the right value on the --with-openssl-includedir flag to configure (I no longer include /openssl). I'm suspicious that make includes
-I/usr/include
twice in the compile command but I don't think it's causing a problem.
Help!
Alan