C++ cgi

Submariner

New Member
Messages
44
Reaction score
1
Points
0
To run a compiled GCI program it needs to be compiled against the OS it will be running on. Since you are compiling your CGI programs on Windows they will only run on Windows servers.

It gets a bit trickier with UNIX servers as you can complie a Linux C++ CGI program and it may or may not work on all Linux web servers if you linked your libraries dynamically (makes a smaller executible). The reason for this is your CGI program may want to load a library that is not installed on the server and the program will fail. If you don't do dynamic linking and pull in all the standard OS functions into you program is shoud run all all like servers.

I hope this helps...

James

BTW, on second thought if you have a cross compiler that will generate the UNIX format code on your Windows box then you can use it to generate the program. Most don't do this, it's easier to build a box that has the same OS you want to run it on and compile there and upload to the production server.
 
Top