A minimalistic programming language written in C89.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
856 B

преди 4 месеца
преди 2 месеца
преди 4 месеца
преди 4 месеца
преди 4 месеца
  1. cmake_minimum_required(VERSION 3.0)
  2. project(ink C)
  3. set(CMAKE_C_STANDARD 90)
  4. add_library(ink lib.c include/ink.h)
  5. # Uncomment to disable the redundant arithmetic
  6. # add_definitions(-DNOEXTRAARITHMETIC)
  7. # Uncomment to disable array types
  8. # add_definitions(-DNOARRAYLIB)
  9. # Uncomment to disable string literals
  10. # add_definitions(-DNOSTRINGLITERALS)
  11. # Ensures the interpreter doesn't use the standard C library functions
  12. # add_definitions(-DNOSTDLIB)
  13. add_executable(ink_exe main.c)
  14. target_link_libraries(ink_exe PUBLIC ink)
  15. target_include_directories(ink PUBLIC include)
  16. if(MSVC)
  17. target_compile_options(ink PRIVATE /W4 /WX)
  18. else()
  19. target_compile_options(ink PRIVATE -Wall -Wextra -Wpedantic -Werror)
  20. endif()
  21. # Benchmark is broken since the addition to coroutines
  22. # add_executable(ink_bench bench.c)
  23. # target_link_libraries(ink_bench PUBLIC ink)