title: FragmentActivity blows up with a simple xml file
body: <p>I have a very simple layout file that looks like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"
      android:orientation="vertical" &gt;
  
      &lt;!-- put map fragment here --&gt;
      &lt;fragment
            android:id="@+id/map"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            class="com.google.android.gms.maps.SupportMapFragment"&gt;
       &lt;/fragment&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>Then, I have a class that extends FragmentActivity that begins like this:</p>
  
  <pre><code>protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_map_view);
  </code></pre>
  
  <p>When it hits that setContentView, I get a runtime exception. I can't figure out why.</p>
  
  <p>Added:</p>
  
  <p>Well, I'm not including the rest of the onCreate, because it never reaches it. The relevant parts of logcat seem to be:</p>
  
  <blockquote>
    <p>05-09 22:31:35.604: E/dalvikvm(922): Could not find class
    'com.google.android.gms.maps.model.MarkerOptions', referenced from
    method com.molavi.homeworkfive.LocalMap.setUpMap 05-09 22:31:35.604:
    W/dalvikvm(922): VFY: unable to resolve new-instance 470
    (Lcom/google/android/gms/maps/model/MarkerOptions;) in
    Lcom/molavi/homeworkfive/LocalMap; 05-09 22:31:35.635:
    D/dalvikvm(922): VFY: replacing opcode 0x22 at 0x0002 05-09
    22:31:35.744: E/dalvikvm(922): Could not find class
    'com.google.android.gms.maps.MapView', referenced from method
    com.molavi.homeworkfive.LocalMap.setUpMapIfNeeded 05-09 22:31:35.744:
    W/dalvikvm(922): VFY: unable to resolve check-cast 466
    (Lcom/google/android/gms/maps/MapView;) in
    Lcom/molavi/homeworkfive/LocalMap; 05-09 22:31:35.744:
    D/dalvikvm(922): VFY: replacing opcode 0x1f at 0x000b 05-09
    22:31:35.754: E/dalvikvm(922): Could not find class
    'com.google.android.gms.maps.SupportMapFragment', referenced from
    method com.molavi.homeworkfive.LocalMap.onCreate 05-09 22:31:35.764:
    W/dalvikvm(922): VFY: unable to resolve check-cast 467
    (Lcom/google/android/gms/maps/SupportMapFragment;) in
    Lcom/molavi/homeworkfive/LocalMap; 05-09 22:31:35.784:
    D/dalvikvm(922): VFY: replacing opcode 0x1f at 0x003f 05-09
    22:31:35.814: I/dalvikvm(922): Could not find method
    com.google.android.gms.maps.SupportMapFragment.onDestroy, referenced
    from method com.molavi.homeworkfive.LocalMap.onDestroy 05-09
    22:31:35.814: W/dalvikvm(922): VFY: unable to resolve virtual method
    3401: Lcom/google/android/gms/maps/SupportMapFragment;.onDestroy ()V
    05-09 22:31:35.814: D/dalvikvm(922): VFY: replacing opcode 0x6e at
    0x0002 05-09 22:31:35.856: I/dalvikvm(922): Could not find method
    com.google.android.gms.maps.SupportMapFragment.onLowMemory, referenced
    from method com.molavi.homeworkfive.LocalMap.onLowMemory 05-09
    22:31:35.864: W/dalvikvm(922): VFY: unable to resolve virtual method
    3402: Lcom/google/android/gms/maps/SupportMapFragment;.onLowMemory ()V
    05-09 22:31:35.864: D/dalvikvm(922): VFY: replacing opcode 0x6e at
    0x0005 05-09 22:31:35.904: I/dalvikvm(922): Could not find method
    com.google.android.gms.maps.SupportMapFragment.onPause, referenced
    from method com.molavi.homeworkfive.LocalMap.onPause 05-09
    22:31:35.904: W/dalvikvm(922): VFY: unable to resolve virtual method
    3403: Lcom/google/android/gms/maps/SupportMapFragment;.onPause ()V
    05-09 22:31:35.934: D/dalvikvm(922): VFY: replacing opcode 0x6e at
    0x0002 05-09 22:31:35.944: I/dalvikvm(922): Could not find method
    com.google.android.gms.maps.SupportMapFragment.onResume, referenced
    from method com.molavi.homeworkfive.LocalMap.onResume 05-09
    22:31:35.964: W/dalvikvm(922): VFY: unable to resolve virtual method
    3404: Lcom/google/android/gms/maps/SupportMapFragment;.onResume ()V
    05-09 22:31:35.964: D/dalvikvm(922): VFY: replacing opcode 0x6e at
    0x0005 05-09 22:31:35.984: I/dalvikvm(922): Could not find method
    com.google.android.gms.maps.SupportMapFragment.onSaveInstanceState,
    referenced from method
    com.molavi.homeworkfive.LocalMap.onSaveInstanceState 05-09
    22:31:35.984: W/dalvikvm(922): VFY: unable to resolve virtual method
    3405:
    Lcom/google/android/gms/maps/SupportMapFragment;.onSaveInstanceState
    (Landroid/os/Bundle;)V 05-09 22:31:36.014: D/dalvikvm(922): VFY:
    replacing opcode 0x6e at 0x0005 05-09 22:31:36.024: D/dalvikvm(922):
    DexOpt: unable to opt direct call 0x0d4f at 0x04 in
    Lcom/molavi/homeworkfive/LocalMap;.setUpMap 05-09 22:31:36.044:
    D/dalvikvm(922): DexOpt: unable to opt direct call 0x0d4e at 0x15 in
    Lcom/molavi/homeworkfive/LocalMap;.setUpMap 05-09 22:31:37.464:
    E/ThrottleService(287): problem during onPollAlarm:
    java.lang.IllegalStateException: problem parsing stats:
    java.io.FileNotFoundException: /proc/net/xt_qtaguid/iface_stat_all:
    open failed: ENOENT (No such file or directory)</p>
  </blockquote>
  
  <p>But I don't get that because it seems to be saying it can't find the methods on mapFragment, but mapFragment definitely has those methods. </p>