<commit_before>find_package(GLEW REQUIRED)
find_package(OpenGL REQUIRED)

add_library(shader SHARED shader.cpp)
if(CMAKE_VERSION VERSION_LESS 3.8)
    target_link_libraries(shader GLEW::GLEW ${OPENGL_gl_LIBRARY})
    include_directories(${OPENGL_INCLUDE_DIR})
else()
    target_link_libraries(shader GLEW::GLEW OpenGL::GL)
endif()
target_enable_warning(shader)
export_library(shader)

add_library(contextUtil SHARED contextUtil.cpp)
if(CMAKE_VERSION VERSION_LESS 3.8)
    target_link_libraries(contextUtil GLEW::GLEW ${OPENGL_gl_LIBRARY})
    include_directories(${OPENGL_INCLUDE_DIR})
else()
    target_link_libraries(contextUtil GLEW::GLEW OpenGL::GL)
endif()
set_target_properties(contextUtil PROPERTIES CXX_STANDARD 11)
set_target_properties(contextUtil PROPERTIES CXX_STANDARD_REQUIRED ON)
target_enable_warning(contextUtil)
export_library(contextUtil)

find_package(Boost COMPONENTS wave)

if(Boost_WAVE_FOUND)
    add_library(cStdShader SHARED cStdShader.cpp)
    set_target_properties(cStdShader PROPERTIES CXX_STANDARD 11)
    set_target_properties(cStdShader PROPERTIES CXX_STANDARD_REQUIRED ON)
    target_link_libraries(cStdShader PRIVATE shader Boost::wave)
    target_enable_warning(cStdShader)
    export_library(cStdShader)
endif()

set(version_config
    ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake)
set(config_dest lib/cmake/${PROJECT_NAME})

include(CMakePackageConfigHelpers)
write_basic_package_version_file(
    ${version_config}
    COMPATIBILITY SameMajorVersion)
install(FILES ${version_config} DESTINATION ${config_dest})

install(EXPORT ${PROJECT_NAME}Config DESTINATION ${config_dest}
    NAMESPACE ${PROJECT_NAME}::
)
<commit_msg>Fixed CMakeLists.txt so that user can select whether GLUtil built as static or shared library with BUILD_SHARED_LIBS flag.<commit_after>find_package(GLEW REQUIRED)
find_package(OpenGL REQUIRED)

add_library(shader shader.cpp)
if(CMAKE_VERSION VERSION_LESS 3.8)
    target_link_libraries(shader GLEW::GLEW ${OPENGL_gl_LIBRARY})
    include_directories(${OPENGL_INCLUDE_DIR})
else()
    target_link_libraries(shader GLEW::GLEW OpenGL::GL)
endif()
target_enable_warning(shader)
export_library(shader)

add_library(contextUtil contextUtil.cpp)
if(CMAKE_VERSION VERSION_LESS 3.8)
    target_link_libraries(contextUtil GLEW::GLEW ${OPENGL_gl_LIBRARY})
    include_directories(${OPENGL_INCLUDE_DIR})
else()
    target_link_libraries(contextUtil GLEW::GLEW OpenGL::GL)
endif()
set_target_properties(contextUtil PROPERTIES CXX_STANDARD 11)
set_target_properties(contextUtil PROPERTIES CXX_STANDARD_REQUIRED ON)
target_enable_warning(contextUtil)
export_library(contextUtil)

find_package(Boost COMPONENTS wave)

if(Boost_WAVE_FOUND)
    add_library(cStdShader cStdShader.cpp)
    set_target_properties(cStdShader PROPERTIES CXX_STANDARD 11)
    set_target_properties(cStdShader PROPERTIES CXX_STANDARD_REQUIRED ON)
    target_link_libraries(cStdShader PRIVATE shader Boost::wave)
    target_enable_warning(cStdShader)
    export_library(cStdShader)
endif()

set(version_config
    ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake)
set(config_dest lib/cmake/${PROJECT_NAME})

include(CMakePackageConfigHelpers)
write_basic_package_version_file(
    ${version_config}
    COMPATIBILITY SameMajorVersion)
install(FILES ${version_config} DESTINATION ${config_dest})

install(EXPORT ${PROJECT_NAME}Config DESTINATION ${config_dest}
    NAMESPACE ${PROJECT_NAME}::
)

{'fraction_non_alphanumeric': 0.08246225319396051, 'fraction_numerical': 0.004645760743321719, 'mean_word_length': 8.759206798866856, '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': '3054216', 'n_tokens_mistral': 1241, 'n_tokens_neox': 1191, 'n_words': 188}