Frontend and backend communication

Dainius (GreatEmerald) pastas4 at gmail.com
Fri Jul 29 11:44:48 PDT 2011


Yes, this is a library, so a main() there would be rather pointless.
However, it seems that on many occasions compilers will simply not
acknowledge anything without one, so I guess at least a declaration is
in order... I'll have to try that out once I get back on Windows.

Meanwhile, on Linux, I am getting these linker errors instead:

    /usr/lib64/gcc/x86_64-suse-linux/4.5/../../../../lib64/libphobos2.a(datetime_3a6_1ec.o):
In function `_D3std8datetime5Clock11currStdTimeFNdNeZl':
    std/datetime.d:(.text._D3std8datetime5Clock11currStdTimeFNdNeZl+0x1d):
undefined reference to `clock_gettime'
    /usr/lib64/gcc/x86_64-suse-linux/4.5/../../../../lib64/libphobos2.a(time_c6_4d1.o):
In function `_D4core4time12TickDuration12_staticCtor7OFNeZv':
    src/core/time.d:(.text._D4core4time12TickDuration12_staticCtor7OFNeZv+0x1f):
undefined reference to `clock_getres'
    /usr/lib64/gcc/x86_64-suse-linux/4.5/../../../../lib64/libphobos2.a(time_c6_4d1.o):
In function `_D4core4time12TickDuration14currSystemTickFNdNeZS4core4time12TickDuration':
    src/core/time.d:(.text._D4core4time12TickDuration14currSystemTickFNdNeZS4core4time12TickDuration+0x1f):
undefined reference to `clock_gettime'

Is it related, or is it a different issue altogether?

Also, apparently SDL and Lua don't like being statically linked. Good
thing the backend doesn't use SDL any more, then! And Lua does link,
although reluctantly and with linker warnings. Reportedly they are
nothing to worry about too much, but still...


More information about the Digitalmars-d-learn mailing list