On Fri, 28 Jan 2011, Simon Baldwin wrote: > A quick question about -no-canonical-prefixes... > > By default, gcc calls realpath() on prefixes generated relative to > argv[0] in the gcc driver. If gcc is held as a "symlink farm" the > realpath() makes it fail (absent a lot of messy -B, -L, -isytem and so > on). It complains about not finding cc1 or cc1plus in libexec. > > -no-canonical-prefixes turns off realpath() to make gcc work cleanly > when stored this way. > > Does anyone know a reason why -no-canonical-prefixes could not become > the gcc default? Are there gcc configurations that must have the > realpath()? The flag is benign on normally laid out gcc > installations.
I think the point of the default is that you can create a symlink in your PATH to a single gcc binary in a tree installed elsewhere, and that will work OK because the symlink is resolved before locating the rest of the tree. Certainly I use such symlinks for convenient access to installations of different GCC versions. -- Joseph S. Myers jos...@codesourcery.com