cmake_minimum_required(VERSION 3.10) project(meshalyzer VERSION 2.0 DESCRIPTION "Graphical program for display time dependent data on 3D finite elment meshes" LANGUAGES C CXX ) add_subdirectory(src) if(APPLE) set(MESHALYZER_EXE "meshalyzer.app/Contents/MacOS/meshalyzer") elseif(UNIX) set(MESHALYZER_EXE "meshalyzer") endif() add_custom_target(link_exe ALL COMMAND ln -sf ${CMAKE_BINARY_DIR}/src/${MESHALYZER_EXE} ${CMAKE_CURRENT_LIST_DIR} COMMENT "Create link to meshalyzer executable" VERBATIM ) add_dependencies(link_exe meshalyzer)