sustrik / libdill

Structured concurrency in C
MIT License
1.69k stars 155 forks source link

Cannot compile step5.c #195

Closed hirrolot closed 5 years ago

hirrolot commented 5 years ago

When trying to compile tutorial/sockets/step5.c:

$ gcc step5.c -ldill -pthread
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_cbio_read':
/home/gymmasssorla/libdill-2.14/tls.c:444: undefined reference to `BIO_get_data'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_cbio_write':
/home/gymmasssorla/libdill-2.14/tls.c:437: undefined reference to `BIO_get_data'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_process_errors':
/home/gymmasssorla/libdill-2.14/tls.c:370: undefined reference to `ERR_error_string_n'
/home/gymmasssorla/libdill-2.14/tls.c:368: undefined reference to `ERR_get_error'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_hclose':
/home/gymmasssorla/libdill-2.14/tls.c:348: undefined reference to `SSL_free'
/home/gymmasssorla/libdill-2.14/tls.c:349: undefined reference to `SSL_CTX_free'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_init':
/home/gymmasssorla/libdill-2.14/tls.c:471: undefined reference to `OPENSSL_init_ssl'
/home/gymmasssorla/libdill-2.14/tls.c:472: undefined reference to `OPENSSL_init_ssl'
/home/gymmasssorla/libdill-2.14/tls.c:474: undefined reference to `BIO_get_new_index'
/home/gymmasssorla/libdill-2.14/tls.c:475: undefined reference to `BIO_meth_new'
/home/gymmasssorla/libdill-2.14/tls.c:477: undefined reference to `BIO_meth_set_create'
/home/gymmasssorla/libdill-2.14/tls.c:479: undefined reference to `BIO_meth_set_destroy'
/home/gymmasssorla/libdill-2.14/tls.c:481: undefined reference to `BIO_meth_set_write'
/home/gymmasssorla/libdill-2.14/tls.c:483: undefined reference to `BIO_meth_set_read'
/home/gymmasssorla/libdill-2.14/tls.c:485: undefined reference to `BIO_meth_set_ctrl'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_new_cbio':
/home/gymmasssorla/libdill-2.14/tls.c:421: undefined reference to `BIO_new'
/home/gymmasssorla/libdill-2.14/tls.c:423: undefined reference to `BIO_set_data'
/home/gymmasssorla/libdill-2.14/tls.c:424: undefined reference to `BIO_set_init'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_followup':
/home/gymmasssorla/libdill-2.14/tls.c:383: undefined reference to `SSL_get_error'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_brecvl':
/home/gymmasssorla/libdill-2.14/tls.c:327: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:328: undefined reference to `SSL_read'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_bsendl':
/home/gymmasssorla/libdill-2.14/tls.c:299: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:300: undefined reference to `SSL_write'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_attach_client_mem':
/home/gymmasssorla/libdill-2.14/tls.c:85: undefined reference to `TLS_method'
/home/gymmasssorla/libdill-2.14/tls.c:87: undefined reference to `SSL_CTX_new'
/home/gymmasssorla/libdill-2.14/tls.c:90: undefined reference to `SSL_new'
/home/gymmasssorla/libdill-2.14/tls.c:92: undefined reference to `SSL_set_connect_state'
/home/gymmasssorla/libdill-2.14/tls.c:96: undefined reference to `SSL_set_bio'
/home/gymmasssorla/libdill-2.14/tls.c:117: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:118: undefined reference to `SSL_connect'
/home/gymmasssorla/libdill-2.14/tls.c:127: undefined reference to `BIO_vfree'
/home/gymmasssorla/libdill-2.14/tls.c:129: undefined reference to `SSL_free'
/home/gymmasssorla/libdill-2.14/tls.c:131: undefined reference to `SSL_CTX_free'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_attach_server_mem':
/home/gymmasssorla/libdill-2.14/tls.c:165: undefined reference to `TLS_server_method'
/home/gymmasssorla/libdill-2.14/tls.c:167: undefined reference to `SSL_CTX_new'
/home/gymmasssorla/libdill-2.14/tls.c:171: undefined reference to `SSL_CTX_use_certificate_file'
/home/gymmasssorla/libdill-2.14/tls.c:173: undefined reference to `SSL_CTX_use_PrivateKey_file'
/home/gymmasssorla/libdill-2.14/tls.c:176: undefined reference to `SSL_new'
/home/gymmasssorla/libdill-2.14/tls.c:178: undefined reference to `SSL_set_accept_state'
/home/gymmasssorla/libdill-2.14/tls.c:182: undefined reference to `SSL_set_bio'
/home/gymmasssorla/libdill-2.14/tls.c:203: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:204: undefined reference to `SSL_accept'
/home/gymmasssorla/libdill-2.14/tls.c:213: undefined reference to `BIO_vfree'
/home/gymmasssorla/libdill-2.14/tls.c:215: undefined reference to `SSL_free'
/home/gymmasssorla/libdill-2.14/tls.c:217: undefined reference to `SSL_CTX_free'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_done':
/home/gymmasssorla/libdill-2.14/tls.c:248: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:249: undefined reference to `SSL_shutdown'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_detach':
/home/gymmasssorla/libdill-2.14/tls.c:272: undefined reference to `ERR_clear_error'
/home/gymmasssorla/libdill-2.14/tls.c:273: undefined reference to `SSL_shutdown'
//usr/local/lib/libdill.a(libdill_la-tls.o): In function `dill_tls_term':
/home/gymmasssorla/libdill-2.14/tls.c:463: undefined reference to `BIO_meth_free'
collect2: error: ld returned 1 exit status

Note: I have installed LibDill like that:

$ wget http://libdill.org/libdill-2.14.tar.gz
$ tar -xzf libdill-2.14.tar.gz
$ cd libdill-2.14
$ ./configure --enable-tls --disable-shared
$ make
$ sudo make install

Note: my system's configuration is:

                          ./+o+-       gymmasssorla@gymmasssorla-desktop
                  yyyyy- -yyyyyy+      OS: Ubuntu 18.04 bionic
               ://+//////-yyyyyyo      Kernel: x86_64 Linux 4.15.0-51-generic
           .++ .:/++++++/-.+sss/`      Uptime: 1h 41m
         .:++o:  /++++++++/:--:/-      Packages: 1819
        o:+o+:++.`..```.-/oo+++++/     Shell: bash 4.4.19
       .:+o:+o/.          `+sssoo+/    Resolution: 1920x1080
  .++/+:+oo+o:`             /sssooo.   DE: GNOME 
 /+++//+:`oo+o               /::--:.   WM: GNOME Shell
 \+/+o+++`o++o               ++////.   WM Theme: Adwaita
  .++.o+++oo+:`             /dddhhh.   GTK Theme: Ambiance [GTK2/3]
       .+.o+oo:.          `oddhhhh+    Icon Theme: ubuntu-mono-dark
        \+.++o+o``-````.:ohdhhhhh+     Font: Ubuntu 11
         `:o+++ `ohhhhhhhhyo++os:      CPU: Intel Core i7-6700 @ 8x 4GHz [44.0°C]
           .o:`.syhhhhhhh/.oo++o`      GPU: GeForce GTX 1060 6GB
               /osyyyyyyo++ooo+++/     RAM: 7173MiB / 7927MiB
                   ````` +oo+++o\:    
                          `oo++.      

Note: my OpenSSL version is:

$ openssl version
OpenSSL 1.1.1  11 Sep 2018
progamer71 commented 5 years ago

I have repeated your steps but do not have any problems. My system is ubuntu 18.04 with latest update, kernel 4.15.0-51-generic, openssl version 1.1.1b.

hirrolot commented 5 years ago

It's quite strange. I think the problem is with OpenSSL because if I execute gcc step5.c -o step5 -pthread -ldill -lssl I receive this output:

gymmasssorla@gymmasssorla-desktop:~/libdill-2.14/tutorial/sockets$ gcc step5.c -o step5 -pthread -ldill -lssl
/usr/bin/ld: //usr/local/lib/libdill.a(libdill_la-tls.o): undefined reference to symbol 'ERR_get_error@@OPENSSL_1_1_0'
//usr/lib/x86_64-linux-gnu/libcrypto.so.1.1: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status

Could you please tell me how did you installed OpenSSL on your machine?

progamer71 commented 5 years ago

Now I can not access to my development machine using openssl 1.1.1b. I will use a development server at my home. it use ubuntu 18.04 with latest update and openssl 1.1.1. I download libdill-2.14.zip file unzip and cd into there. I run following commands with out any problems. I also show output of my build, please compare with your output.

sudo apt install autoconf libtool
./autogen.sh
./configure --enable-tls --disable-shared
make
make check
sudo make install
cd tutorial/basics/
gcc step5.c -o step5 -pthread -ldill -lssl
~/Downloads/libdill-2.14$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 18.04.2 LTS
Release:    18.04
Codename:   bionic

~/Downloads/libdill-2.14$ openssl version
OpenSSL 1.1.1  11 Sep 2018

~/Downloads/libdill-2.14$ gcc --version
gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

~/Downloads/libdill-2.14$ ./autogen.sh 
autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal --force -I m4
autoreconf: configure.ac: tracing
autoreconf: running: libtoolize --copy --force
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
autoreconf: running: /usr/bin/autoconf --force
autoreconf: configure.ac: not using Autoheader
autoreconf: running: automake --add-missing --copy --force-missing
configure.ac:59: installing './compile'
configure.ac:32: installing './missing'
Makefile.am: installing './depcomp'
autoreconf: Leaving directory `.'

