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

.libs/unitmain.o:unitmain.c:function main: error: undefined reference to 'ENGINE_cleanup' #175

Closed
noloader opened this issue Feb 29, 2020 · 0 comments

Comments

@noloader
Copy link
Contributor

noloader commented Feb 29, 2020

Hi Everyone,

I'm testing Unbound on Android. Android testing is limited to compile and link. Also see PR #174.

OpenSSL and Expat are built for the tests. OpenSSL is built with no-asm no-hw no-engine.

The Android tests are failing with an error message from the linker:

.libs/unitmain.o:unitmain.c:function main: error: undefined reference to 'ENGINE_cleanup'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Makefile:360: recipe for target 'unittest' failed

In testcode/unitmain.c, it looks like the header is guarded as expected:

#ifdef HAVE_OPENSSL_ENGINE_H
#include <openssl/engine.h>
#endif

However, the call to ENGINE_cleanup() is not guarded:

#  ifdef HAVE_OPENSSL_CONFIG
#  ifdef HAVE_EVP_CLEANUP
	EVP_cleanup();
#  endif
	ENGINE_cleanup();
	CONF_modules_free();
#  endif
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

1 participant