<commit_before># many thanks go to <NAME> for writing the code this file is based on
#  http://www.cmake.org/pipermail/cmake/2006-August/010794.html
#
# much later i also found this:
#  http://tobias.rautenkranz.ch/cmake/doxygen/
# but it is hard to understand...
  
IF (BUILD_LIBNOISE_DOCUMENTATION)

FIND_PACKAGE(Doxygen)

IF(DOXYGEN_FOUND)
  SET(DOXYGEN_LANGUAGE "English" CACHE STRING "Language used by doxygen")
  MARK_AS_ADVANCED(DOXYGEN_LANGUAGE)

  # you could also set the version with this, see Doxygen.in
  # there you will find a line like this: 
  #      PROJECT_NUMBER         = @LIBNOISE_VERSION@
  # @LIBNOISE_VERSION@ is then replaced by our global LIBNOISE_VERSION
  #
  # for instance you could uncomment the next 3 lines and change the version for testing
  # SET(LIBNOISE_VERSION
  #     "1.2.3-foo500"
  # )

  # doxygen can reference external images with IMAGE_PATH, this is how we set it dynamically
  SET( CMAKE_DOXYGEN_IMAGE_PATH
    "${CMAKE_CURRENT_SOURCE_DIR}/img"
  )

  # doxygen searches for source code (defined in FILE_PATTERNS, for example: *.cpp *.h)
  # with DOXYGEN_SOURCE_DIR we fill a list of directories and later we write it into
  # the Doxyfile with a REGEX REPLACE (see below)
  SET( DOXYGEN_SOURCE_DIR
    /home/joachim/Desktop/projects/springrts.com-random-map-generator/noise/src
  )

  SET(DOXYGEN_OUTPUT_DIR html)
  STRING(REGEX REPLACE ";" " " CMAKE_DOXYGEN_INPUT_LIST "${DOXYGEN_SOURCE_DIR}")

  CONFIGURE_FILE(Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
  SET(HTML_TARGET "html" )

  ADD_CUSTOM_TARGET(${HTML_TARGET} ALL
		/usr/bin/doxygen ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
		DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)

  INSTALL( DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html/" DESTINATION "/usr/share/doc/libnoise-${LIBNOISE_VERSION}" )

ELSE(DOXYGEN_FOUND)
  MESSAGE (FATAL_ERROR "doxygen binary couldn't be found")
ENDIF(DOXYGEN_FOUND)

ENDIF (BUILD_LIBNOISE_DOCUMENTATION)

<commit_msg>removed static path with a dynamic path<commit_after># many thanks go to <NAME> for writing the code this file is based on
#  http://www.cmake.org/pipermail/cmake/2006-August/010794.html
#
# much later i also found this:
#  http://tobias.rautenkranz.ch/cmake/doxygen/
# but it is hard to understand...
  
IF (BUILD_LIBNOISE_DOCUMENTATION)

FIND_PACKAGE(Doxygen)

IF(DOXYGEN_FOUND)
  SET(DOXYGEN_LANGUAGE "English" CACHE STRING "Language used by doxygen")
  MARK_AS_ADVANCED(DOXYGEN_LANGUAGE)

  # you could also set the version with this, see Doxygen.in
  # there you will find a line like this: 
  #      PROJECT_NUMBER         = @LIBNOISE_VERSION@
  # @LIBNOISE_VERSION@ is then replaced by our global LIBNOISE_VERSION
  #
  # for instance you could uncomment the next 3 lines and change the version for testing
  # SET(LIBNOISE_VERSION
  #     "1.2.3-foo500"
  # )

  # doxygen can reference external images with IMAGE_PATH, this is how we set it dynamically
  SET( CMAKE_DOXYGEN_IMAGE_PATH
    "${CMAKE_CURRENT_SOURCE_DIR}/img"
  )

  # doxygen searches for source code (defined in FILE_PATTERNS, for example: *.cpp *.h)
  # with DOXYGEN_SOURCE_DIR we fill a list of directories and later we write it into
  # the Doxyfile with a REGEX REPLACE (see below)
  SET( DOXYGEN_SOURCE_DIR
    "${CMAKE_SOURCE_DIR}/src"
  )

  SET(DOXYGEN_OUTPUT_DIR html)
  STRING(REGEX REPLACE ";" " " CMAKE_DOXYGEN_INPUT_LIST "${DOXYGEN_SOURCE_DIR}")

  CONFIGURE_FILE(Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
  SET(HTML_TARGET "html" )

  ADD_CUSTOM_TARGET(${HTML_TARGET} ALL
		/usr/bin/doxygen ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
		DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)

  INSTALL( DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html/" DESTINATION "/usr/share/doc/libnoise-${LIBNOISE_VERSION}" )

ELSE(DOXYGEN_FOUND)
  MESSAGE (FATAL_ERROR "doxygen binary couldn't be found")
ENDIF(DOXYGEN_FOUND)

ENDIF (BUILD_LIBNOISE_DOCUMENTATION)


{'fraction_non_alphanumeric': 0.09088568486096807, 'fraction_numerical': 0.008753861997940269, 'mean_word_length': 4.55793991416309, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '2595905', 'n_tokens_mistral': 1504, 'n_tokens_neox': 1385, 'n_words': 352}