[vlc-devel] [PATCH] configure: Don't explicitly add -ladvapi32 to linker flags
Martin Storsjö
martin at martin.st
Thu Apr 26 01:06:55 CEST 2018
On Thu, 26 Apr 2018, Jean-Baptiste Kempf wrote:
>
>
> On Thu, 26 Apr 2018, at 00:49, Martin Storsjö wrote:
>> This flag was originally not added because of crypto functions,
>> but together with -lssp in 460879.
>
> Because without that, it wouldn't compile. And it failed the buildbots.
Hmm, strange. Right now, gcc+mingw5 setups still build after this patch
for me at least.
>> Advapi32 is one of the libs that are automatically linked in by
>> the mingw compiler/linker driver.
>
> Are you sure? Are you sure also that it is at the right place? (and doesn't that depend on the mingw version)
The right place should be at the end, and I'm pretty sure it does that.
You can have a look with e.g. "x86_64-w64-mingw32-gcc hello.c -o hello.exe
-v", to print the actual link command invoked.
That said, libtool as used in vlc does some tricks where it parses the
output from "$CC -v" and picks up the default libraries, and then links
with -nostdlib, adding the default libs manually.
I don't insist on this fix though - I have a fix for mingw-w64 as well,
that at least fixes my build failure - but I didn't really see why this
would be necessary.
// Martin
More information about the vlc-devel
mailing list