<commit_before>cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)

project(lxqt-config)
set(LXQT_CONFIG_PROJECT "${PROJECT_NAME}")

option(UPDATE_TRANSLATIONS "Update source translation translations/*.ts files" OFF)
option(WITH_INPUT "Build the 'lxqt-config-input'" ON)
option(WITH_FILE_ASSOCIATIONS "Build the 'lxqt-config-file-associations'" ON)
option(WITH_APPEARANCE "Build the 'lxqt-config-appearance'" ON)
option(WITH_MONITOR "Build the 'lxqt-config-monitor'" ON)
option(WITH_BRIGHTNESS "Build the 'lxqt-config-brightness'" ON)
option(WITH_LOCALE "Build the 'lxqt-config-locale'" ON)

include(GNUInstallDirs)

set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)

find_package(Qt5Widgets REQUIRED)
find_package(Qt5DBus REQUIRED)
find_package(Qt5Xml REQUIRED)
find_package(Qt5Concurrent REQUIRED)
find_package(Qt5X11Extras REQUIRED)
find_package(Qt5LinguistTools REQUIRED)
find_package(lxqt REQUIRED)

include(LXQtCompilerSettings NO_POLICY_SCOPE)

if(NOT CMAKE_BUILD_TYPE)
    set(CMAKE_BUILD_TYPE Release)
endif()

# Patch Version
set(LXQT_CONFIG_PATCH_VERSION 0)

set(LXQT_CONFIG_VERSION ${LXQT_MAJOR_VERSION}.${LXQT_MINOR_VERSION}.${LXQT_CONFIG_PATCH_VERSION})
add_definitions(
    "-DLXQT_CONFIG_VERSION=\"${LXQT_CONFIG_VERSION}\""
    "-DQT_NO_FOREACH"
)

include(LXQtTranslate)

add_subdirectory(src)
if (WITH_INPUT OR WITH_APPEARANCE)
    add_subdirectory(liblxqt-config-cursor)
endif()
if (WITH_INPUT)
    add_subdirectory(lxqt-config-input)
endif()
if (WITH_FILE_ASSOCIATIONS)
    add_subdirectory(lxqt-config-file-associations)
endif()<commit_msg>CMake: Prevent in-source builds<commit_after>cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)

project(lxqt-config)
set(LXQT_CONFIG_PROJECT "${PROJECT_NAME}")

option(UPDATE_TRANSLATIONS "Update source translation translations/*.ts files" OFF)
option(WITH_INPUT "Build the 'lxqt-config-input'" ON)
option(WITH_FILE_ASSOCIATIONS "Build the 'lxqt-config-file-associations'" ON)
option(WITH_APPEARANCE "Build the 'lxqt-config-appearance'" ON)
option(WITH_MONITOR "Build the 'lxqt-config-monitor'" ON)
option(WITH_BRIGHTNESS "Build the 'lxqt-config-brightness'" ON)
option(WITH_LOCALE "Build the 'lxqt-config-locale'" ON)

include(GNUInstallDirs)

set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)

find_package(Qt5Widgets REQUIRED)
find_package(Qt5DBus REQUIRED)
find_package(Qt5Xml REQUIRED)
find_package(Qt5Concurrent REQUIRED)
find_package(Qt5X11Extras REQUIRED)
find_package(Qt5LinguistTools REQUIRED)
find_package(lxqt REQUIRED)

include(LXQtPreventInSourceBuilds)
include(LXQtCompilerSettings NO_POLICY_SCOPE)

if(NOT CMAKE_BUILD_TYPE)
    set(CMAKE_BUILD_TYPE Release)
endif()

# Patch Version
set(LXQT_CONFIG_PATCH_VERSION 0)

set(LXQT_CONFIG_VERSION ${LXQT_MAJOR_VERSION}.${LXQT_MINOR_VERSION}.${LXQT_CONFIG_PATCH_VERSION})
add_definitions(
    "-DLXQT_CONFIG_VERSION=\"${LXQT_CONFIG_VERSION}\""
    "-DQT_NO_FOREACH"
)

include(LXQtTranslate)

add_subdirectory(src)
if (WITH_INPUT OR WITH_APPEARANCE)
    add_subdirectory(liblxqt-config-cursor)
endif()
if (WITH_INPUT)
    add_subdirectory(lxqt-config-input)
endif()
if (WITH_FILE_ASSOCIATIONS)
    add_subdirectory(lxqt-config-file-associations)
endif()
{'fraction_non_alphanumeric': 0.10146225007460459, 'fraction_numerical': 0.007162041181736795, 'mean_word_length': 8.858823529411765, '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': '54187', 'n_tokens_mistral': 1374, 'n_tokens_neox': 1276, 'n_words': 203}