From 6d7cb3760b90da5e32b61490cf8fe60640140f71 Mon Sep 17 00:00:00 2001 From: kelson8 Date: Mon, 4 Nov 2024 14:47:49 -0500 Subject: [PATCH] Move files into src folder. --- CMakeLists.txt | 15 +++++++++++---- hello.c => src/hello.c | 0 hello.h => src/hello.h | 0 main.c => src/main.c | 0 math_functions.c => src/math_functions.c | 0 math_functions.h => src/math_functions.h | 0 struct_test.c => src/struct_test.c | 0 struct_test.h => src/struct_test.h | 0 8 files changed, 11 insertions(+), 4 deletions(-) rename hello.c => src/hello.c (100%) rename hello.h => src/hello.h (100%) rename main.c => src/main.c (100%) rename math_functions.c => src/math_functions.c (100%) rename math_functions.h => src/math_functions.h (100%) rename struct_test.c => src/struct_test.c (100%) rename struct_test.h => src/struct_test.h (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1d1ec04..c43893a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,11 +2,18 @@ cmake_minimum_required(VERSION 3.5.0) project(Test_Project VERSION 0.1.0 LANGUAGES C) # Add more c files in here +# add_executable(Test_Project +# main.c +# hello.c +# math_functions.c +# struct_test.c +# ) + add_executable(Test_Project -main.c -hello.c -math_functions.c -struct_test.c +src/main.c +src/hello.c +src/math_functions.c +src/struct_test.c ) # https://discourse.cmake.org/t/how-to-properly-include-header-files/4762 diff --git a/hello.c b/src/hello.c similarity index 100% rename from hello.c rename to src/hello.c diff --git a/hello.h b/src/hello.h similarity index 100% rename from hello.h rename to src/hello.h diff --git a/main.c b/src/main.c similarity index 100% rename from main.c rename to src/main.c diff --git a/math_functions.c b/src/math_functions.c similarity index 100% rename from math_functions.c rename to src/math_functions.c diff --git a/math_functions.h b/src/math_functions.h similarity index 100% rename from math_functions.h rename to src/math_functions.h diff --git a/struct_test.c b/src/struct_test.c similarity index 100% rename from struct_test.c rename to src/struct_test.c diff --git a/struct_test.h b/src/struct_test.h similarity index 100% rename from struct_test.h rename to src/struct_test.h