Last active
August 18, 2020 07:11
-
-
Save sepfy/d191938e167368d33f954989a8f59d2c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 3.1) | |
project(app) | |
file(GLOB APP_SOURCES "*.c") | |
foreach(sourcefile ${APP_SOURCES}) | |
string(REPLACE ".c" "" appname ${sourcefile}) | |
string(REPLACE "${PROJECT_SOURCE_DIR}/" "" appname ${appname}) | |
add_executable(${appname} ${sourcefile}) | |
endforeach(sourcefile ${APP_SOURCES}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment