-V<version> and libstdc++
Joseph S. Myers
jsm28@cam.ac.uk
Sat Feb 24 16:56:00 GMT 2001
On Sun, 25 Feb 2001, Carlo Wood wrote:
> Why doesn't using option -V switch libstdc++ to?
> Especially since libstdc++ is part of the gcc distribution,
> it would be handy to get the same headers when I use
> -V2.95.3 as do people who only have 2.95.3 installed.
It is documented that
for the specified target. It is common for the interface to the other
executables to change incompatibly between compiler versions, so
unless the version specified is very close to that of the driver (for
example,`-V 3.0' with a driver program from GCC version 3.0.1), use of
`-V' may not work; for example, using `-V 2.95.2' will not work with a
driver program from GCC 3.0.
This doesn't explicitly discuss headers, but in general -V should be
considered deprecated.
If you couldn't find this documentation or it didn't seem applicable,
please submit a patch to improve the manual, or a PR discussing the
problem. (This applies in general: never tolerate deficiencies in the
manual or treat them as something everyone knows about; fix them, or
submit PRs about them, no matter how trivial they might seem.)
> Apart from the question why it doesn't work out-of-the-box,
> I really need to test compiler/libstdc++ combinations (headers
> and binaries) for multiple releases of gcc. How can I best
> achieve this?
Install each version with a different --prefix. For the C compiler it
suffices to keep copies of the old gcc driver executables around, but that
won't handle the C++ headers installed outside of libsubdir.
--
Joseph S. Myers
jsm28@cam.ac.uk
More information about the Gcc
mailing list