From 93e56e4d3bc11fff47d232c684f8c165c210c2ef Mon Sep 17 00:00:00 2001 From: Stas Sergeev Date: Sun, 21 Jun 2026 01:14:48 +0300 Subject: [PATCH] try to fix dj32 build on arm Needs to export cross-tools for djlink. --- src/32/makefile | 2 +- src/makefile | 2 +- src/makefile.inc | 11 ++++++++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/32/makefile b/src/32/makefile index d483971..3738ed4 100644 --- a/src/32/makefile +++ b/src/32/makefile @@ -1,5 +1,5 @@ PRJ = comcom32 TOOLC = dj32 -STRIP = djstrip +DJSTRIP = djstrip srcdir ?= .. include ../makefile.inc diff --git a/src/makefile b/src/makefile index 9b4e5b3..2d97068 100644 --- a/src/makefile +++ b/src/makefile @@ -1,4 +1,4 @@ PRJ = comcom64 TOOLC = dj64 -STRIP = @true +DJSTRIP = @true include makefile.inc diff --git a/src/makefile.inc b/src/makefile.inc index 017af3f..08c50e0 100644 --- a/src/makefile.inc +++ b/src/makefile.inc @@ -67,10 +67,19 @@ ifeq ($(DJ64STATIC),1) DJCFLAGS += -DSTATIC_LINK endif +ifeq ($(TOOLC),dj32) +ifneq ($(CROSS_PREFIX),) +# for djlink on arm +export READELF = $(CROSS_PREFIX)readelf +export OBJCOPY = $(CROSS_PREFIX)objcopy +export STRIP = $(CROSS_PREFIX)strip +endif +endif + ifneq ($(LINK),) $(RCMD): $(DJ64_XLIB) $(srcdir)/link.sh $(LINK) $^ $(DBG) $@ $(DJ64_XLDFLAGS) - $(STRIP) $@ + $(DJSTRIP) $@ info: $(RCMD) djstubify -i $<