~/Downloads/libdill-2.14$./configure --enable-tls --disable-shared
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether UID '1000' is supported by ustar format... yes
checking whether GID '1000' is supported by ustar format... yes
checking how to create a ustar tar archive... gnutar
checking whether make supports nested variables... (cached) yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking for a sed that does not truncate output... /bin/sed
checking for gawk... (cached) gawk
configure: libdill package version: Unknown
configure: libdill ABI version: 25.0.5
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for pthread_attr_init in -lpthread... yes
checking for SSL_ctrl  in -lssl... yes
checking for BIO_read in -lcrypto... yes
checking for posix_memalign... yes
checking for mprotect... yes
checking for clock_gettime in -lrt... yes
checking for clock_gettime... yes
checking for socket in -lsocket... no
checking for epoll_create... yes
checking for kqueue... no
checking for struct sockaddr.sa_len... no
checking how to print strings... printf
checking for a sed that does not truncate output... (cached) /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /bin/dd
checking how to truncate binary pipes... /bin/dd bs=4096 count=1
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating man/Makefile
config.status: creating libdill.pc
config.status: executing depfiles commands
config.status: executing libtool commands

~/Downloads/libdill-2.14$ make
Making all in man
make[1]: Entering directory '/home/kai/Downloads/libdill-2.14/man'
make[1]: Nothing to be done for 'all'.
make[1]: Leaving directory '/home/kai/Downloads/libdill-2.14/man'
make[1]: Entering directory '/home/kai/Downloads/libdill-2.14'
  CC       libdill_la-chan.lo
  CC       libdill_la-cr.lo
  CC       libdill_la-handle.lo
  CC       libdill_la-libdill.lo
  CC       libdill_la-now.lo
  CC       libdill_la-pollset.lo
  CC       libdill_la-rbtree.lo
  CC       libdill_la-stack.lo
  CC       libdill_la-ctx.lo
  CC       libdill_la-utils.lo
  CC       libdill_la-bsock.lo
  CC       libdill_la-fd.lo
  CC       libdill_la-happyeyeballs.lo
  CC       libdill_la-http.lo
  CC       libdill_la-iol.lo
  CC       libdill_la-ipc.lo
  CC       libdill_la-ipaddr.lo
  CC       libdill_la-msock.lo
  CC       libdill_la-prefix.lo
  CC       libdill_la-socks5.lo
  CC       libdill_la-suffix.lo
  CC       libdill_la-tcp.lo
  CC       libdill_la-term.lo
  CC       libdill_la-udp.lo
  CC       libdill_la-ws.lo
  CC       dns/libdill_la-dns.lo
  CC       libdill_la-tls.lo
  CCLD     libdill.la
