diff options
Diffstat (limited to 'prefix-stack-ccwrap')
-rw-r--r-- | prefix-stack-ccwrap | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/prefix-stack-ccwrap b/prefix-stack-ccwrap index 93f7a82..4e297ce 100644 --- a/prefix-stack-ccwrap +++ b/prefix-stack-ccwrap @@ -63,17 +63,22 @@ IFS=$save_ifs PATH=${new_path} +pfx_comp=("-I${prefix}/include" "-I${prefix}/usr/include") +pfx_link=("-L${prefix}/usr/lib" "-L${prefix}/lib") # binutils-config's ldwrapper understands '-R' for aix and hpux too. -# parity (winnt) understands -rpath only ... +pfx_link_r=("-Wl,-R,${prefix}/lib" "-Wl,-R,${prefix}/usr/lib") case "${chost}" in -*-winnt*) rpath_opt="-Wl,-rpath," ;; -*) rpath_opt="-Wl,-R," ;; +*-winnt*) + # parity (winnt) understands -rpath only ... + pfx_link_r=("-Wl,-rpath,${prefix}/lib" "-Wl,-rpath,${prefix}/usr/lib") + ;; +*-linux*) + # With gcc, -isystem would avoid warning messages in installed headers, + # but that breaks with AIX host headers. + pfx_comp=("-isystem" "${prefix}/include" "-isystem" "${prefix}/usr/include") + ;; esac -pfx_link=("-L${prefix}/usr/lib" "-L${prefix}/lib") -pfx_link_r=("${rpath_opt}${prefix}/lib" "${rpath_opt}${prefix}/usr/lib") -pfx_comp=("-I${prefix}/include" "-I${prefix}/usr/include") - # ensure we run the right chost program in base prefix [[ ${myself} == *-*-*-* ]] || myself=${chost}-${myself#${chost}-} |