Added dependency calculation (good for CMake scripts)