diff --git a/pkgimage.mk b/pkgimage.mk index 0b46531cfa137..58049e9a48f2b 100644 --- a/pkgimage.mk +++ b/pkgimage.mk @@ -29,6 +29,10 @@ all-debug: $(addprefix cache-debug-, $(STDLIBS)) define stdlib_builder ifneq ($(filter $(1),$(INDEPENDENT_STDLIBS)),) +# Define target-specific export for `JULIA_CPU_TARGET` +$$(BUILDDIR)/stdlib/$1.release.image: export JULIA_CPU_TARGET=$(JULIA_CPU_TARGET) +$$(BUILDDIR)/stdlib/$1.debug.image: export JULIA_CPU_TARGET=$(JULIA_CPU_TARGET) + $$(BUILDDIR)/stdlib/$1.release.image: $$($1_SRCS) $$(addsuffix .release.image,$$(addprefix $$(BUILDDIR)/stdlib/,$2)) $(build_private_libdir)/sys.$(SHLIB_EXT) @$$(call PRINT_JULIA, $$(call spawn,$$(JULIA_EXECUTABLE)) --startup-file=no --check-bounds=yes -e 'Base.compilecache(Base.identify_package("$1"))') @$$(call PRINT_JULIA, $$(call spawn,$$(JULIA_EXECUTABLE)) --startup-file=no --pkgimage=no -e 'Base.compilecache(Base.identify_package("$1"))')