I am trying to compile a small .c file that has the following:
#include <openssl/ssl.h> #include <openssl/rsa.h> #include <openssl/x509.h> #include <openssl/evp.h>
In the same folder where I have the .c file, I have / openssl with all these files (and more), also in the synaptic package manager I see that OpenSSL is installed, I'm trying to compile with this:
gcc -o Opentest Opentest.c -lcrypto
but I always get errors:
error: openssl/ssl.h: No such file or directory error: openssl/rsa.h: No such file or directory error: openssl/x509.h: No such file or directory error: openssl/evp.h: No such file or directory
The file I want to compile is just a .c file, does not have a Makefile or. / configure.
I have already tried:
env CFLAGS=-I/path/to/openssl/
and tried to compile again, but I get the same errors.
What should I do to compile using openssl?
c compiler-construction linux compiler-errors openssl
jahmax Jul 30 '10 at 4:21 2010-07-30 04:21
source share