Skip to content

Commit 6d1fdd8

Browse files
committed
Merge release 5.0
2 parents 19fef01 + 03306b6 commit 6d1fdd8

File tree

342 files changed

+6059
-7628
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

342 files changed

+6059
-7628
lines changed

.clang-format

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,8 @@ SpacesInParentheses: false
99
SpaceAfterCStyleCast: true
1010
AlignConsecutiveDeclarations: true
1111
AlignConsecutiveAssignments: true
12+
AccessModifierOffset: -4
13+
IndentAccessModifiers: false
14+
SpacesBeforeTrailingComments: 2
15+
AlignTrailingComments: true
16+
AllowShortIfStatementsOnASingleLine: false
149 KB
Loading
159 KB
Loading

.github/screenshots/ll1old.png

491 KB
Loading

.github/screenshots/noll1.png

274 KB
Loading

.github/screenshots/output.png

211 KB
Loading
253 KB
Loading

.github/screenshots/tree.png

743 KB
Loading

.gitignore

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
*.exe
3131
*.out
3232
*.app
33-
parser
33+
ll1
3434

3535
# Vscode
3636
.vscode
@@ -40,4 +40,8 @@ lex.l
4040
lex.yy.c
4141

4242
# IDEA
43-
.idea
43+
.idea
44+
45+
build
46+
47+
gen.py

CMakeLists.txt

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
cmake_minimum_required(VERSION 3.16)
2+
3+
project(LL1Checker VERSION 5.0.0 LANGUAGES CXX)
4+
5+
cmake_policy(SET CMP0077 NEW)
6+
7+
set(CMAKE_CXX_STANDARD 20)
8+
set(CMAKE_CXX_STANDARD_REQUIRED ON)
9+
set(CMAKE_CXX_EXTENSIONS OFF)
10+
11+
option(LL1CHECKER_FORCE_STATIC_RUNTIME
12+
"Link C++ runtime and dependencies statically in Release builds" OFF)
13+
14+
if(LL1CHECKER_FORCE_STATIC_RUNTIME)
15+
set(BUILD_SHARED_LIBS OFF)
16+
if(MSVC)
17+
set(CMAKE_MSVC_RUNTIME_LIBRARY
18+
"MultiThreaded$<$<CONFIG:Debug>:Debug>")
19+
else()
20+
add_link_options($<$<CONFIG:Release>:-static>
21+
$<$<CONFIG:Release>:-static-libstdc++>
22+
$<$<CONFIG:Release>:-static-libgcc>)
23+
endif()
24+
set(Boost_USE_STATIC_LIBS ON)
25+
endif()
26+
27+
set(LIB_NAME ll1_core)
28+
set(EXECUTABLE ll1)
29+
30+
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
31+
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Build type" FORCE)
32+
endif()
33+
34+
find_package(Boost 1.78 REQUIRED CONFIG COMPONENTS headers)
35+
36+
find_package(cxxopts QUIET CONFIG)
37+
if(NOT cxxopts_FOUND)
38+
find_path(CXXOPTS_INCLUDE_DIR cxxopts.hpp)
39+
if(CXXOPTS_INCLUDE_DIR)
40+
add_library(cxxopts INTERFACE)
41+
add_library(cxxopts::cxxopts ALIAS cxxopts)
42+
target_include_directories(cxxopts INTERFACE ${CXXOPTS_INCLUDE_DIR})
43+
else()
44+
include(FetchContent)
45+
FetchContent_Declare(
46+
cxxopts
47+
GIT_REPOSITORY https://github.com/jarro2783/cxxopts.git
48+
GIT_TAG v3.1.1
49+
)
50+
set(FETCHCONTENT_UPDATES_DISCONNECTED ON)
51+
FetchContent_MakeAvailable(cxxopts)
52+
if(TARGET cxxopts)
53+
add_library(cxxopts::cxxopts ALIAS cxxopts)
54+
endif()
55+
endif()
56+
endif()
57+
58+
add_subdirectory(src)
59+
add_subdirectory(app)

0 commit comments

Comments
 (0)