Question & Answer
Question
What is the the significance of the "-V2.8.1" as seen in the example "LIBSETCCFLAGS = -V2.8.1 -fno-exceptions -fno-rtti" found in the IBM® Rational® Rose RealTime® on line Help (Adapting Rational Rose RealTime for Target Environments > Porting the TargetRTS > Libset makefile?
Answer
The option is used to ensure that a specific version of the compiler is used.
For g++, -Vx.x.x ensures that the compiler version is explicitly stated. This prevents the wrong version of the compiler from being used.
Note: If the -Vx.x.x does not match the compiler installed, errors like the following may be experienced.
!> Compiling MyComponent g++: installation problem, cannot exec `cpp0': No such file or directory g++: file path prefix `/usr/lib/gcc-lib/i386-linux/egcs-2.91.66/' never used
If there is a problem with compiler mismatch, the TargetRTS can easily be ported to a new version. A good example of this is given in the technote Porting Rose RealTime's TargetRTS to a new minor version of a supported compiler
Note: The "-V" option might not be available for all compilers. Consult your compiler vendor's documentation for more information on this and other compiler options.
Related Information
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg21131275