<commit_before>cmake_minimum_required(VERSION 3.1)

project(amqpcpp)

# ensure c++11 on all compilers
set (CMAKE_CXX_STANDARD 11)

macro (add_sources)
    file (RELATIVE_PATH _relPath "${PROJECT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}")
    foreach (_src ${ARGN})
        if (_relPath)
            list (APPEND SRCS "${_relPath}/${_src}")
        else()
            list (APPEND SRCS "${_src}")
        endif()
    endforeach()
    if (_relPath)
        # propagate SRCS to parent directory
        set (SRCS ${SRCS} PARENT_SCOPE)
    endif()
endmacro()

add_subdirectory(src)
if(AMQPCPP_BUILD_TCP)
    add_subdirectory(src/tcpconnection)
endif()

option(BUILD_SHARED "build shared library" OFF)

if(BUILD_SHARED)
  add_library(amqpcpp SHARED ${SRCS})
  set_target_properties(amqpcpp PROPERTIES SOVERSION 2.7)
  install(TARGETS amqpcpp
          LIBRARY DESTINATION lib
  )
else()
  add_library(amqpcpp STATIC ${SRCS})
  install(TARGETS amqpcpp
          ARCHIVE DESTINATION lib
  )
endif()
Include_directories(${PROJECT_SOURCE_DIR})
install(DIRECTORY include/ DESTINATION include/amqpcpp
        FILES_MATCHING PATTERN "*.h")
install(FILES amqpcpp.h DESTINATION include)

option(BUILD_TUTORIALS "build rabbitmq tutorials" OFF)
if(BUILD_TUTORIALS)
#    add_subdirectory(examples/rabbitmq_tutorials)
endif()<commit_msg>CMakefile cleanup. No functional changes.<commit_after>cmake_minimum_required(VERSION 3.1)

project(amqpcpp)

# ensure c++11 on all compilers
set (CMAKE_CXX_STANDARD 11)

macro (add_sources)
    file (RELATIVE_PATH _relPath "${PROJECT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}")
    foreach (_src ${ARGN})
        if (_relPath)
            list (APPEND SRCS "${_relPath}/${_src}")
        else()
            list (APPEND SRCS "${_src}")
        endif()
    endforeach()
    if (_relPath)
        # propagate SRCS to parent directory
        set (SRCS ${SRCS} PARENT_SCOPE)
    endif()
endmacro()

add_subdirectory(src)
if(BUILD_TCP)
    add_subdirectory(src/tcpconnection)
endif()

option(BUILD_SHARED "build shared library" OFF)

if(BUILD_SHARED)
    add_library(${PROJECT_NAME} SHARED ${SRCS})
    set_target_properties(${PROJECT_NAME} PROPERTIES SOVERSION 2.7) # TODO version incorrect
    install(TARGETS ${PROJECT_NAME}
            LIBRARY DESTINATION lib
    )
else()
    add_library(${PROJECT_NAME} STATIC ${SRCS})
    install(TARGETS ${PROJECT_NAME}
            ARCHIVE DESTINATION lib
    )
endif()
Include_directories(${PROJECT_SOURCE_DIR})
install(DIRECTORY include/ DESTINATION include/amqpcpp
        FILES_MATCHING PATTERN "*.h")
install(FILES amqpcpp.h DESTINATION include)
{'fraction_non_alphanumeric': 0.10506134969325154, 'fraction_numerical': 0.006134969325153374, 'mean_word_length': 4.026974951830443, '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': '5724728', 'n_tokens_mistral': 946, 'n_tokens_neox': 902, 'n_words': 196}