Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

gcc:linker input file unused because linking not done

Tags:

linux

gcc

When I run a make file in Linux to compile C codes, I get the following error:

gcc -Wall -fPIC -DSOLARIS -DXP_UNIX -DMCC_HTTPD -D_REENTRANT -I/opt/profile/OraAlert_test/code/include -I/usr/netscape/server4/plugins/include -I../../pwutils -I../../database/src  -I../../access/src -I/data/share/capscan/include -o getEnv.o -c ../src/
gcc: ../src/: linker input file unused because linking not done

I have tried searching for related questions in stackoverflow and tried the the solutions suggested. Still this could not be resolved. Any suggestions?

like image 300
Blackforest Avatar asked May 24 '12 14:05

Blackforest


1 Answers

You have a compilation command without a source file.
What is it supposed to compile?

The error is indeed misleading. It assumes you want to link with ../src/, but -c says no linkage is to be done.

like image 124
ugoren Avatar answered Oct 14 '22 03:10

ugoren