From c5160d75c4efaa62f8d57f180c6d544b44096ca1 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Sun, 7 Feb 2010 03:43:07 +0100 Subject: [PATCH] Don't strip on any-emu --- conf/any-emu.rmk | 1 + genmk.rb | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/conf/any-emu.rmk b/conf/any-emu.rmk index ebcc9087c..983dc2c1f 100644 --- a/conf/any-emu.rmk +++ b/conf/any-emu.rmk @@ -23,6 +23,7 @@ kernel_img_SOURCES = kern/device.c kern/disk.c kern/dl.c kern/env.c \ grub_emu_init.c gnulib/progname.c kernel_img_CFLAGS = $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 kernel_img_LDFLAGS = $(COMMON_LDFLAGS) +TARGET_NO_STRIP = yes # For hostfs.mod. pkglib_MODULES += hostfs.mod diff --git a/genmk.rb b/genmk.rb index df03e1dfe..65bcb3ddd 100644 --- a/genmk.rb +++ b/genmk.rb @@ -148,7 +148,7 @@ ifneq ($(TARGET_APPLE_CC),1) -rm -f $@ $(TARGET_CC) $(#{prefix}_LDFLAGS) $(TARGET_LDFLAGS) -Wl,-r,-d -o $@ #{pre_obj} #{mod_obj} if test ! -z \"$(TARGET_OBJ2ELF)\"; then ./$(TARGET_OBJ2ELF) $@ || (rm -f $@; exit 1); fi - $(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -K _grub_mod_init -K _grub_mod_fini -R .note -R .comment $@ + if test x$(TARGET_NO_STRIP) != xyes ; then $(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -K _grub_mod_init -K _grub_mod_fini -R .note -R .comment $@; fi else #{@name}: #{pre_obj} #{mod_obj} $(TARGET_OBJ2ELF) -rm -f $@ @@ -330,11 +330,11 @@ MOSTLYCLEANFILES += #{deps_str} ifeq ($(#{prefix}_RELOCATABLE),yes) #{@name}: $(#{prefix}_DEPENDENCIES) #{objs_str} $(TARGET_CC) -Wl,-r,-d -o $@ #{objs_str} $(TARGET_LDFLAGS) $(#{prefix}_LDFLAGS) - $(STRIP) --strip-unneeded -K start -R .note -R .comment $@ + if test x$(TARGET_NO_STRIP) != xyes ; then $(STRIP) --strip-unneeded -K start -R .note -R .comment $@; fi else #{@name}: $(#{prefix}_DEPENDENCIES) #{objs_str} $(TARGET_CC) -o $@ #{objs_str} $(TARGET_LDFLAGS) $(#{prefix}_LDFLAGS) - $(STRIP) -R .rel.dyn -R .reginfo -R .note -R .comment $@ + if test x$(TARGET_NO_STRIP) != xyes ; then $(STRIP) -R .rel.dyn -R .reginfo -R .note -R .comment $@; fi endif " + objs.collect_with_index do |obj, i|