[llvm-commits] [llvm-gcc-4.0] r41902 - /llvm-gcc-4.0/trunk/gcc/config/darwin.h

Chris Lattner clattner at apple.com
Wed Sep 12 17:55:37 PDT 2007


On Sep 12, 2007, at 5:18 PM, Evan Cheng wrote:

> Mac OS X 64-bit is PIC only. Silently ignore -mdynamic-no-pic and - 
> static.

Hi Evan,

This is not obvious, can you please add this as a comment above  
LLVM_SET_TARGET_OPTIONS?  Thanks,

-Chris


> Modified:
>     llvm-gcc-4.0/trunk/gcc/config/darwin.h
>
> Modified: llvm-gcc-4.0/trunk/gcc/config/darwin.h
> URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.0/trunk/gcc/ 
> config/darwin.h?rev=41902&r1=41901&r2=41902&view=diff
>
> ====================================================================== 
> ========
> --- llvm-gcc-4.0/trunk/gcc/config/darwin.h (original)
> +++ llvm-gcc-4.0/trunk/gcc/config/darwin.h Wed Sep 12 19:18:50 2007
> @@ -1721,10 +1721,11 @@
>  const char *darwin_objc_llvm_implicit_target_global_var_section 
> (tree);
>
>  #define LLVM_SET_TARGET_OPTIONS(argvec)              \
> -  if (flag_pic)                                      \
> -    argvec.push_back ("--relocation-model=pic");     \
> -  else if (!MACHO_DYNAMIC_NO_PIC_P)                  \
> -    argvec.push_back ("--relocation-model=static")
> +  if (!TARGET_64BIT)                                 \
> +    if (flag_pic)                                    \
> +      argvec.push_back ("--relocation-model=pic");   \
> +    else if (!MACHO_DYNAMIC_NO_PIC_P)                \
> +      argvec.push_back ("--relocation-model=static")
>  #endif
>  /* APPLE LOCAL end LLVM */
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list