hab
hab

Reputation: 627

ARM9 cross compilation error

I'm a beginner in programming embedded devices. While cross compiling a cryptography algorithm (using openssl), it generates an error as shown below. The program doesn't have a problem, since it runs well in the host system (Ubuntu 14). Did anyone come across this problem ? I tried some of the already posted related questions on cross compilation but didn't solve my problem. Thanks.

enter image description here

Upvotes: 0

Views: 143

Answers (1)

Mohit Jain
Mohit Jain

Reputation: 30489

For headers issue:

Locate the headers and include it using -I switch while compilation.

For linking ussue:

$ locate libcrypto.so

You will get the directory libcrypto resides. Let's say the directory is: target_usr/lib/libcrypto.so

Now use the following command to ensure correct linking:

$ arm-linux-gnueabi-gcc hashSHA.c -Ltarget_usr/lib -lcrypto

Also make sure to add appropriate include flag and prefer to use some warning and optimization flags (-W -Wall -O2 for example)

Upvotes: 1

Related Questions