remove rpath flag, add c++ header support