<commit_before>#TODO: remove commented code
function(install_importlibs)

  if(NOT WIN32)
    return()
  endif()

  set(search_regex  "..IMPORTED_IMPLIB_([A-Z]+)...{_IMPORT_PREFIX}\/lib\/")
  if(NOT WIN32)
    set(search_regex    "..IMPORTED_LOCATION_([A-Z]+)...{_IMPORT_PREFIX}\/lib\/")
  endif()

  file(GLOB_RECURSE
    target_cmake_files
    "${SUPERBUILD_INSTALL_DIR}/lib/cmake/ITK*/*Targets-*.*"
    "${SUPERBUILD_INSTALL_DIR}/lib/cmake/OTB*/*Targets-*.*")

  set(lib_files)
  foreach( target_cmake_file ${target_cmake_files})
    if(PKG_DEBUG)
      message("checking IMPORTED_IMPLIB_RELEASE in ${target_cmake_file}")
    endif()
    file(STRINGS "${target_cmake_file}" matched_items REGEX "${search_regex}")
    foreach(matched_item ${matched_items})
      if(matched_item MATCHES "otbapp_")
	continue()
      endif()
      string(REGEX REPLACE "${search_regex}" "" lib_file "${matched_item}")
      string(REGEX REPLACE "\"" "" lib_file "${lib_file}")
      list(APPEND lib_files "${SUPERBUILD_INSTALL_DIR}/lib/${lib_file}")
    endforeach()
  endforeach()

  foreach(lib_file ${lib_files})
    if(PKG_DEBUG)
      message("SPECIAL install_rule for lib_file: ${lib_file}")
    endif()
    install_rule(${lib_file})
  endforeach()


#RK: to hell with cmake targets files.
  # file(GLOB ALL_EXTRA_FILES
    # ${SUPERBUILD_INSTALL_DIR}/lib/*boost*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*glut*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*QtXml*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*kml*${LIB_EXT}*
      # )

      
    # file(GLOB MY_LIB_FILES 
    # "${SUPERBUILD_INSTALL_DIR}/lib/*${STATIC_LIB_EXT}"
    # "${SUPERBUILD_INSTALL_DIR}/${DEST_LIB_DIR}/${LIB_PREFIX}itk*${LIB_EXT}*"
    # "${SUPERBUILD_INSTALL_DIR}/${DEST_LIB_DIR}/${LIB_PREFIX}ITK*${LIB_EXT}*"<commit_msg>BUG: windows need all .lib files for devel.<commit_after>#TODO: remove commented code
function(install_importlibs)

  if(NOT WIN32)
    return()
  endif()

  #ALL .lib files are required for building
  #eg: gdal.dll will have gdal_i.lib which is
  #needed when you do cmake configure for projects
  #using OTB. Hence the *.lib regex is non optional
  #and cannot be optimized at any level.
  #Only thing you can control is to create only those
  #required .lib files in install directory. This exclude
  #all otb*.*testdriver.lib etc..
  file(GLOB import_lib_files 
    "${SUPERBUILD_INSTALL_DIR}/lib/*.lib")
  foreach( import_lib_file ${import_lib_files})
    install_rule(${import_lib_file})
  endforeach()


#RK: to hell with cmake targets files.
  # file(GLOB ALL_EXTRA_FILES
    # ${SUPERBUILD_INSTALL_DIR}/lib/*boost*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*glut*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*QtXml*${LIB_EXT}*
    # ${SUPERBUILD_INSTALL_DIR}/lib/*kml*${LIB_EXT}*
      # )

      
    # file(GLOB MY_LIB_FILES 
    # "${SUPERBUILD_INSTALL_DIR}/lib/*${STATIC_LIB_EXT}"
    # "${SUPERBUILD_INSTALL_DIR}/${DEST_LIB_DIR}/${LIB_PREFIX}itk*${LIB_EXT}*"
    # "${SUPERBUILD_INSTALL_DIR}/${DEST_LIB_DIR}/${LIB_PREFIX}ITK*${LIB_EXT}*"
{'fraction_non_alphanumeric': 0.15620915032679739, 'fraction_numerical': 0.00196078431372549, 'mean_word_length': 4.45632798573975, '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': '800175', 'n_tokens_mistral': 1169, 'n_tokens_neox': 1112, 'n_words': 186}