Linux: How to statically link against system libs?
Nick Sabalausky
a at a.a
Mon May 9 16:46:31 PDT 2011
"Nick Sabalausky" <a at a.a> wrote in message
news:iq6159$q3q$1 at digitalmars.com...
> "Nick Sabalausky" <a at a.a> wrote in message
> news:iq60qt$pm0$1 at digitalmars.com...
>>
>> I downloaded 4.2 (picked pretty much at random), installed it in
>> VirtualBox, compiled a trivial test C program in the included GCC,
>> uploaded that to the server, and it worked! :)
>>
>
> Actually, I did have to remove the HTTP status code output from my little
> hello world cgi test in forder for Apache to not throw up a 500. That kind
> of surprised me, actually. But maybe it just means it's been far too long
> since I've done CGI... *shrug*
>
If anyone's curious, I did get a basic D cgi app to work, too (ie, Compiling
on CentOS 4.2 in a VM and uploading to my shared host server), but I had to:
1. Recompile DMD (Because the precompiled DMD would immediately quit with a
"Floating point exception" message, even if called with zero args).
2. Remove "-L--no-warn-search-mismatch" (Because otherwise, when it tried to
link, the GCC in CentOS 4.2 would error out and complain that wasn't a valid
switch.)
As a little bonus, the C test app I compiled in the CentOS 4.2 VM also ran
fine on my physical Kubuntu 10.04 box. Although the D one segfaulted. No big
deal deal though, it's easy enough to compile on that box.
The only problem I'm having now (aside from the fact that I haven't
attempted to deal with the other shared host server yet - the debian one
from the horrible ipower company), is that CentOS 4.2 (or maybe it's just
KDE) runs so slow in a VM that it frequently doesn't recognize when I let go
of a key and so then it goes off doing crazy shit. :/ Or it'll swap my key
presses if I type too fast. At one point I had a hell of a time just getting
it to let me type in "cd dmd" correctly. (I don't think it's entirely
because of my computer though. XP runs just fine in a VM for me, even with
only 192MB RAM allocated to it instead of the 512MB given to CentOS 4.2) So
I'm going to try putting CentOS 4.9 in a VM and replacing KDE with XFCE. And
I'll also have VirtualBox enable 3D accel and see if maybe then the
"VirtualBox Guest Additions" package will be able to use OpenGL.
More information about the Digitalmars-d-learn
mailing list