add_subdirectory with path outside project produces strange tmp directorys

thanks for fast reply,
I’ve got one more clue. I have printed the binary dir with message("${CMAKE_CURRENT_BINARY_DIR}") and for windows I get:

D:/Projects/Sn/LocalGit/Mbed6-Projects/apps/test-new/cmake_build/STM32F407VE_BLACK/release/GCC_ARM

This is appended to the cmake_build dir which is generated by Mbed. And appending D:… to a path creates an invalid path. On the linux system, /home/me/… is appended, therefore it works.

so it looks my approach with
add_subdirectory("${MBED_PATH}" "${CMAKE_CURRENT_BINARY_DIR}/mbed-os")
is wrong.

Edit:
its still strange. I have changed the binary-path to xx-mbed-os, but the obj files are still placed into the numbered temp dirs. The xx- path is created, but there no object files.