Mercurial > hg > release > icedtea7-forest-2.4 > hotspot
changeset 5019:1053216103e0
Add patches/arm-hsdis.patch from IcedTea 6
author | andrew |
---|---|
date | Fri, 12 Jul 2013 20:03:52 +0100 |
parents | 8f0c2e1287f5 |
children | 3dc977fbd5d1 |
files | src/share/tools/hsdis/Makefile src/share/tools/hsdis/hsdis.c |
diffstat | 2 files changed, 12 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/src/share/tools/hsdis/Makefile Thu Mar 15 07:57:19 2012 -0400 +++ b/src/share/tools/hsdis/Makefile Fri Jul 12 20:03:52 2013 +0100 @@ -68,14 +68,18 @@ CONFIGURE_ARGS= --host=$(MINGW) --target=$(MINGW) else CPU = $(shell uname -m) +ifneq ($(findstring arm,$(CPU)),) +ARCH=arm +else ARCH1=$(CPU:x86_64=amd64) ARCH=$(ARCH1:i686=i386) CFLAGS/i386 += -m32 CFLAGS/sparc += -m32 CFLAGS/sparcv9 += -m64 CFLAGS/amd64 += -m64 +endif CFLAGS += $(CFLAGS/$(ARCH)) -CFLAGS += -fPIC +CFLAGS += -fPIC -g OS = linux LIB_EXT = .so CC = gcc @@ -118,7 +122,7 @@ BINUTILSDIR = $(shell cd $(BINUTILS);pwd) endif -CPPFLAGS += -I$(BINUTILSDIR)/include -I$(BINUTILS)/bfd -I$(TARGET_DIR)/bfd +CPPFLAGS += -I$(BINUTILSDIR)/include -I$(BINUTILSDIR)/bfd -I$(TARGET_DIR)/bfd CPPFLAGS += -DLIBARCH_$(LIBARCH) -DLIBARCH=\"$(LIBARCH)\" -DLIB_EXT=\"$(LIB_EXT)\" TARGET_DIR = build/$(OS)-$(JDKARCH) @@ -145,7 +149,7 @@ demo: $(TARGET) $(DEMO_TARGET) $(LIBRARIES): $(TARGET_DIR) $(TARGET_DIR)/Makefile - if [ ! -f $@ ]; then cd $(TARGET_DIR); make all-opcodes; fi + if [ ! -f $@ ]; then cd $(TARGET_DIR); make all-opcodes "CFLAGS=$(CFLAGS)"; fi $(TARGET_DIR)/Makefile: (cd $(TARGET_DIR); CC=$(CC) CFLAGS="$(CFLAGS)" $(BINUTILSDIR)/configure --disable-nls $(CONFIGURE_ARGS))
--- a/src/share/tools/hsdis/hsdis.c Thu Mar 15 07:57:19 2012 -0400 +++ b/src/share/tools/hsdis/hsdis.c Fri Jul 12 20:03:52 2013 +0100 @@ -35,6 +35,8 @@ #include <dis-asm.h> #include <inttypes.h> +#include <string.h> + #ifndef bool #define bool int #define true 1 @@ -418,6 +420,9 @@ #ifdef LIBARCH_sparcv9 res = "sparc:v9b"; #endif +#ifdef LIBARCH_arm + res = "arm"; +#endif if (res == NULL) res = "architecture not set in Makefile!"; return res;