Reputation: 658
I'm trying to build c++ project.
When I run the make command in terminal it works, but when I do it through Jenkins, it shows me a message that files are missing.
What can be the problem, and how can I solve it?
The Error:
+ make
make -f enclave_lib.mk SGX_DEBUG=1
make[1]: Entering directory '/home/yoni/Documents/private_ledger-tp/CryptoLib'
mt19937ar.c:44:19: fatal error: stdio.h: No such file or directory
Upvotes: 1
Views: 6191
Reputation: 658
It turned out that in our case it was an issue of environment variables.
What I did to solve it is
Any variables that seemed relevant that the Terminal environment and the Jenkins didn't I placed into /etc/environment file (Jenkins takes additional environment vars from there)
env | sort > envInTerminal.txt
env | sort > envInJenkins.txt
meld envInTerminal.txt envInJenkins.txt
sudo gedit /etc/environment
Upvotes: 1
Reputation: 1433
From your comments, the problem is that Jenkins is executed as root user, and can not find the lib stdio.h.
To fix this you can have several options:
As a root user, you install build-essential. That should install this missing dependency
Upvotes: 2