File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -17,15 +17,16 @@ $(FINAL_BINARY_PATH): $(UNIVERSAL_BINARY_PATH)
17
17
18
18
$(UNIVERSAL_BINARY_PATH ) :
19
19
@echo " Building universal binary for $( UNIVERSAL_BINARY_NAME) (arm64 + x86_64) with size optimization (Osize, dead_strip)..."
20
- @swift build -c release --arch arm64 --arch x86_64 -Xswiftc -Osize -Xcc -Wl,-dead_strip
21
- @echo " Stripping symbols from $( UNIVERSAL_BINARY_PATH) ..."
22
- @strip $(UNIVERSAL_BINARY_PATH )
23
- @echo " Universal binary built and stripped at $( UNIVERSAL_BINARY_PATH) "
20
+ @swift build -c release --arch arm64 --arch x86_64 -Xswiftc -Osize -Xlinker -Wl,-dead_strip
21
+ @echo " Aggressively stripping symbols (strip -x) from $( UNIVERSAL_BINARY_PATH) ..."
22
+ @strip -x $(UNIVERSAL_BINARY_PATH )
23
+ @echo " Universal binary built and stripped: $( UNIVERSAL_BINARY_PATH) "
24
24
25
- # Clean build artifacts
26
25
clean :
27
26
@echo " Cleaning build artifacts..."
28
- @rm -rf .build $(FINAL_BINARY_PATH )
27
+ @rm -rf $(SWIFT_BUILD_DIR )
28
+ @rm -f $(FINAL_BINARY_PATH )
29
+ @rm -f $(UNIVERSAL_BINARY_PATH ) # Also remove the intermediate universal binary if it exists
29
30
@echo " Clean complete."
30
31
31
32
.PHONY : all clean
You can’t perform that action at this time.
0 commit comments