cmake_minimum_required(VERSION 2.8)add_definitions(-DUNICODE -D_UNICODE)set(PROJECT solution)project(${PROJECT})set(COMMON_LIBRARY common)set(DEVICESdevice1device2)set(PROGRAM app)# add devicesforeach(DEVICE ${DEVICES}) add_subdirectory (../${DEVICE}/build ../bin/${DEVICE})endforeach()# add commonadd_subdirectory(../${COMMON_LIBRARY}/build ../bin/${COMMON_LIBRARY})# add programadd_subdirectory(../${PROGRAM}/build ../bin/${PROGRAM})