<commit_before># ============================================================================
# Copyright (c) 2011-2012 University of Pennsylvania
# Copyright (c) 2013-2014 <NAME>
# All rights reserved.
#
# See COPYING file for license information or visit
# http://opensource.andreasschuh.com/cmake-basis/download.html#license
# ============================================================================

##############################################################################
# @file  ExportTools.cmake
# @brief Functions and macros for the export of targets.
#
# @ingroup CMakeTools
##############################################################################

if (__BASIS_EXPORTIMPORTTOOLS_INCLUDED)
  return ()
else ()
  set (__BASIS_EXPORTIMPORTTOOLS_INCLUDED TRUE)
endif ()


## @addtogroup CMakeUtilities
#  @{


# ----------------------------------------------------------------------------
## @brief Add target to export set.
#
# Targets are added to the export set named after the top-level project.
# This is necessary because CMake does not allow us to split the exports
# into different sets when there are inter-dependencies between library
# targets of the modules.
#
# @param[out] EXPORT_OPTION Export option for install() command including
#                           the EXPORT option name. Set to an empty string
#                           if target is not installed.
# @param[in]  TARGET_UID    UID of target to be exported.
# @param[in]  IS_TEST       Whether given target is a test executable or library.
# @param[in]  ARGN          Optional installation destinations.
function (basis_add_export_target EXPORT_OPTION TARGET_UID IS_TEST)
  set (EXPORT_SET "${TOPLEVEL_PROJECT_NAME}")
  if (IS_TEST)
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY TEST_EXPORT_TARGETS "${TARGET_UID}")
  else ()
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY EXPORT_TARGETS "${TARGET_UID}")
    if (ARGN)
      basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY INSTALL_EXPORT_TARGETS "${TARGET_UID}")
    endif ()
    set (${EXPORT_OPTION} "EXPORT;${EXPORT_SET}" PARENT_SCOPE)
  endif ()
endfunction ()

# ----------------------------------------------------------------------------
## @brief Add target to custom export set.
#
# Targets are added to the export set named after the top-level project.
# This is necessary because CMake does not allow us to split the exports
# into different sets when there are inter-dependencies between library
# targets of the modules.
#
# @param[in]  TARGET_UID UID of target to add to the export set.
# @param[in]  IS_TEST    Whether given target is a test executable or library.
function (basis_add_custom_export_target TARGET_UID IS_TEST)
  set (EXPORT_SET "${TOPLEVEL_PROJECT_NAME}")
  if (IS_TEST)
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY TEST_EXPORT_TARGETS "${TARGET_UID}")
  else ()
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY CUSTOM_EXPORT_TARGETS "${TARGET_UID}")
  endif ()
endfunction ()

# ----------------------------------------------------------------------------
## @brief Get soname of object file.
#
# This function extracts the soname from object files in the ELF format on
# systems where the objdump command is available. On all other systems,<commit_msg>enh: Optional basis_add_export_target argument can be boolean FALSE [BASIS]<commit_after># ============================================================================
# Copyright (c) 2011-2012 University of Pennsylvania
# Copyright (c) 2013-2014 <NAME>
# All rights reserved.
#
# See COPYING file for license information or visit
# http://opensource.andreasschuh.com/cmake-basis/download.html#license
# ============================================================================

##############################################################################
# @file  ExportTools.cmake
# @brief Functions and macros for the export of targets.
#
# @ingroup CMakeTools
##############################################################################

if (__BASIS_EXPORTIMPORTTOOLS_INCLUDED)
  return ()
else ()
  set (__BASIS_EXPORTIMPORTTOOLS_INCLUDED TRUE)
endif ()


## @addtogroup CMakeUtilities
#  @{


# ----------------------------------------------------------------------------
## @brief Add target to export set.
#
# Targets are added to the export set named after the top-level project.
# This is necessary because CMake does not allow us to split the exports
# into different sets when there are inter-dependencies between library
# targets of the modules.
#
# @param[out] EXPORT_OPTION Export option for install() command including
#                           the EXPORT option name. Set to an empty string
#                           if target is not installed (see @p ARGN).
# @param[in]  TARGET_UID    UID of target to be exported.
# @param[in]  IS_TEST       Whether given target is a test executable or library.
# @param[in]  ARGN          Optional installation destinations. The actual
#                           values are ignored and argument @c TRUE should
#                           be used if no specific destination paths are given,
#                           but the target is also to be included in the export
#                           set used for installation. If ARGN is empty, the
#                           target is only added to the build tree export set.
#                           When @p ARGN is @c 0, @c FALSE or @c OFF, the target
#                           is not added to list of installation exports.
function (basis_add_export_target EXPORT_OPTION TARGET_UID IS_TEST)
  set (EXPORT_SET "${TOPLEVEL_PROJECT_NAME}")
  if (IS_TEST)
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY TEST_EXPORT_TARGETS "${TARGET_UID}")
    set (${EXPORT_OPTION} "" PARENT_SCOPE)
  else ()
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY EXPORT_TARGETS "${TARGET_UID}")
    if (ARGN AND NOT "^${ARGN}$" STREQUAL "^(0|false|FALSE|off|OFF)$")
      basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY INSTALL_EXPORT_TARGETS "${TARGET_UID}")
      set (${EXPORT_OPTION} "EXPORT;${EXPORT_SET}" PARENT_SCOPE)
    else ()
      set (${EXPORT_OPTION} "" PARENT_SCOPE)
    endif ()
  endif ()
endfunction ()

# ----------------------------------------------------------------------------
## @brief Add target to custom export set.
#
# Targets are added to the export set named after the top-level project.
# This is necessary because CMake does not allow us to split the exports
# into different sets when there are inter-dependencies between library
# targets of the modules.
#
# @param[in]  TARGET_UID UID of target to add to the export set.
# @param[in]  IS_TEST    Whether given target is a test executable or library.
function (basis_add_custom_export_target TARGET_UID IS_TEST)
  set (EXPORT_SET "${TOPLEVEL_PROJECT_NAME}")
  if (IS_TEST)
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY TEST_EXPORT_TARGETS "${TARGET_UID}")
  else ()
    basis_set_project_property (PROJECT "${EXPORT_SET}" APPEND PROPERTY CUSTOM_EXPORT_TARGETS "${TARGET_UID}")
  endif ()
endfunction ()

# ----------------------------------------------------------------------------
## @brief Get soname of object file.
#
# This function extracts the soname from object files in the ELF format on
# systems where the objdump command is available. On all other systems,
{'fraction_non_alphanumeric': 0.21428571428571427, 'fraction_numerical': 0.00453091684434968, 'mean_word_length': 3.1078270388615215, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6411435', 'n_tokens_mistral': 2026, 'n_tokens_neox': 1898, 'n_words': 692}