let's say you have a my_cgi1.c as the program source then:
gcc -o my_cgi my_cgi1.c -lcgi
will do the trick. This assumes that libcgi.a exists in /lib, /usr/lib
or /usr/local/lib. If it's sitting somewhere else, e.g. let's say you
installed the
cgi library in /opt/cgi then includes would be in /opt/cgi/include and
library would be in /opt/cgi/lib/libcgi.a
then you have to add the directory containing the library as so:
gcc -I/opt/cgi/include -o my_cgi my_cgi1.c -L/opt/cgi/lib -lcgi
Hope this helps
> Hello,<br>
> I know this is going to be the biggest newbie
> question of all time, but I'm going to ask anyway. I've looked all
> through the documentation and through the website. I've searched
> through google and anywhere else I could think of. Despite all of this,
> I still cannot figure out what compiling flags i need to use. I'm using
> gcc, so if anyone would kindly tell me the correct compile flags I
> would be very grateful. Thank you.
|