Minor alterations to CMake to make macros more generic
This commit is contained in:
parent
5925934122
commit
ab326c9d54
6 changed files with 23 additions and 3 deletions
|
@ -1,11 +1,13 @@
|
||||||
project(BlogParser)
|
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.20)
|
cmake_minimum_required(VERSION 3.20)
|
||||||
set(CMAKE_BUILD_TYPE Debug) # Debug or Release
|
set(CMAKE_BUILD_TYPE Debug) # Debug or Release
|
||||||
set(CMAKE_CXX_STANDARD 17)
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED True)
|
set(CMAKE_CXX_STANDARD_REQUIRED True)
|
||||||
set(CMAKE_EXPORT_COMPILE_COMMANDS 1) # export our compiler flags for clangd to read
|
set(CMAKE_EXPORT_COMPILE_COMMANDS 1) # export our compiler flags for clangd to read
|
||||||
|
|
||||||
|
project(BlogParser)
|
||||||
|
|
||||||
|
configure_file(MacroDefinitions.h.in MacroDefinitions.h)
|
||||||
|
|
||||||
add_subdirectory(Src)
|
add_subdirectory(Src)
|
||||||
add_subdirectory(Tests)
|
add_subdirectory(Tests)
|
||||||
|
|
||||||
|
|
8
MacroDefinitions.h.in
Normal file
8
MacroDefinitions.h.in
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define TEST_RESOURCE_FOLDER "${CMAKE_SOURCE_DIR}/Resources/Tests"
|
||||||
|
#define RESOURCE_FOLDER "${CMAKE_SOURCE_DIR}/Resources"
|
||||||
|
|
||||||
|
#define SOURCE_FILE_FOLDER "${CMAKE_SOURCE_DIR}/Resources/Input"
|
||||||
|
#define OUTPUT_FILE_FOLDER "${CMAKE_SOURCE_DIR}/Resources/Output"
|
||||||
|
|
Binary file not shown.
|
@ -11,7 +11,7 @@
|
||||||
#include "Page.h"
|
#include "Page.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Class that builds blog pages, takes a template page to plut the blog-post in
|
* Class that builds blog pages, takes a template page to put the blog-post in
|
||||||
* along with an optional artifleIdentifier. The template is searched for this
|
* along with an optional artifleIdentifier. The template is searched for this
|
||||||
* and the blog is placed after it.
|
* and the blog is placed after it.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -8,6 +8,7 @@ set(CMAKE_DEPENDS_GENERATOR "Unix Makefiles")
|
||||||
set(CMAKE_MAKEFILE_DEPENDS
|
set(CMAKE_MAKEFILE_DEPENDS
|
||||||
"CMakeCache.txt"
|
"CMakeCache.txt"
|
||||||
"../CMakeLists.txt"
|
"../CMakeLists.txt"
|
||||||
|
"../MacroDefinitions.h.in"
|
||||||
"../Src/CMakeLists.txt"
|
"../Src/CMakeLists.txt"
|
||||||
"../Src/Libs/CMakeLists.txt"
|
"../Src/Libs/CMakeLists.txt"
|
||||||
"../Tests/CMakeLists.txt"
|
"../Tests/CMakeLists.txt"
|
||||||
|
@ -45,6 +46,7 @@ set(CMAKE_MAKEFILE_OUTPUTS
|
||||||
|
|
||||||
# Byproducts of CMake generate step:
|
# Byproducts of CMake generate step:
|
||||||
set(CMAKE_MAKEFILE_PRODUCTS
|
set(CMAKE_MAKEFILE_PRODUCTS
|
||||||
|
"MacroDefinitions.h"
|
||||||
"CMakeFiles/CMakeDirectoryInformation.cmake"
|
"CMakeFiles/CMakeDirectoryInformation.cmake"
|
||||||
"Src/CMakeFiles/CMakeDirectoryInformation.cmake"
|
"Src/CMakeFiles/CMakeDirectoryInformation.cmake"
|
||||||
"Src/Libs/CMakeFiles/CMakeDirectoryInformation.cmake"
|
"Src/Libs/CMakeFiles/CMakeDirectoryInformation.cmake"
|
||||||
|
|
8
build/MacroDefinitions.h
Normal file
8
build/MacroDefinitions.h
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define TEST_RESOURCE_FOLDER "/home/rosia/Programming/Cpp/BlogParser/Resources/Tests"
|
||||||
|
#define RESOURCE_FOLDER "/home/rosia/Programming/Cpp/BlogParser/Resources"
|
||||||
|
|
||||||
|
#define SOURCE_FILE_FOLDER "/home/rosia/Programming/Cpp/BlogParser/Resources/Input"
|
||||||
|
#define OUTPUT_FILE_FOLDER "/home/rosia/Programming/Cpp/BlogParser/Resources/Output"
|
||||||
|
|
Loading…
Add table
Reference in a new issue