<commit_before>cmake_minimum_required(VERSION 2.8)

# find glut
find_package(GLUT REQUIRED)
include_directories(${GLUT_INCLUDE_DIRS})
link_directories(${GLUT_LIBRARY_DIRS})
add_definitions(${GLUT_DEFINITIONS})

# find opengl
find_package(OpenGL REQUIRED)
include_directories(${OPENGL_INCLUDE_DIRS})
link_directories(${OPENGL_LIBRARY_DIRS})
add_definitions(${OPENGL_DEFINITIONS})

add_executable(bspline bspline.c)
target_link_libraries(bspline LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})

add_executable(nurbs nurbs.c)
target_link_libraries(nurbs LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})

add_executable(split split.c)
target_link_libraries(split LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})
<commit_msg>check for opengl and glut<commit_after>cmake_minimum_required(VERSION 2.8)

# find glut
find_package(GLUT)
include_directories(${GLUT_INCLUDE_DIRS})
link_directories(${GLUT_LIBRARY_DIRS})
add_definitions(${GLUT_DEFINITIONS})

# find opengl
find_package(OpenGL)
include_directories(${OPENGL_INCLUDE_DIRS})
link_directories(${OPENGL_LIBRARY_DIRS})
add_definitions(${OPENGL_DEFINITIONS})

if(GLUT_FOUND AND OPENGL_FOUND)
  add_executable(bspline bspline.c)
  target_link_libraries(bspline LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})
  
  add_executable(nurbs nurbs.c)
  target_link_libraries(nurbs LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})
  
  add_executable(split split.c)
  target_link_libraries(split LINK_PUBLIC tinyspline ${OPENGL_LIBRARIES} ${GLUT_LIBRARY})
endif()

{'fraction_non_alphanumeric': 0.09884467265725289, 'fraction_numerical': 0.0025673940949935813, 'mean_word_length': 12.100840336134453, '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': '4973689', 'n_tokens_mistral': 653, 'n_tokens_neox': 604, 'n_words': 80}