From e9d8ec64322c9be220d754b14ce8b325f116df7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Sun, 7 Apr 2024 00:29:27 +0200 Subject: [PATCH] Native/Assimp: Strip Linux/macOS binaries after build. --- build/nuke/Native/Assimp.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/build/nuke/Native/Assimp.cs b/build/nuke/Native/Assimp.cs index 3162e304e8..bb09bc4351 100644 --- a/build/nuke/Native/Assimp.cs +++ b/build/nuke/Native/Assimp.cs @@ -73,6 +73,8 @@ partial class Build { InheritedShell($"{prepare} {GetCMakeToolchainFlag(triple)}", buildDir).AssertZeroExitCode(); InheritedShell(build, buildDir).AssertZeroExitCode(); + InheritedShell($"{triple}-strip --strip-unneeded bin/libassimp.so.5", buildDir).AssertZeroExitCode(); + CopyAll((buildDir / "bin").GlobFiles("libassimp.so.5"), runtimes / rid / "native"); } } @@ -89,6 +91,8 @@ partial class Build { InheritedShell($"{prepare} -DCMAKE_OSX_ARCHITECTURES={arch}", buildDir).AssertZeroExitCode(); InheritedShell(build, buildDir).AssertZeroExitCode(); + InheritedShell($"strip -Sx bin/libassimp.5.dylib", buildDir).AssertZeroExitCode(); + CopyAll((buildDir / "bin").GlobFiles("libassimp.5.dylib"), runtimes / rid / "native"); } }