title: Detect ld flags in m4 files
body: <p>I have a <code>.m4</code> file that appends some flags to the linker, one of which sets the rpath flag. This script was originally written for a GNU version of ld that uses <code>-rpath=&lt;value&gt;</code>, however, I'm trying to run the script on OSX, where the version of ld uses <code>-rpath &lt;value&gt;</code>. The end result is that I see this in my config.log:</p>
  
  <blockquote>
    <p>ld: unknown option: -rpath=path/to/stuff</p>
  </blockquote>
  
  <p>Is there a way to detect something about how ld expects flags to be passed in from within my <code>.m4</code> file so I can output the right format depending on the version available?</p>