Commit a54f454dee for frr

commit a54f454dee3d31cc370c35ffea3c667544da7f1d
Author: Donald Sharp <sharpd@nvidia.com>
Date:   Sun Nov 8 10:33:45 2026 -0500

    build: avoid non-portable sed -i when generating protobuf C files

    BSD/macOS sed requires an explicit backup extension argument to -i,
    unlike GNU sed.  Prepend #include "config.h" via a temporary file and
    mv instead so the rule works portably.

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

diff --git a/Makefile.am b/Makefile.am
index 3a3c453883..27859a9fd8 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -176,8 +176,7 @@ am__v_PROTOC_C_1 =

 %.pb-c.c %.pb-c.h : %.proto
 	$(AM_V_PROTOC_C)$(PROTOC_C) -I$(top_srcdir) --c_out=$(top_builddir) $^
-	$(AM_V_GEN)$(SED) -i -e '1i\
-	#include "config.h"' $@
+	$(AM_V_GEN)(echo '#include "config.h"'; cat $@) > $@.tmp && mv $@.tmp $@

 include doc/subdir.am
 include doc/user/subdir.am