OK, some more research into binutils, and here are some new patches:
config.sub: (this is the one that defines simplified targets, and which is shared with GCC)
Code:
*** config.sub.old 2012-11-20 19:51:30.000000000 +0100
--- config.sub 2012-11-20 20:29:36.000000000 +0100
***************
*** 1020,1028 ****
--- 1020,1036 ----
os=-pw32
;;
rdos)
+ basic_machine=x86_64-pc
+ os=-rdos
+ ;;
+ rdos32)
basic_machine=i386-pc
os=-rdos
;;
+ rdos64)
+ basic_machine=x86_64-pc
+ os=-rdos
+ ;;
rom68k)
basic_machine=m68k-rom68k
os=-coff
So now the standard target "rdos" refers to a 64-bit build, and there are also specific targets for 32-bits (rdos32) and 64-bits (rdos64).
bfd/config.bfd: (adds a new target for 64-bits)
Code:
*** config.bfd.old 2012-09-04 16:15:00.000000000 +0200
--- config.bfd 2012-11-20 21:21:10.000000000 +0100
***************
*** 660,665 ****
--- 660,670 ----
want64=true
targ_underscore=no
;;
+ x86_64-*-rdos*)
+ targ_defvec=bfd_elf64_x86_64_vec
+ targ_selvecs="bfd_elf32_i386_vec bfd_elf64_l1om_vec bfd_elf64_k1om_vec"
+ want64=true
+ ;;
#endif
i[3-7]86-*-lynxos*)
targ_defvec=bfd_elf32_i386_vec
ld/configure.tgt:
Code:
*** configure.tgt.old 2012-09-04 14:53:48.000000000 +0200
--- configure.tgt 2012-11-20 21:20:08.000000000 +0100
***************
*** 198,203 ****
--- 198,204 ----
i[3-7]86-*-rtems*) targ_emul=elf_i386 ;;
i[3-7]86-*-aros*) targ_emul=elf_i386 ;;
i[3-7]86-*-rdos*) targ_emul=elf_i386 ;;
+ x86_64-*-rdos*) targ_emul=elf_x86_64 ;;
i[3-7]86-*-bsd) targ_emul=i386bsd ;;
i[3-7]86-*-bsd386) targ_emul=i386bsd ;;
i[3-7]86-*-bsdi*) targ_emul=i386bsd ;;
I'll send these new patches and hope for acceptance.