]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#3731] Fix KEA_LFC_BUILD_DIR
authorAndrei Pavel <andrei@isc.org>
Thu, 20 Mar 2025 06:33:47 +0000 (08:33 +0200)
committerAndrei Pavel <andrei@isc.org>
Thu, 20 Mar 2025 06:33:47 +0000 (08:33 +0200)
src/lib/dhcpsrv/tests/Makefile.am
src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc
src/lib/dhcpsrv/tests/meson.build

index 20439888caa5d10744c0599c0b4afbe6d27ace8e..d6b316a05445cd0c6ddb4773e27c7a7da96ef51a 100644 (file)
@@ -4,7 +4,7 @@ AM_CPPFLAGS = -I$(top_builddir)/src/lib -I$(top_srcdir)/src/lib
 AM_CPPFLAGS += $(BOOST_INCLUDES) $(CRYPTO_CFLAGS) $(CRYPTO_INCLUDES)
 AM_CPPFLAGS += -DTEST_DATA_BUILDDIR=\"$(abs_top_builddir)/src/lib/dhcpsrv/tests\"
 AM_CPPFLAGS += -DDHCP_DATA_DIR=\"$(abs_top_builddir)/src/lib/dhcpsrv/tests\"
-AM_CPPFLAGS += -DKEA_LFC_BUILD_DIR=\"$(abs_top_builddir)/src/bin/lfc\"
+AM_CPPFLAGS += -DKEA_LFC_EXECUTABLE=\"$(abs_top_builddir)/src/bin/lfc/kea-lfc\"
 AM_CPPFLAGS += -DINSTALL_PROG=\"$(abs_top_srcdir)/install-sh\"
 AM_CPPFLAGS += -DDEFAULT_HOOKS_PATH=\"$(libdir)/kea/hooks\"
 
index f22b5cdee009150b326bff573fcfed2a1b19db08..66517ade30d0d0629da86f8d2d1a398bb613593c 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2012-2024 Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2012-2025 Internet Systems Consortium, Inc. ("ISC")
 //
 // This Source Code Form is subject to the terms of the Mozilla Public
 // License, v. 2.0. If a copy of the MPL was not distributed with this
@@ -120,9 +120,7 @@ public:
         DatabaseConnection::setIOService(io_service_);
         ProcessSpawn::setIOService(io_service_);
 
-        std::ostringstream s;
-        s << KEA_LFC_BUILD_DIR << "/kea-lfc";
-        setenv("KEA_LFC_EXECUTABLE", s.str().c_str(), 1);
+        setenv("KEA_LFC_EXECUTABLE", KEA_LFC_EXECUTABLE, 1);
 
         // Remove lease files and products of Lease File Cleanup.
         removeFiles(getLeaseFilePath("leasefile4_0.csv"));
index 1d2ebc2b87da8c4752ff9099b176258330a2f3e9..17e3df9fc96d3f942952f042a41a0a7e4c42cdd1 100644 (file)
@@ -131,7 +131,7 @@ kea_dhcpsrv_tests = executable(
     cpp_args: [
         f'-DTEST_DATA_BUILDDIR="@current_build_dir@"',
         f'-DDHCP_DATA_DIR="@current_build_dir@"',
-        f'-DKEA_LFC_BUILD_DIR="@KEA_LFC_BUILT@"',
+        f'-DKEA_LFC_EXECUTABLE="@KEA_LFC_BUILT@"',
         f'-DDEFAULT_HOOKS_PATH="@DEFAULT_HOOKS_PATH@"',
     ],
     dependencies: [CRYPTO_DEP, GTEST_DEP],