ar: `u' modifier ignored since `D' is the default (see `U')
  CC       tutorial/basics/step1.o
  CCLD     tutorial/basics/step1
  CC       tutorial/basics/step2.o
  CCLD     tutorial/basics/step2
  CC       tutorial/basics/step3.o
  CCLD     tutorial/basics/step3
  CC       tutorial/basics/step4.o
  CCLD     tutorial/basics/step4
  CC       tutorial/basics/step5.o
  CCLD     tutorial/basics/step5
  CC       tutorial/basics/step6.o
  CCLD     tutorial/basics/step6
  CC       tutorial/protocol/step1.o
  CCLD     tutorial/protocol/step1
  CC       tutorial/protocol/step2.o
  CCLD     tutorial/protocol/step2
  CC       tutorial/protocol/step3.o
  CCLD     tutorial/protocol/step3
  CC       tutorial/protocol/step4.o
  CCLD     tutorial/protocol/step4
  CC       tutorial/protocol/step5.o
  CCLD     tutorial/protocol/step5
  CC       tutorial/protocol/step6.o
  CCLD     tutorial/protocol/step6
  CC       tutorial/protocol/step7.o
  CCLD     tutorial/protocol/step7
  CC       tutorial/protocol/step8.o
  CCLD     tutorial/protocol/step8
  CC       tutorial/protocol/step9.o
  CCLD     tutorial/protocol/step9
  CC       tutorial/sockets/step1.o
  CCLD     tutorial/sockets/step1
  CC       tutorial/sockets/step2.o
  CCLD     tutorial/sockets/step2
  CC       tutorial/sockets/step3.o
  CCLD     tutorial/sockets/step3
  CC       tutorial/sockets/step4.o
  CCLD     tutorial/sockets/step4
  CC       tutorial/sockets/step5.o
  CCLD     tutorial/sockets/step5
  CC       examples/socks5proxy.o
  CCLD     examples/socks5proxy
  CC       examples/webapp.o
  CCLD     examples/webapp
  CC       perf/go.o
  CCLD     perf/go
  CC       perf/ctxswitch.o
  CCLD     perf/ctxswitch
  CC       perf/chan.o
  CCLD     perf/chan
  CC       perf/choose.o
  CCLD     perf/choose
  CC       perf/done.o
  CCLD     perf/done
  CC       perf/whispers.o
  CCLD     perf/whispers
  CC       perf/timer.o
  CCLD     perf/timer
