X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=linux%2Fhost_dasm.c;h=15597b4647f1f2c560ce2dc1de263dce96a9dab2;hb=17def48f1f0eeedb1f97f9392c0f5c82cb838e65;hp=a63a9acc41e16b1d5e4c07f23faf112e90bdc276;hpb=82d64b3a5ff89b5b44a2b1b901dcee4326a97af7;p=libpicofe.git diff --git a/linux/host_dasm.c b/linux/host_dasm.c index a63a9ac..15597b4 100644 --- a/linux/host_dasm.c +++ b/linux/host_dasm.c @@ -1,3 +1,14 @@ +/* + * (C) Gražvydas "notaz" Ignotas, 2009-2010 + * + * This work is licensed under the terms of any of these licenses + * (at your option): + * - GNU GPL, version 2 or later. + * - GNU LGPL, version 2.1 or later. + * - MAME license. + * See the COPYING file in the top-level directory. + */ + #include #include #include @@ -11,14 +22,16 @@ extern char **g_argv; static struct disassemble_info di; -#ifdef ARM +#ifdef __arm__ #define print_insn_func print_insn_little_arm #define BFD_ARCH bfd_arch_arm -#define BFD_MACH bfd_mach_arm_4T +#define BFD_MACH bfd_mach_arm_unknown +#define DASM_OPTS "reg-names-std" #else #define print_insn_func print_insn_i386_intel #define BFD_ARCH bfd_arch_i386 #define BFD_MACH bfd_mach_i386_i386_intel_syntax +#define DASM_OPTS NULL #endif /* symbols */ @@ -170,6 +183,7 @@ static void host_dasm_init(void) di.arch = BFD_ARCH; di.mach = BFD_MACH; di.endian = BFD_ENDIAN_LITTLE; + di.disassembler_options = DASM_OPTS; disassemble_init_for_target(&di); init_done = 1; }