[MPlayer-dev-eng] Patch for build failure with clang, lvvm, etc. on Mac OSX > 10.6

Reimar Döffinger Reimar.Doeffinger at gmx.de
Thu May 16 07:46:29 CEST 2013


On 29.03.2013, at 15:00, Aubin Paul <clist at outlyer.org> wrote:
> 1. using -DPIC with YASM to allow ffmpeg to compile properly

I don't see that in your patch.

> 2. Using -Wl,-pie to fix linking since -pie -fpie is incorrect under
> Darwin's clang

Why would that be incorrect? Using -Wl means your passing it to the linker behind the compiler's back.
However in particular -fpie is an option the compiler absolutely must see.

> 3. --mdynamic-no-pic breaks compilation due to security features in
> newer versions of Mac OS X

Please provide more details.

> Clang does support PIC but the configure check breaks due to the
> inclusion of -fpie -pie so I added a separate check for clang and
> darwin to include the right flags. After that, PIC is successfully
> detected and works fine.

We discussed that before, and the only conclusion we could make that the compiler is simply broken, adding -fpie should not undefine PIC.
Do you have any other information?

> Attached a patch which fixes the issue and should not affect any other
> platforms.

I see it affect older OS X and gcc in potentially bad ways, the removal especially of -mdynamic-no-pic having a serious bad impact on performance of PPC builds.


More information about the MPlayer-dev-eng mailing list