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

[msmtp-users] Can't create static binary



I like to create static binaries for use on embedded linux system (routers), but I can't figure how to get msmtp to compile statically. I mean completely static binary, no external dependencies on libc etc. Generally while compiling either natively on the router or cross-compiling on x64, I throw in
LDFLAGS="-Wl,-static -static -static-libgcc"
and for most things this takes care of it.

It seems it's openssl complaining about libdl.
If I then run
make LDFLAGS="-ldl"
it will compile successfully, but it is not static.
Any help or suggestions?

thanks,
Lance