To build against different versions of the SDK, simply include the PRI that you want to build against in your project's .pro file. For example
For 100.4, add the following to your .pro:
include(/InstallDir/ArcGIS_SDKs/Qt100.4/sdk/ideintegration/arcgis_runtime_qml_cpp.pri)
For 100.5, add the following to your .pro
include(/InstallDir/ArcGIS_SDKs/Qt100.5/sdk/ideintegration/arcgis_runtime_qml_cpp.pri)
For convenience, we have everything setup in our DSA app and our app templates so that all you need to do is change the version variable, and it'll update the include path automatically. For example, once we release 100.6, you can update the Vehicle version of DSA by changing this variable, running qmake, and rebuilding - https://github.com/Esri/dynamic-situational-awareness-qt/blob/master/Vehicle/Vehicle.pro#L23