<commit_before>set(interface_headers coreinterfaces.hh gctypes-decl.hh)

foreach(header ${interface_headers})
add_custom_target(${header}.gen
  COMMAND ${LLVM_BUILD_DIR}/bin/clang++ -std=c++0x -femit-ast -o${header}.ast -DMOZART_GENERATOR ${CMAKE_CURRENT_SOURCE_DIR}/${header}
  COMMAND ${CMAKE_CURRENT_BINARY_DIR}/../../generator/main/generator ${header}.ast
  DEPENDS ${header}
  WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
  COMMENT Generating Interfaces for ${header}
  VERBATIM)
endforeach(header)
string(REPLACE ".hh" ".hh.gen" interface_headers_gen "${interface_headers}")

include_directories(${CMAKE_CURRENT_BINARY_DIR})

add_executable(vm main.cc emulate.cc corebuiltins.cc
               memmanager.cc gcollect.cc)
add_dependencies(vm ${interface_headers_gen})<commit_msg>Compile the VM as a static library.<commit_after>set(interface_headers coreinterfaces.hh gctypes-decl.hh)

foreach(header ${interface_headers})
add_custom_target(${header}.gen
  COMMAND ${LLVM_BUILD_DIR}/bin/clang++ -std=c++0x -femit-ast -o${header}.ast -DMOZART_GENERATOR ${CMAKE_CURRENT_SOURCE_DIR}/${header}
  COMMAND ${CMAKE_CURRENT_BINARY_DIR}/../../generator/main/generator ${header}.ast
  DEPENDS ${header}
  WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
  COMMENT Generating Interfaces for ${header}
  VERBATIM)
endforeach(header)
string(REPLACE ".hh" ".hh.gen" interface_headers_gen "${interface_headers}")

include_directories(${CMAKE_CURRENT_BINARY_DIR})

add_library(mozartvm emulate.cc corebuiltins.cc memmanager.cc gcollect.cc)
add_dependencies(mozartvm ${interface_headers_gen})

add_executable(vm main.cc)
target_link_libraries(vm mozartvm)

{'fraction_non_alphanumeric': 0.1285018270401949, 'fraction_numerical': 0.001218026796589525, 'mean_word_length': 7.215, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4707677', 'n_tokens_mistral': 579, 'n_tokens_neox': 565, 'n_words': 90}