Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with libcrypto #37

Closed
vuongnch57 opened this issue Oct 8, 2014 · 3 comments
Closed

Error with libcrypto #37

vuongnch57 opened this issue Oct 8, 2014 · 3 comments

Comments

@vuongnch57
Copy link

Hi. First, thanks in advance for your project.
I try to build and run the server following your readme. But when I run "make h2o", I got an error:
Linking C executable h2o
/usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function dlfcn_globallookup': dso_dlfcn.c:(.text+0x21): undefined reference todlopen'
dso_dlfcn.c:(.text+0x34): undefined reference to dlsym' dso_dlfcn.c:(.text+0x3f): undefined reference todlclose'
/usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function dlfcn_bind_func': dso_dlfcn.c:(.text+0x354): undefined reference todlsym'
dso_dlfcn.c:(.text+0x3fb): undefined reference to dlerror' /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In functiondlfcn_bind_var':
dso_dlfcn.c:(.text+0x474): undefined reference to dlsym' dso_dlfcn.c:(.text+0x52e): undefined reference todlerror'
/usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function dlfcn_load': dso_dlfcn.c:(.text+0x5a4): undefined reference todlopen'
dso_dlfcn.c:(.text+0x612): undefined reference to dlclose' dso_dlfcn.c:(.text+0x640): undefined reference todlerror'
/usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function dlfcn_pathbyaddr': dso_dlfcn.c:(.text+0x6be): undefined reference todladdr'
dso_dlfcn.c:(.text+0x721): undefined reference to dlerror' /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In functiondlfcn_unload':
dso_dlfcn.c:(.text+0x77a): undefined reference to `dlclose'
collect2: ld returned 1 exit status
make[3]: *** [h2o] Error 1
make[2]: *** [CMakeFiles/h2o.dir/all] Error 2
make[1]: *** [CMakeFiles/h2o.dir/rule] Error 2
make: *** [h2o] Error 2
Can you tell me how can I fix it?

@kazuho
Copy link
Member

kazuho commented Oct 8, 2014

What is the OS (or linux distro?) are you using? Did you build libcrypto (which is part of OpenSSL) by yourself?

It seems like that on your environment libcrypto wants to link to libdl, so adding dl after pthread at the last line of CMakeLists.txt might fix the problem.

@vuongnch57
Copy link
Author

Yes.I built libcrypto with OpenSSL.I follow your suggestion and now the h2o server is working perfectly. Thanks a lot

@kazuho
Copy link
Member

kazuho commented Oct 10, 2014

Your welcome!

@kazuho kazuho closed this as completed Oct 10, 2014
kazuho pushed a commit that referenced this issue Oct 20, 2014
…y env (ubuntu 14.04 lts with hand-build openssl 1.0.2beta3 as well)
gfx pushed a commit to gfx/h2o that referenced this issue Jun 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants