Update cmake to allow C++ and fix maxos compile error
Signed-off-by: Anita Anderson <anita@ansan.io>
This commit is contained in:
parent
39756f4e89
commit
c9c83efaa0
7
.editorconfig
Normal file
7
.editorconfig
Normal file
|
@ -0,0 +1,7 @@
|
|||
[*]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
|
@ -1,21 +1,26 @@
|
|||
cmake_minimum_required(VERSION 3.21)
|
||||
project(Erythro C)
|
||||
project(Erythro C CXX)
|
||||
|
||||
set(CMAKE_C_STANDARD 11)
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
|
||||
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
||||
|
||||
include_directories(include)
|
||||
|
||||
add_executable(Erythro
|
||||
include/Data.h
|
||||
include/Defs.h
|
||||
src/Assembler.c
|
||||
src/Delegate.c
|
||||
src/Dump.c
|
||||
src/Lexer.c
|
||||
src/Main.c
|
||||
src/Parser.c
|
||||
src/Pointers.c
|
||||
src/Statements.c
|
||||
src/Symbols.c
|
||||
src/Types.c
|
||||
src/Importer.c)
|
||||
set(ERYTHRO_SRC
|
||||
src/Assembler.c
|
||||
src/Delegate.c
|
||||
src/Dump.c
|
||||
src/Lexer.c
|
||||
src/Main.c
|
||||
src/Parser.c
|
||||
src/Pointers.c
|
||||
src/Statements.c
|
||||
src/Symbols.c
|
||||
src/Types.c
|
||||
src/Importer.c
|
||||
)
|
||||
|
||||
add_executable(eryc ${ERYTHRO_SRC})
|
||||
|
|
|
@ -12,6 +12,11 @@
|
|||
#include <limits.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
|
||||
/**
|
||||
* The function of the importer is to read in definitions from a file, and store
|
||||
* them into the symbol tables.
|
||||
|
|
Loading…
Reference in New Issue
Block a user