[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] gethostid() problem



Alan Hourihane a wrote:
In mintlib the gethostid() function calls gethostbyname() which is in
libsocket.a.

This creates a problem when linking, so you have to do this...

gcc -o main main.c -lc -lsocket

to fix the link order.

The default libraries are specified in the linker script embedded into the binutils ld executable, they can be adjusted if necessary.

Howver, it sounds very bad that libc.a depends on other libraries (other than libgcc.a).

--
Vincent Rivière