make[1]: Leaving directory '/home/kai/Downloads/libdill-2.14'

~/Downloads/libdill-2.14$ make check
Making check in man
make[1]: Entering directory '/home/kai/Downloads/libdill-2.14/man'
make[1]: Nothing to be done for 'check'.
make[1]: Leaving directory '/home/kai/Downloads/libdill-2.14/man'
make[1]: Entering directory '/home/kai/Downloads/libdill-2.14'
make  tests/example tests/go1 tests/go2 tests/go3 tests/go4 tests/go5 tests/fd tests/handle tests/chan tests/choose tests/sleep tests/signals tests/overload tests/rbtree tests/bundle tests/threads tests/threads2 tests/ipaddr tests/iol tests/tcp tests/ipc tests/prefix tests/socks5 tests/suffix tests/udp tests/http tests/ws tests/term tests/happyeyeballs tests/tls tests/assert.h
make[2]: Entering directory '/home/kai/Downloads/libdill-2.14'
  CC       tests/example.o
  CCLD     tests/example
  CC       tests/go1.o
  CCLD     tests/go1
  CC       tests/go2.o
  CCLD     tests/go2
  CC       tests/go3.o
  CCLD     tests/go3
  CC       tests/go4.o
  CCLD     tests/go4
  CC       tests/go5.o
  CCLD     tests/go5
  CC       tests/fd.o
  CCLD     tests/fd
  CC       tests/handle.o
  CCLD     tests/handle
  CC       tests/chan.o
  CCLD     tests/chan
  CC       tests/choose.o
  CCLD     tests/choose
  CC       tests/sleep.o
  CCLD     tests/sleep
  CC       tests/signals.o
  CCLD     tests/signals
  CC       tests/overload.o
  CCLD     tests/overload
  CC       tests/rbtree.o
  CCLD     tests/rbtree
  CC       tests/bundle.o
  CCLD     tests/bundle
  CC       tests/threads.o
  CCLD     tests/threads
  CC       tests/threads2.o
  CCLD     tests/threads2
  CC       tests/ipaddr.o
  CCLD     tests/ipaddr
  CC       tests/iol.o
  CCLD     tests/iol
  CC       tests/tcp.o
  CCLD     tests/tcp
  CC       tests/ipc.o
  CCLD     tests/ipc
  CC       tests/prefix.o
  CCLD     tests/prefix
  CC       tests/socks5.o
  CCLD     tests/socks5
  CC       tests/suffix.o
  CCLD     tests/suffix
  CC       tests/udp.o
  CCLD     tests/udp
  CC       tests/http.o
  CCLD     tests/http
  CC       tests/ws.o
  CCLD     tests/ws
  CC       tests/term.o
  CCLD     tests/term
  CC       tests/happyeyeballs.o
  CCLD     tests/happyeyeballs
  CC       tests/tls.o
  CCLD     tests/tls
