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

Fix building with --disable-ssl #290

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sebastic
Copy link
Contributor

The 4.1.3 build fails when configured with --disable-ssl.

X509_STORE_CTX is only available when HAVE_SSL is set:

In file included from ./nrpe.c:44:
../include/nrpe-ssl.h:47:50: error: unknown type name 'X509_STORE_CTX'
int ssl_verify_callback_common(int preverify_ok, X509_STORE_CTX * ctx, int is_invalid);
                                                 ^

And the use_ssl flag needs to be disabled when HAVE_SSL is not set:

Undefined symbols for architecture x86_64:
  "_use_ssl", referenced from:
      _process_arguments in nrpe-4fa9f6.o
      _handle_connection in nrpe-4fa9f6.o
      _read_packet in nrpe-4fa9f6.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Fixes build failure:
```
In file included from ./nrpe.c:44:
../include/nrpe-ssl.h:47:50: error: unknown type name 'X509_STORE_CTX'
int ssl_verify_callback_common(int preverify_ok, X509_STORE_CTX * ctx, int is_invalid);
                                                 ^
```
Fixes linker failure:

```
Undefined symbols for architecture x86_64:
  "_use_ssl", referenced from:
      _process_arguments in nrpe-4fa9f6.o
      _handle_connection in nrpe-4fa9f6.o
      _read_packet in nrpe-4fa9f6.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
```
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

Successfully merging this pull request may close these issues.

1 participant