Some time ago I decided to take a few of the C++11 features for a spin on Ubuntu 12.04, but the default Clang version for this distro (3.06) wasn’t good enough so I decided to build from source.
I ended up following these instructions to the letter and it was a walk in the park…until I built a tiny little project and a build time that previously took ~30 seconds suddenly took 4 minutes! Shock and horror!
After much reading, searching and re-reading I finally realised that I didn’t pay any attention to one of the bullet points under step six:
- This builds both LLVM and Clang for debug mode.
I simply cleaned, reconfigured with the “–enable-optimized” flag set, rebuilt and the universe returned to normal.
Read the manual man…read the manual…