From 08f0e55d8f1933597c0b944650265619c4761b6f Mon Sep 17 00:00:00 2001 From: Calvin Rose Date: Thu, 27 Jul 2023 21:37:26 -0500 Subject: [PATCH] Add strip in release process instead of local builds - Address #1233 --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index b1d72830..7f78ceee 100644 --- a/Makefile +++ b/Makefile @@ -48,7 +48,8 @@ SONAME_SETTER=-Wl,-soname, # For cross compilation HOSTCC?=$(CC) HOSTAR?=$(AR) -CFLAGS?=-O2 +# Symbols are (optionally) removed later, keep -g as default! +CFLAGS?=-O2 -g LDFLAGS?=-rdynamic RUN:=$(RUN) @@ -266,6 +267,7 @@ build/janet-%.tar.gz: $(JANET_TARGET) \ README.md build/c/janet.c build/c/shell.c mkdir -p build/$(JANET_DIST_DIR)/bin cp $(JANET_TARGET) build/$(JANET_DIST_DIR)/bin/ + strip -x -S 'build/$(JANET_DIST_DIR)/bin/$(JANET_TARGET)' mkdir -p build/$(JANET_DIST_DIR)/include cp build/janet.h build/$(JANET_DIST_DIR)/include/ mkdir -p build/$(JANET_DIST_DIR)/lib/