mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-02-11 13:53:03 +02:00
Require compiler support for __builtin_clzl() and __builtin_bswap64().
These functions will be useful for optimizing varint-128 functions. Require them in the meson build before adding new code in case there are problems with packaging.
This commit is contained in:
parent
0c32757fd9
commit
1094aecab5
@ -2,6 +2,7 @@
|
||||
<release-core-list>
|
||||
<text>
|
||||
<p><b>NOTE TO PACKAGERS</b>: The <proper>lz4</proper> library is now required by the meson build.</p>
|
||||
<p><b>NOTE TO PACKAGERS</b>: Compiler support for <code>__builtin_clzl()</code> and <code>__builtin_bswap64()</code> is now required by the meson build.</p>
|
||||
</text>
|
||||
|
||||
<release-bug-list>
|
||||
|
10
meson.build
10
meson.build
@ -135,6 +135,16 @@ add_project_arguments(cc.get_supported_arguments('-fmacro-prefix-map=@0@/test/sr
|
||||
####################################################################################################################################
|
||||
configuration = configuration_data()
|
||||
|
||||
# Ensure the C compiler supports __builtin_clzl()
|
||||
if not cc.links('''int main(int arg, char **argv) {__builtin_clzl(1);}''')
|
||||
error('compiler must support __builtin_clzl()')
|
||||
endif
|
||||
|
||||
# Ensure the C compiler supports __builtin_bswap64()
|
||||
if not cc.links('''int main(int arg, char **argv) {__builtin_bswap64(1);}''')
|
||||
error('compiler must support __builtin_bswap64()')
|
||||
endif
|
||||
|
||||
# Find optional backtrace library
|
||||
lib_backtrace = cc.find_library('backtrace', required: false)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user