2009-07-20 Pedro Alves <pedro@codesourcery.com>
[deliverable/binutils-gdb.git] / gdb / target-descriptions.c
index 741ea655b8ae60ed45a746f8ff0b0b72331f12c1..88cc7e0442d66fa7692ee2c94d5bca5c3b5a84f3 100644 (file)
@@ -165,6 +165,10 @@ struct target_desc
   /* The architecture reported by the target, if any.  */
   const struct bfd_arch_info *arch;
 
+  /* The osabi reported by the target, if any; GDB_OSABI_UNKNOWN
+     otherwise.  */
+  enum gdb_osabi osabi;
+
   /* Any architecture-specific properties specified by the target.  */
   VEC(property_s) *properties;
 
@@ -351,6 +355,16 @@ tdesc_architecture (const struct target_desc *target_desc)
 {
   return target_desc->arch;
 }
+
+/* Return the OSABI associated with this target description, or
+   GDB_OSABI_UNKNOWN if no osabi was specified.  */
+
+enum gdb_osabi
+tdesc_osabi (const struct target_desc *target_desc)
+{
+  return target_desc->osabi;
+}
+
 \f
 
 /* Return 1 if this target description includes any registers.  */
@@ -1161,6 +1175,12 @@ set_tdesc_architecture (struct target_desc *target_desc,
 {
   target_desc->arch = arch;
 }
+
+void
+set_tdesc_osabi (struct target_desc *target_desc, enum gdb_osabi osabi)
+{
+  target_desc->osabi = osabi;
+}
 \f
 
 static struct cmd_list_element *tdesc_set_cmdlist, *tdesc_show_cmdlist;
This page took 0.023523 seconds and 4 git commands to generate.