[upstream-utils][mpack] Add upstream util for mpack (#4500)

This commit is contained in:
PJ Reiniger
2022-11-04 23:03:49 -04:00
committed by GitHub
parent 4ba16db645
commit fa44a07938
6 changed files with 278 additions and 1 deletions

View File

@@ -0,0 +1,24 @@
From d4d045c843d4b4de747d800e570c32cff3759a80 Mon Sep 17 00:00:00 2001
From: PJ Reiniger <pj.reiniger@gmail.com>
Date: Sat, 29 Oct 2022 12:16:36 -0400
Subject: [PATCH 2/3] Update amalgamation script
---
tools/amalgamate.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/amalgamate.sh b/tools/amalgamate.sh
index 2e24e27..4dfe999 100755
--- a/tools/amalgamate.sh
+++ b/tools/amalgamate.sh
@@ -74,8 +74,8 @@ echo -e "#endif\n" >> $HEADER
# assemble source
echo -e "#define MPACK_INTERNAL 1" >> $SOURCE
-echo -e "#define MPACK_EMIT_INLINE_DEFS 1\n" >> $SOURCE
-echo -e "#include \"mpack.h\"\n" >> $SOURCE
+echo -e "#define MPACK_EMIT_INLINE_DEFS 0\n" >> $SOURCE
+echo -e "#include \"wpi/mpack.h\"\n" >> $SOURCE
for f in $SOURCES; do
echo -e "\n/* $f.c */" >> $SOURCE
sed -e 's@^#include ".*@/* & */@' -e '0,/^ \*\/$/d' src/$f >> $SOURCE