Commit 07c2736080 for frr

commit 07c2736080377bffe11f47978527b8ded1a81f3f
Author: Donald Sharp <sharpd@nvidia.com>
Date:   Fri Nov 6 09:41:52 2026 -0500

    zebra: Only allow metaQ plugging when in dev build

    Only allow the metaQ to be plugged when in a dev
    build.  This will prevent accidental usage in production,
    which would be bad.

    Signed-off-by: Donald Sharp <sharpd@nvidia.com>

diff --git a/tests/topotests/zebra_metaq/test_zebra_metaq.py b/tests/topotests/zebra_metaq/test_zebra_metaq.py
index c69056cbba..9b31a23c79 100644
--- a/tests/topotests/zebra_metaq/test_zebra_metaq.py
+++ b/tests/topotests/zebra_metaq/test_zebra_metaq.py
@@ -27,7 +27,7 @@ sys.path.append(os.path.join(CWD, "../"))
 # pylint: disable=C0413
 from lib import topotest
 from lib.common_config import kill_router_daemons, step
-from lib.topogen import Topogen, TopoRouter, get_topogen
+from lib.topogen import Topogen, TopoRouter, get_frrdir, get_topogen
 from lib.topolog import logger


@@ -40,6 +40,13 @@ def build_topo(tgen):

 def setup_module(mod):
     "Set up the pytest environment"
+    # "zebra test metaq" is only built with --enable-dev-build.
+    dev_build = topotest.frr_configured_with("dev-build", get_frrdir())
+    if dev_build is False:
+        pytest.skip("FRR built without --enable-dev-build")
+    if dev_build is None:
+        pytest.skip("cannot confirm --enable-dev-build: configure args unknown")
+
     tgen = Topogen(build_topo, mod.__name__)
     tgen.start_topology()

diff --git a/tests/topotests/zebra_multiple_connected/test_zebra_multiple_connected.py b/tests/topotests/zebra_multiple_connected/test_zebra_multiple_connected.py
index 7ae66889d7..bcda2b092a 100644
--- a/tests/topotests/zebra_multiple_connected/test_zebra_multiple_connected.py
+++ b/tests/topotests/zebra_multiple_connected/test_zebra_multiple_connected.py
@@ -34,7 +34,7 @@ sys.path.append(os.path.join(CWD, "../"))
 # pylint: disable=C0413
 # Import topogen and topotest helpers
 from lib import topotest
-from lib.topogen import Topogen, get_topogen
+from lib.topogen import Topogen, get_frrdir, get_topogen

 # Required to instantiate the topology builder class.

@@ -82,6 +82,12 @@ def build_topo(tgen):

 def setup_module(module):
     "Setup topology and load unified config (frr.conf)."
+    dev_build = topotest.frr_configured_with("dev-build", get_frrdir())
+    if dev_build is False:
+        pytest.skip("FRR built without --enable-dev-build")
+    if dev_build is None:
+        pytest.skip("cannot confirm --enable-dev-build: configure args unknown")
+
     tgen = Topogen(build_topo, module.__name__)
     tgen.start_topology()

diff --git a/zebra/zebra_vty.c b/zebra/zebra_vty.c
index 380ad90b83..aa8a8de8e2 100644
--- a/zebra/zebra_vty.c
+++ b/zebra/zebra_vty.c
@@ -4096,6 +4096,7 @@ DEFUN (zebra_show_routing_tables_summary,
 	return CMD_SUCCESS;
 }

+#ifdef DEV_BUILD
 DEFPY_HIDDEN(zebra_test_metaq_plug,
 	     zebra_test_metaq_plug_cmd,
 	     "[no] zebra test metaq disable",
@@ -4116,7 +4117,6 @@ DEFPY_HIDDEN(zebra_test_metaq_plug,
 	return CMD_SUCCESS;
 }

-#ifdef DEV_BUILD
 DEFPY_HIDDEN(zebra_test_dplane_results_plug,
 	     zebra_test_dplane_results_plug_cmd,
 	     "[no] zebra test dplane disable results",
@@ -4425,8 +4425,8 @@ void zebra_vty_init(void)
 	install_element(VIEW_NODE, &show_dataplane_cmd);
 	install_element(VIEW_NODE, &show_dataplane_providers_cmd);
 	install_element(VIEW_NODE, &show_zebra_metaq_counters_cmd);
-	install_element(VIEW_NODE, &zebra_test_metaq_plug_cmd);
 #ifdef DEV_BUILD
+	install_element(VIEW_NODE, &zebra_test_metaq_plug_cmd);
 	install_element(VIEW_NODE, &zebra_test_dplane_results_plug_cmd);
 	install_element(VIEW_NODE, &zebra_test_dplane_install_plug_cmd);
 #endif