<commit_before>cmake_minimum_required (VERSION 2.6)
project (ircd)

# hide default options from ccmake
mark_as_advanced (FORCE CMAKE_INSTALL_PREFIX)

# custom options
option (BUILD_DEBUG "Compile with debug options" OFF)
option (USE_GETOPT "Use getopt to parse command line arguments" ON)
option (USE_BACKTRACE "Print backtrace on error" ON)

# setup compiler/linker flags
if (BUILD_DEBUG)
	message(STATUS "Debug build")
	set(CMAKE_BUILD_TYPE "Debug")
else ()
	message(STATUS "Release build")
	set(CMAKE_BUILD_TYPE "Release")
endif ()

set (CMAKE_C_FLAGS "-std=c99 -Wall")
set (CMAKE_C_FLAGS_RELEASE "-O3")
set (CMAKE_C_FLAGS_DEBUG "-g -pg")

# setup custom definitions
if (USE_GETOPT)
	message(STATUS "Enabling getopt support")
	add_definitions ("-D_BSD_SOURCE -D_XOPEN_SOURCE")
endif ()
if (USE_BACKTRACE)
	message(STATUS "Enabling backtrace support")
	add_definitions ("-DDEBUG_PRINT_BACKTRACE")
	set (LINK_FLAGS "-rdynamic")
endif ()

file (GLOB ircd_SRCS src/*.c src/commands/*.c)

add_executable (ircd ${ircd_SRCS})

<commit_msg>Hidden cmake_build_type from options, using own (on/off)<commit_after>cmake_minimum_required (VERSION 2.6)
project (ircd)

# hide default options from ccmake
mark_as_advanced (FORCE CMAKE_BUILD_TYPE CMAKE_INSTALL_PREFIX)

# custom options
option (BUILD_DEBUG "Compile with debug options" OFF)
option (USE_GETOPT "Use getopt to parse command line arguments" ON)
option (USE_BACKTRACE "Print backtrace on error" ON)

# setup compiler/linker flags
if (BUILD_DEBUG)
	message(STATUS "Debug build")
	set(CMAKE_BUILD_TYPE "Debug")
else ()
	message(STATUS "Release build")
	set(CMAKE_BUILD_TYPE "Release")
endif ()

set (CMAKE_C_FLAGS "-std=c99 -Wall")
set (CMAKE_C_FLAGS_RELEASE "-O3")
set (CMAKE_C_FLAGS_DEBUG "-g -pg")

# setup custom definitions
if (USE_GETOPT)
	message(STATUS "Enabling getopt support")
	add_definitions ("-D_BSD_SOURCE -D_XOPEN_SOURCE")
endif ()
if (USE_BACKTRACE)
	message(STATUS "Enabling backtrace support")
	add_definitions ("-DDEBUG_PRINT_BACKTRACE")
	set (LINK_FLAGS "-rdynamic")
endif ()

file (GLOB ircd_SRCS src/*.c src/commands/*.c)

add_executable (ircd ${ircd_SRCS})


{'fraction_non_alphanumeric': 0.107981220657277, 'fraction_numerical': 0.004694835680751174, 'mean_word_length': 6.323024054982818, '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': '3459667', 'n_tokens_mistral': 774, 'n_tokens_neox': 742, 'n_words': 207}