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

Is it possible to skip a specific library check? #30

Open
vishalbiswas opened this issue May 15, 2021 · 1 comment
Open

Is it possible to skip a specific library check? #30

vishalbiswas opened this issue May 15, 2021 · 1 comment

Comments

@vishalbiswas
Copy link

I'm trying to compile librdkafka for Android.
The pthreads library is built into Android's libc (bionic). Hence, when you specify -lpthread to the linker, it fails.

I need to know whether a mechanism to skip or override the result of a specific library check is available.

@edenhill
Copy link
Owner

edenhill commented Jun 16, 2021

You could do two checks, first a mkl_compile_check and if that fails do a mkl_lib_check, e.g., something like:

if ! mkl_compile_check pthreads_builtin WITH_PTHREADS disable "" \
 "#include <pthreads.h> .. 
void foo (void) {
   pthread_self();
}"; then
    mkl_lib_compile_check pthreads WITH_PTHREADS fail "-lpthread" \
 "#include <pthreads.h> .. 
void foo (void) {
   pthread_self();
}"
fi

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