]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Rename -Dnamed-lto=off to -Dnamed-lto=disabled
authorAlessio Podda <alessio@isc.org>
Tue, 30 Sep 2025 07:19:00 +0000 (09:19 +0200)
committerAlessio Podda <alessio@isc.org>
Thu, 27 Nov 2025 12:00:22 +0000 (13:00 +0100)
Meson boolean options are usually configured with enabled/disabled
instead of on/off. Make things more consistent with other meson options
by renaming -Dnamed-lto=off to -Dnamed-lto=disabled.

.gitlab-ci.yml
meson.build
meson.options

index 29b3f627f8918f4a40428623361c68f19604a64e..2f6b58b9a9c5a1ddad16c824d9e4e3ab0e6d8b17 100644 (file)
@@ -1511,7 +1511,7 @@ clang:tsan:
     CC: "${CLANG}"
     CFLAGS: "${CFLAGS_COMMON}"
     LDFLAGS: "-Wl,--disable-new-dtags"
-    EXTRA_CONFIGURE: "${TSAN_CONFIGURE_FLAGS_COMMON} -Db_lundef=false -Dnamed-lto=off --native-file ci/clang-trixie.ini"
+    EXTRA_CONFIGURE: "${TSAN_CONFIGURE_FLAGS_COMMON} -Db_lundef=false -Dnamed-lto=disabled --native-file ci/clang-trixie.ini"
   <<: *build_job
 
 system:clang:tsan:
@@ -1985,7 +1985,7 @@ respdiff:tsan:
     CC: "${CLANG}"
     CFLAGS: "${CFLAGS_COMMON}"
     LDFLAGS: "-Wl,--disable-new-dtags"
-    EXTRA_CONFIGURE: "${TSAN_CONFIGURE_FLAGS_COMMON} -Dnamed-lto=off -Db_lundef=false"
+    EXTRA_CONFIGURE: "${TSAN_CONFIGURE_FLAGS_COMMON} -Dnamed-lto=disabled -Db_lundef=false"
     MAX_DISAGREEMENTS_PERCENTAGE: "0.3"
     TSAN_OPTIONS: "${TSAN_OPTIONS_DEBIAN}"
   script:
index 66b76da732cf619aadd39c772e36cc799376c552..199f1a2c650071c764b792d8ad3265642eb2ed28 100644 (file)
@@ -938,9 +938,9 @@ supported_clang_lto_linkers = [
 has_fat_lto = cc.has_argument('-ffat-lto-objects') and host_machine.system() != 'darwin'
 if not has_fat_lto
     warning(
-        'Your platform does not support fat lto objects but -Dnamed-lto was not set to off. Building without LTO anyway.',
+        'Your platform does not support fat lto objects but -Dnamed-lto was not set to `disabled`. Building without LTO anyway.',
     )
-    named_lto_opt = 'off'
+    named_lto_opt = 'disabled'
 endif
 
 static_lto_c_args = []
@@ -964,17 +964,17 @@ elif named_lto_opt == 'thin'
         error(
             'Clang ThinLTO only works with gold, lld, lld-link, ld64 or mold, not '
             + cc.get_linker_id()
-            + '. To build, use a supported linker or disable LTO with -Dnamed-lto=off.',
+            + '. To build, use a supported linker or disable LTO with -Dnamed-lto=disabled.',
         )
     else
         error(
-            'Unsupported configuration for LTO. To build, use a supported linker or disable LTO with -Dnamed-lto=off.',
+            'Unsupported configuration for LTO. To build, use a supported linker or disable LTO with -Dnamed-lto=disabled.',
         )
     endif
 endif
 
 add_project_arguments(static_lto_c_args, language: 'c')
-if named_lto_opt != 'off' and cc.get_id() == 'clang' and sanitizer.contains('address')
+if named_lto_opt != 'disabled' and cc.get_id() == 'clang' and sanitizer.contains('address')
     # Needed to suppress the
     #    warning: Redundant instrumentation detected, with module flag:
     #    nosanitize_address [-Werror,-Wbackend-plugin]
@@ -987,7 +987,7 @@ if named_lto_opt != 'off' and cc.get_id() == 'clang' and sanitizer.contains('add
     add_project_arguments('-Wno-backend-plugin', language: 'c')
 endif
 
-if meson_lto and named_lto_opt != 'off'
+if meson_lto and named_lto_opt != 'disabled'
     # Meson's builtin LTO settings do not set -ffat-lto-objects, which can cause
     # build issues.
     # Since we don't want two, possibly conflicting, sets of LTO flags, we
@@ -996,7 +996,7 @@ if meson_lto and named_lto_opt != 'off'
     error(
         '''
             Meson builtin -Db_lto and BIND's -Dnamed-lto options are incompatible.
-            Either disable named-lto with -Dnamed-lto=off, or avoid setting
+            Either disable named-lto with -Dnamed-lto=disabled, or avoid setting
             -Db_lto.
 
             Note that using -Db_lto is not a recommended configuration, might
@@ -1572,7 +1572,7 @@ executable(
 
 named_deps = []
 
-if named_lto_opt == 'off'
+if named_lto_opt == 'disabled'
     named_deps = [
         libdns_dep,
         libisc_dep,
index 0fac926a4a9beec9319256ada049a5471bcc8437..73f70be303792459e60977587f64436bf3a53cdb 100644 (file)
@@ -199,7 +199,7 @@ option(
 option(
     'named-lto',
     type: 'combo',
-    choices: ['off', 'thin', 'full'],
+    choices: ['disabled', 'thin', 'full'],
     value: 'thin',
     description: 'Enable Link Time Optimization for named.',
 )