diff options
author | dx <aryadevchavali1@gmail.com> | 2020-05-23 19:35:43 +0100 |
---|---|---|
committer | dx <aryadevchavali1@gmail.com> | 2020-05-23 19:35:43 +0100 |
commit | e17e84e92d77c5f8fc40ec5bcbc0eb2e9f212dbf (patch) | |
tree | 415e8913d8376adf3007d695961c48494dc77bd4 /Compiler | |
parent | b363c018c5e1af140563a82ae0bcada3b9a60910 (diff) | |
download | mdhtml-e17e84e92d77c5f8fc40ec5bcbc0eb2e9f212dbf.tar.gz mdhtml-e17e84e92d77c5f8fc40ec5bcbc0eb2e9f212dbf.tar.bz2 mdhtml-e17e84e92d77c5f8fc40ec5bcbc0eb2e9f212dbf.zip |
+c++ project
Decision: to increase productivity as well as make implementing new
features a bit easier, I've decided to move to C++, which has a
standard (and fast) implementation of a regex system. Furthermore, it
has a ton of good features that make working with this system easier.
Diffstat (limited to 'Compiler')
-rw-r--r-- | Compiler/CMakeLists.txt | 33 | ||||
-rw-r--r-- | Compiler/src/main.cpp | 10 |
2 files changed, 43 insertions, 0 deletions
diff --git a/Compiler/CMakeLists.txt b/Compiler/CMakeLists.txt new file mode 100644 index 0000000..321945c --- /dev/null +++ b/Compiler/CMakeLists.txt @@ -0,0 +1,33 @@ +## Metadata +cmake_minimum_required(VERSION 3.10.2) + +set(THIS mdhtml) # Name of project +project(${THIS} CXX) + +set(CMAKE_CXX_COMPILER clang++) # compiler + +set(CMAKE_CXX_STANDARD 11) # code standard +SET(CMAKE_POSITION_INDEPENDENT_CODE ON) + +## Variables for files +file(GLOB_RECURSE HEADERS "includes/*.hpp") +file(GLOB_RECURSE SRC "src/*.cpp") + +## Debug and release flags +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror") +set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wall -Werror -O0") + +## Executable recipes +add_executable(${THIS} ${SRC} ${HEADERS}) + +## SDL2 INCLUDE +# find_package(SDL2 REQUIRED) +# find_package(SDL2_image REQUIRED) +# include_directories(${SDL2_INCLUDE_DIRS} ${SDL2_IMAGE_INCLUDE_DIRS}) +# target_link_libraries(${THIS} ${SDL2_LIBRARIES} ${SDL2_IMAGE_LIBRARIES}) +## SFML INCLUDE +# find_package(SFML 2.5 COMPONENTS graphics REQUIRED) +# target_link_libraries(${THIS} sfml-graphics) +## FMT INCLUDE +# find_package(fmt) +# target_link_libraries(${THIS} fmt::fmt) diff --git a/Compiler/src/main.cpp b/Compiler/src/main.cpp new file mode 100644 index 0000000..ac686c3 --- /dev/null +++ b/Compiler/src/main.cpp @@ -0,0 +1,10 @@ +#include <iostream> + +using std::cout; +using std::endl; + +int main() +{ + cout << "Hello, world!" << endl; + return 0; +} |