This post was originally published on Admiral Ackbar’s Code Emporium .
This tutorial will show you how you can have different versions of the same library side by side such that it’s easy to change which version your code uses.
For example, I work a lot with OpenCV, the computer vision library. I like to be able to try out different features in the trunk version of the library, but prefer to use a stable release in production settings. It’s actually pretty easy to have both versions on your computer, and select which one you’d like to use at compile time.
The following assumes you’re on a Linux machine. I’ll use OpenCV as an example, but the concept applies to any library.