ClickHouse/src/IO/examples
Robert Schulze 1a7727a254
Prefix overridden add_executable() command with "clickhouse_"
A simple HelloWorld program with zero includes except iostream triggers
a build of ca. 2000 source files. The reason is that ClickHouse's
top-level CMakeLists.txt overrides "add_executable()" to link all
binaries against "clickhouse_new_delete". This links against
"clickhouse_common_io", which in turn has lots of 3rd party library
dependencies ... Without linking "clickhouse_new_delete", the number of
compiled files for "HelloWorld" goes down to ca. 70.

As an example, the self-extracting-executable needs none of its current
dependencies but other programs may also benefit.

In order to restore access to the original "add_executable()", the
overriding version is now prefixed. There is precedence for a
"clickhouse_" prefix (as opposed to "ch_"), for example
"clickhouse_split_debug_symbols". In general prefixing makes sense also
because overriding CMake commands relies on undocumented behavior and is
considered not-so-great practice (*).

(*) https://crascit.com/2018/09/14/do-not-redefine-cmake-commands/
2022-07-11 19:36:18 +02:00
..
CMakeLists.txt Prefix overridden add_executable() command with "clickhouse_" 2022-07-11 19:36:18 +02:00
dragonbox_test.cpp
hadoop_snappy_read_buffer.cpp add some usage test 2022-03-08 20:00:39 +08:00
hashing_buffer.h
hashing_read_buffer.cpp
hashing_write_buffer.cpp
io_operators.cpp
limit_read_buffer2.cpp
limit_read_buffer.cpp
lzma_buffers.cpp
o_direct_and_dirty_pages.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
parse_date_time_best_effort.cpp
parse_int_perf2.cpp
parse_int_perf.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
read_buffer_perf.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
read_buffer.cpp refactor metadatacache to reduce using of USE_ROCKSDB 2022-01-05 19:51:50 +08:00
read_escaped_string.cpp
read_float_perf.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
read_write_int.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
snappy_read_buffer.cpp implement hive table engine 2021-11-05 19:55:30 +08:00
test.snappy implement hive table engine 2021-11-05 19:55:30 +08:00
valid_utf8_perf.cpp
valid_utf8.cpp
var_uint.cpp
write_buffer_perf.cpp Rename "common" to "base" 2021-10-02 10:13:14 +03:00
write_buffer.cpp Build with ENABLE_TESTS fix 2022-01-11 12:30:40 +03:00
write_int.cpp
zlib_buffers.cpp
zlib_ng_bug.cpp Enable define from cmake 2021-09-03 08:30:03 +00:00
zstd_buffers.cpp