]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - sim/common/sim-model.c
sim: sim-model: build for everyone
[thirdparty/binutils-gdb.git] / sim / common / sim-model.c
index 0d0c28d33543aacffce419df0a0270b79c05cd1f..054f0bcf7f0cf3b7fa2be00630ab9c98351c81b7 100644 (file)
@@ -190,6 +190,9 @@ sim_model_init (SIM_DESC sd)
 {
   SIM_CPU *cpu;
 
+  if (!WITH_MODEL_P)
+    return SIM_RC_OK;
+
   /* If both cpu model and state architecture are set, ensure they're
      compatible.  If only one is set, set the other.  If neither are set,
      use the default model.  STATE_ARCHITECTURE is the bfd_arch_info data
@@ -241,3 +244,12 @@ sim_model_init (SIM_DESC sd)
 
   return SIM_RC_OK;
 }
+\f
+#if !WITH_MODEL_P
+/* Set up basic model support.  This is a stub for ports that do not define
+   models.  See sim-model.h for more details.  */
+const SIM_MACH *sim_machs[] =
+{
+  NULL
+};
+#endif