[rescue] ar library linking error

Michael Parson mparson at bl.org
Sat Dec 14 12:27:37 CST 2019


On 2019-12-11 12:45, William Barnett-Lewis wrote:
> I am attempting to build SDL 1.2.15 on Tru64 5.1b. I have little
> experience building libraries because I've been lucky I guess :)
> 
> At any rate, I have config'ed it, ran make, all the CC passes build
> the .o files fine but at the final link I get
> 
> ar: build/.libs/libSDL.a file truncated
> 
> Any clues? I'm trying to build this since it's the main dependency for
> DosBox and Doom :) It would be fun to run old DOS games or even my old
> copy of Wordstar 7 on an Alpha :)

'ar' is simply an archiver, similar to, but not the same as, 'tar'.

So, the static library file libSDL.a should be an archive with a bunch 
of .o files in it.

Check the Makefile for the 'ar' command line and arguments that are 
being used to create the archive.  Compare those
commands with the 'ar' manpage.  It's possible that the 'ar' you are 
using is not 100% command-line compatible with the 'ar' the Makefile is 
expecting.  Check to see if you have multiple 'ar' commands installed, 
like maybe /usr/ccs/bin/ar and /usr/local/bin/ar, see which one your 
path is finding, maybe adjust your PATH to pick the other one, or 
hard-code the path in the Makefile.

-- 
Michael Parson
Pflugerville, TX
KF5LGQ


More information about the rescue mailing list