From 0cbabd2c22e1b4c9c3c8697623e62afbcbadd2ea Mon Sep 17 00:00:00 2001 From: Joseph Eng Date: Sun, 14 Jul 2024 18:20:13 -0700 Subject: [PATCH] Apply patches first --- upstream_utils/update_mpack.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/upstream_utils/update_mpack.py b/upstream_utils/update_mpack.py index 68315e933a9..a70ee5d6fcb 100755 --- a/upstream_utils/update_mpack.py +++ b/upstream_utils/update_mpack.py @@ -17,13 +17,6 @@ def main(): wpilib_root = get_repo_root() wpiutil = os.path.join(wpilib_root, "wpiutil") - # Delete old install - for d in [ - "src/main/native/thirdparty/mpack/src", - "src/main/native/thirdparty/mpack/include", - ]: - shutil.rmtree(os.path.join(wpiutil, d), ignore_errors=True) - # Apply patches to upstream Git repo os.chdir(upstream_root) @@ -37,6 +30,13 @@ def main(): os.path.join(wpilib_root, "upstream_utils/mpack_patches", f), ) + # Delete old install + for d in [ + "src/main/native/thirdparty/mpack/src", + "src/main/native/thirdparty/mpack/include", + ]: + shutil.rmtree(os.path.join(wpiutil, d), ignore_errors=True) + # Run the amalgmation script subprocess.check_call(["bash", "tools/amalgamate.sh"])