# HG changeset patch # User reimar # Date 1364982030 0 # Node ID 5f730ed5b3d20013fd095299cb7811d0d090b3a2 # Parent 5ecbf382ff267583ad232453061afa9c31ce7545 Add workaround to allow compiling 64 bit MPlayer with clang on OSX. diff -r 5ecbf382ff26 -r 5f730ed5b3d2 configure --- a/configure Mon Apr 01 18:16:20 2013 +0000 +++ b/configure Wed Apr 03 09:40:30 2013 +0000 @@ -2851,9 +2851,16 @@ echocheck "PIC" def_pic='#define CONFIG_PIC 0' pic=no -cpp_condition_check '' 'defined(__PIC__) || defined(__pic__) || defined(PIC)' && - pic=yes && extra_cflags="$extra_cflags -DPIC" && def_pic='#define CONFIG_PIC 1' +cpp_condition_check '' 'defined(__PIC__) || defined(__pic__) || defined(PIC)' && pic=yes +# This check is needed to work around issues with clang on OSX when compiling 64 bit relocatable binaries. +if x86_64 && test "$relocatable" = "yes" && test "$pic" = "no"; then + res_comment="Broken compiler incorrectly claims PIC not necessary for PIE" + pic=yes +fi echores $pic +if test "$pic" = "yes" ; then + extra_cflags="$extra_cflags -DPIC" && def_pic='#define CONFIG_PIC 1' +fi def_bswap='#define HAVE_BSWAP 0'