mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-18 05:32:52 +00:00
97f2a2213e
* Move some code outside dbms/src folder * Fix paths
21 lines
705 B
Bash
Executable File
21 lines
705 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
[ ! -f public_suffix_list.dat ] && wget -O public_suffix_list.dat https://publicsuffix.org/list/public_suffix_list.dat
|
|
|
|
echo '%language=C++
|
|
%define lookup-function-name is_valid
|
|
%define class-name tldLookupHash
|
|
%readonly-tables
|
|
%includes
|
|
%compare-strncmp
|
|
%{
|
|
#pragma GCC diagnostic push
|
|
#pragma GCC diagnostic ignored "-Wimplicit-fallthrough"
|
|
#pragma GCC diagnostic ignored "-Wzero-as-null-pointer-constant"
|
|
#pragma GCC diagnostic ignored "-Wunused-macros"
|
|
%}
|
|
# List generated using https://publicsuffix.org/list/public_suffix_list.dat
|
|
%%' > tldLookup.gperf
|
|
grep -v "//" public_suffix_list.dat | grep . | grep "\." | grep -ve "\..*\..*" >> tldLookup.gperf
|
|
echo "%%" >> tldLookup.gperf
|