I had a similar issue and used the following workaround: in alidist/yaml-cpp.sh I simply commented out the line starting with “prefer_system:” and the following two lines as well. That way aliBuild always builds yaml-cpp, although you have the dependency already installed on your system. And that way cmake finds yaml-cpp correctly during the compilation of FairRoot.
Of course this is not a real fix, since it builds yaml-cpp although that should not be necessary. But it works well for me…