make[2]: Nothing to be done for 'tests/assert.h'.
make[2]: Leaving directory '/home/kai/Downloads/libdill-2.14'
make  check-TESTS
make[2]: Entering directory '/home/kai/Downloads/libdill-2.14'
make[3]: Entering directory '/home/kai/Downloads/libdill-2.14'
PASS: tests/example
PASS: tests/go1
PASS: tests/go2
PASS: tests/go3
PASS: tests/go4
PASS: tests/go5
PASS: tests/fd
PASS: tests/handle
PASS: tests/chan
PASS: tests/choose
PASS: tests/sleep
PASS: tests/signals
PASS: tests/overload
PASS: tests/rbtree
PASS: tests/bundle
PASS: tests/threads
PASS: tests/threads2
PASS: tests/ipaddr
PASS: tests/iol
PASS: tests/tcp
PASS: tests/ipc
PASS: tests/prefix
PASS: tests/socks5
PASS: tests/suffix
PASS: tests/udp
PASS: tests/http
PASS: tests/ws
PASS: tests/term
PASS: tests/happyeyeballs
PASS: tests/tls
============================================================================
Testsuite summary for libdill Unknown
============================================================================
# TOTAL: 30
# PASS:  30
# SKIP:  0
# XFAIL: 0
# FAIL:  0
# XPASS: 0
# ERROR: 0
============================================================================
make[3]: Leaving directory '/home/kai/Downloads/libdill-2.14'
make[2]: Leaving directory '/home/kai/Downloads/libdill-2.14'
make[1]: Leaving directory '/home/kai/Downloads/libdill-2.14'

~/Downloads/libdill-2.14$ cd tutorial/basics/
~/Downloads/libdill-2.14$ gcc step5.c -o step5 -pthread -ldill -lssl
~/Downloads/libdill-2.14$
hirrolot commented 5 years ago
gymmasssorla@gymmasssorla-desktop:~/libdill-2.14$ make check
Making check in man
make[1]: Entering directory '/home/gymmasssorla/libdill-2.14/man'
make[1]: Nothing to be done for 'check'.
make[1]: Leaving directory '/home/gymmasssorla/libdill-2.14/man'
make[1]: Entering directory '/home/gymmasssorla/libdill-2.14'
make  tests/example tests/go1 tests/go2 tests/go3 tests/go4 tests/go5 tests/fd tests/handle tests/chan tests/choose tests/sleep tests/signals tests/overload tests/rbtree tests/bundle tests/threads tests/threads2 tests/ipaddr tests/iol tests/tcp tests/ipc tests/prefix tests/socks5 tests/suffix tests/udp tests/http tests/ws tests/term tests/happyeyeballs tests/tls tests/assert.h
make[2]: Entering directory '/home/gymmasssorla/libdill-2.14'
  CC       tests/example.o
  CCLD     tests/example
  CC       tests/go1.o
  CCLD     tests/go1
  CC       tests/go2.o
  CCLD     tests/go2
  CC       tests/go3.o
  CCLD     tests/go3
  CC       tests/go4.o
  CCLD     tests/go4
  CC       tests/go5.o
  CCLD     tests/go5
  CC       tests/fd.o
  CCLD     tests/fd
  CC       tests/handle.o
  CCLD     tests/handle
  CC       tests/chan.o
  CCLD     tests/chan
  CC       tests/choose.o
  CCLD     tests/choose
  CC       tests/sleep.o
  CCLD     tests/sleep
  CC       tests/signals.o
  CCLD     tests/signals
  CC       tests/overload.o
  CCLD     tests/overload
  CC       tests/rbtree.o
  CCLD     tests/rbtree
  CC       tests/bundle.o
  CCLD     tests/bundle
  CC       tests/threads.o
  CCLD     tests/threads
  CC       tests/threads2.o
  CCLD     tests/threads2
  CC       tests/ipaddr.o
  CCLD     tests/ipaddr
  CC       tests/iol.o
  CCLD     tests/iol
  CC       tests/tcp.o
  CCLD     tests/tcp
  CC       tests/ipc.o
  CCLD     tests/ipc
  CC       tests/prefix.o
  CCLD     tests/prefix
  CC       tests/socks5.o
  CCLD     tests/socks5
  CC       tests/suffix.o
  CCLD     tests/suffix
  CC       tests/udp.o
  CCLD     tests/udp
  CC       tests/http.o
  CCLD     tests/http
  CC       tests/ws.o
  CCLD     tests/ws
  CC       tests/term.o
  CCLD     tests/term
  CC       tests/happyeyeballs.o
  CCLD     tests/happyeyeballs
  CC       tests/tls.o
  CCLD     tests/tls
