Skip to content

Commit 4ff7a1c

Browse files
authored
build(meson): simplify build options (#2176)
The "cpp-httplib_" prefix of build options is now dropped, as Meson build options are already namespaced for each project. The old names remain as deprecated aliases for the new ones.
1 parent 082acac commit 4ff7a1c

File tree

2 files changed

+17
-8
lines changed

2 files changed

+17
-8
lines changed

meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ project(
1313
'b_lto=true',
1414
'warning_level=3'
1515
],
16-
meson_version: '>=0.62.0'
16+
meson_version: '>=0.63.0'
1717
)
1818

1919
cxx = meson.get_compiler('cpp')

meson_options.txt

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,19 @@
22
#
33
# SPDX-License-Identifier: MIT
44

5-
option('cpp-httplib_openssl', type: 'feature', value: 'auto', description: 'Enable OpenSSL support')
6-
option('cpp-httplib_zlib', type: 'feature', value: 'auto', description: 'Enable zlib support')
7-
option('cpp-httplib_brotli', type: 'feature', value: 'auto', description: 'Enable Brotli support')
8-
option('cpp-httplib_macosx_keychain', type: 'feature', value: 'auto', description: 'Enable loading certs from the Keychain on Apple devices')
9-
option('cpp-httplib_non_blocking_getaddrinfo', type: 'feature', value: 'auto', description: 'Enable asynchronous name lookup')
10-
option('cpp-httplib_compile', type: 'boolean', value: false, description: 'Split the header into a compilable header & source file (requires python3)')
11-
option('cpp-httplib_test', type: 'boolean', value: false, description: 'Build tests')
5+
option('openssl', type: 'feature', value: 'auto', description: 'Enable OpenSSL support')
6+
option('zlib', type: 'feature', value: 'auto', description: 'Enable zlib support')
7+
option('brotli', type: 'feature', value: 'auto', description: 'Enable Brotli support')
8+
option('macosx_keychain', type: 'feature', value: 'auto', description: 'Enable loading certs from the Keychain on Apple devices')
9+
option('non_blocking_getaddrinfo', type: 'feature', value: 'auto', description: 'Enable asynchronous name lookup')
10+
option('compile', type: 'boolean', value: false, description: 'Split the header into a compilable header & source file (requires python3)')
11+
option('test', type: 'boolean', value: false, description: 'Build tests')
12+
13+
# Old option names
14+
option('cpp-httplib_openssl', type: 'feature', deprecated: 'openssl')
15+
option('cpp-httplib_zlib', type: 'feature', deprecated: 'zlib')
16+
option('cpp-httplib_brotli', type: 'feature', deprecated: 'brotli')
17+
option('cpp-httplib_macosx_keychain', type: 'feature', deprecated: 'macosx_keychain')
18+
option('cpp-httplib_non_blocking_getaddrinfo', type: 'feature', deprecated: 'non_blocking_getaddrinfo')
19+
option('cpp-httplib_compile', type: 'boolean', value: false, deprecated: 'compile')
20+
option('cpp-httplib_test', type: 'boolean', value: false, deprecated: 'test')

0 commit comments

Comments
 (0)