]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Properly handle autotools-based builds as well 15565/head
authorRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 19 May 2025 10:46:47 +0000 (12:46 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 19 May 2025 10:46:47 +0000 (12:46 +0200)
pdns/dnsdistdist/dnsdist-rust-lib/Makefile.am
pdns/dnsdistdist/dnsdist-rust-lib/dnsdist-settings-generator.py

index 98fbf5d7940ba029a4821a678ec8a6fdea339daf..ef9363596a64893f2890f2293425d86a74f261c7 100644 (file)
@@ -17,5 +17,5 @@ rust/src/lib.rs dnsdist-configuration-yaml-items-generated.cc: dnsdist-settings-
        @if test "$(PYTHON)" = ":"; then echo "Settings definitions have changed, python is needed to regenerate the related settings files but python was not found. Please install python and re-run configure"; exit 1; fi
        @if ! $(PYTHON) --version | grep -q "Python 3"; then echo $(PYTHON) should be at least version 3. Please install python 3 and re-run configure; exit 1; fi
        $(MAKE) -C rust clean
-       (cd ${srcdir} && $(PYTHON) dnsdist-settings-generator.py ../ ./ ../)
+       (cd ${srcdir} && $(PYTHON) dnsdist-settings-generator.py ../ ./ ../ ../)
        $(PYTHON) dnsdist-settings-documentation-generator.py
index 9f76fdbe0f9da6a9449ebefacfb49af3ff6916c6..7a102cb11b60882248ec8f2c2e720acef9e13603 100644 (file)
@@ -377,7 +377,8 @@ void convertRuntimeFlatSettingsFromRust(const dnsdist::rust::settings::GlobalCon
 ''')
 
     os.rename(cxx_flat_settings_fp.name, out_file_path + '/dnsdist-configuration-yaml-items-generated.cc')
-    os.symlink(os.path.abspath(out_file_path + '/dnsdist-configuration-yaml-items-generated.cc'), build_dir_path + '/dnsdist-configuration-yaml-items-generated.cc')
+    if out_file_path != build_dir_path:
+        os.symlink(os.path.abspath(out_file_path + '/dnsdist-configuration-yaml-items-generated.cc'), build_dir_path + '/dnsdist-configuration-yaml-items-generated.cc')
 
 def generate_actions_config(output, def_dir, response, default_functions):
     suffix = 'ResponseAction' if response else 'Action'