Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,7 @@ jobs:
run: |
mkdir crashes
cp output/default/crashes/id:* crashes/
(cd crashes && find . -type f -exec mv '{}' '{}'.ark \;)
tar -czvf crashes.tar.gz crashes

- name: Upload crashes
Expand Down
21 changes: 11 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ if (CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_CLANG OR APPLE)
target_compile_definitions(ArkReactor PRIVATE ARK_USE_COMPUTED_GOTOS=1)

target_compile_options(ArkReactor
PUBLIC
PRIVATE
-Wall -Wextra -pedantic -Wstrict-aliasing
-Wshadow
-Wconversion
Expand All @@ -82,8 +82,8 @@ if (CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_CLANG OR APPLE)
-fno-semantic-interposition
)
if (NOT ARK_BENCHMARKS)
target_compile_options(ArkReactor PUBLIC -Werror)
endif()
target_compile_options(ArkReactor PRIVATE -Werror)
endif ()

# set fmtlib visibility to default
target_compile_definitions(ArkReactor PUBLIC FMT_SHARED)
Expand All @@ -92,7 +92,7 @@ if (CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_CLANG OR APPLE)
# The standard SSH libraries are depreciate on APPLE.
# Thus they currently generate a warning that we have to ignore for now.
# Though we should look to fix that in the future.
target_compile_options(ArkReactor PUBLIC -Wno-deprecated-declarations)
target_compile_options(ArkReactor PRIVATE -Wno-deprecated-declarations)
endif ()

# The following sub-modules link with -L/usr/local/lib
Expand All @@ -104,29 +104,30 @@ if (CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_CLANG OR APPLE)
# lib/modules/msgpack/CMakeFiles/msgpack.dir/__/submodules/msgpack-cpp/src/vrefbuffer.c.o
# lib/modules/msgpack/CMakeFiles/msgpack.dir/__/submodules/msgpack-cpp/src/zone.c.o
target_compile_options(ArkReactor
PUBLIC
PRIVATE
-Wno-unused-command-line-argument)

# The nlohmann/json.hpp external project has unused typedefs in the code
# to compensate for this error we remove the following warning.
if (CMAKE_COMPILER_IS_CLANG)
target_compile_options(ArkReactor PUBLIC -Wno-unused-local-typedef)
target_compile_options(ArkReactor PRIVATE -Wno-unused-local-typedef)
elseif (CMAKE_COMPILER_IS_GNUCXX)
target_compile_options(ArkReactor PUBLIC -Wno-unused-local-typedefs)
target_compile_options(ArkReactor PRIVATE -Wno-unused-local-typedefs)
endif ()

elseif (MSVC)
target_compile_definitions(ArkReactor PRIVATE ARK_USE_COMPUTED_GOTOS=0)
target_compile_options(ArkReactor
PUBLIC
PRIVATE
/W4
/MP4 # build multiple source files concurrently
/EHa # set exception model to standard C++ stack unwinding
/wd4267 # disable warning about data loss (size_t -> int)
/wd4244 # disable warning about data loss (size_t -> char)
/wd4505 # disable warning about unused static function was deleted
/wd4068 # disable warnings about unknown pragmas.
/utf-8)
)
target_compile_options(ArkReactor PUBLIC /utf-8)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /STACK:8000000") # set stack size to 8MB
endif ()

Expand Down Expand Up @@ -252,7 +253,7 @@ if (ARK_BENCHMARKS)
CPMAddPackage(
URI "gh:CodSpeedHQ/codspeed-cpp#5324618a1a14e0aa9a99dcfb467b9c2a57957e19@1.1.1"
SOURCE_SUBDIR google_benchmark)
else()
else ()
CPMAddPackage("gh:google/benchmark@1.8.3")
endif ()

Expand Down
2 changes: 1 addition & 1 deletion src/arkscript/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
# define ARK_ERROR_EXIT_CODE 0
#else
# define ARK_ERROR_EXIT_CODE -1
# define ARK_ERROR_EXIT_CODE (-1)
#endif

int main(int argc, char** argv)
Expand Down
Loading