3 ms·
POSIX mandates c89 and c99 commands. Extend that idea to c++ and the problem is solved.
by ksherlock 11y ago
POSIX mandates c89 and c99 commands. Extend that idea to c++ and the problem is solved.
- pdkl95 11y agoExactly - just add something equivalent to alias c99="gcc --std=c99" alias gc99="gcc --std=gnu99" alias c++11="gcc --std=c++11" alias g++11="gcc --std=gnu++11" and so on to the compile distribution, and leave "gcc" and "g++" at their current defaults for legacy code. If the changes between the dialects are different enough to have compatibility issues, then it makes sense to actually treat them as different languages with different compilers.
- simoncion 11y agoYour c99 alias is unneeded: $ which c99 /usr/bin/c99 $ c99 --version gcc (Gentoo Hardened 4.9.2 p1.5, pie-0.6.2) 4.9.2 [snip]