make[2]: Nothing to be done for 'tests/assert.h'.
make[2]: Leaving directory '/home/gymmasssorla/libdill-2.14'
make  check-TESTS
make[2]: Entering directory '/home/gymmasssorla/libdill-2.14'
make[3]: Entering directory '/home/gymmasssorla/libdill-2.14'
PASS: tests/example
PASS: tests/go1
PASS: tests/go2
PASS: tests/go3
PASS: tests/go4
PASS: tests/go5
PASS: tests/fd
PASS: tests/handle
PASS: tests/chan
PASS: tests/choose
PASS: tests/sleep
PASS: tests/signals
PASS: tests/overload
PASS: tests/rbtree
PASS: tests/bundle
PASS: tests/threads
PASS: tests/threads2
PASS: tests/ipaddr
PASS: tests/iol
PASS: tests/tcp
PASS: tests/ipc
PASS: tests/prefix
PASS: tests/socks5
PASS: tests/suffix
PASS: tests/udp
PASS: tests/http
PASS: tests/ws
PASS: tests/term
PASS: tests/happyeyeballs
./test-driver: line 107: 23699 Aborted                 "$@" > $log_file 2>&1
FAIL: tests/tls
============================================================================
Testsuite summary for libdill 2.14
============================================================================
# TOTAL: 30
# PASS:  29
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0
============================================================================
See ./test-suite.log
Please report to sustrik@250bpm.com
============================================================================
Makefile:2040: recipe for target 'test-suite.log' failed
make[3]: *** [test-suite.log] Error 1
make[3]: Leaving directory '/home/gymmasssorla/libdill-2.14'
Makefile:2146: recipe for target 'check-TESTS' failed
make[2]: *** [check-TESTS] Error 2
make[2]: Leaving directory '/home/gymmasssorla/libdill-2.14'
Makefile:2583: recipe for target 'check-am' failed
make[1]: *** [check-am] Error 2
make[1]: Leaving directory '/home/gymmasssorla/libdill-2.14'
Makefile:1926: recipe for target 'check-recursive' failed
make: *** [check-recursive] Error 1

My test-suite.log:

gymmasssorla@gymmasssorla-desktop:~/libdill-2.14$ cat test-suite.log
====================================
   libdill 2.14: ./test-suite.log
====================================

# TOTAL: 30
# PASS:  29
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: tests/tls
===============

Bad address [14] (tests/tls.c:91)
FAIL tests/tls (exit status: 134)

Now it's clear that the problem is with TLS. Any ideas?

hirrolot commented 5 years ago

Also if I compile LibDill as a shared library, this error doesn't occur.

hirrolot commented 5 years ago

I tried to compile with the additional -lcrypto flag and the problem has been solved.