ld was running out of memory at link time. Since we are here, set LDFLAGS initially instead of adding to it.