title: ResourcesNotFoundException in the devices below marshmallow for fused location provider
body: <p>The fused location provider works fine in android marshmallow but it fails to install the versions below it. The code, build.gradle, manifest and build error are below. Please have a look.</p>
  
  <p>My code: </p>
  
  <pre><code>protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
  
      lblLocation = (TextView) findViewById(R.id.lblLocation);
      btnShowLocation = (Button) findViewById(R.id.btnShowLocation);
      btnStartLocationUpdates = (Button) findViewById(R.id.btnLocationUpdates);
  
       // Check for permission
          if (ContextCompat.checkSelfPermission(MainActivity.this,
                  android.Manifest.permission.ACCESS_FINE_LOCATION)
                  != PackageManager.PERMISSION_GRANTED) {
              ActivityCompat.requestPermissions(
                      this, // Activity
                      new String[]{android.Manifest.permission.ACCESS_FINE_LOCATION},
                      MY_PERMISSIONS_REQUEST_FINE_LOCATION);
          }
  
      if (checkPlayServices()) {
          Log.i("playservice", checkPlayServices()+"");
          // Building the GoogleApi client
          buildGoogleApiClient();
      }
  
      btnShowLocation.setOnClickListener(new View.OnClickListener() {
  
          @Override
          public void onClick(View v) {
              displayLocation();
          }
      });
  
  }
  
  private void displayLocation() {
  
      mLastLocation = LocationServices.FusedLocationApi
              .getLastLocation(mGoogleApiClient);
  
      if (mLastLocation != null) {
          double latitude = mLastLocation.getLatitude();
          double longitude = mLastLocation.getLongitude();
  
          lblLocation.setText(latitude + ", " + longitude);
      } else {
          lblLocation.setText("(Couldn't get the location. Make sure location is enabled on the device)");
      }
  }
  
  protected synchronized void buildGoogleApiClient() {
      Log.i(TAG, "Building GoogleApiClient");
  
      mGoogleApiClient = new GoogleApiClient.Builder(this)
              .addConnectionCallbacks(this)
              .addOnConnectionFailedListener(this)
              .addApi(LocationServices.API)
              .build();
  }
  
  private boolean checkPlayServices() {
      int resultCode = GooglePlayServicesUtil
              .isGooglePlayServicesAvailable(this);
      if (resultCode != ConnectionResult.SUCCESS) {
          if (GooglePlayServicesUtil.isUserRecoverableError(resultCode)) {
              GooglePlayServicesUtil.getErrorDialog(resultCode, this,
                      PLAY_SERVICES_RESOLUTION_REQUEST).show();
          } else {
              Toast.makeText(getApplicationContext(),
                      "This device is not supported.", Toast.LENGTH_LONG)
                      .show();
              finish();
          }
          return false;
      }
      return true;
  }
  
  @Override
  public void onConnected(Bundle bundle) {
  
      Log.i(TAG, "GoogleApiClient connected!");
      createLocationRequest();
      mLastLocation = LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);
      Log.i(TAG, " Location: " + mLastLocation);
  }
  
  protected void createLocationRequest() {
  
      mLocationRequest = new LocationRequest();
      mLocationRequest.setInterval(10000);
      mLocationRequest.setFastestInterval(5000);
      mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);
      LocationServices.FusedLocationApi.requestLocationUpdates(mGoogleApiClient, mLocationRequest, new LocationCallback() {
          @Override
          public void onLocationResult(final LocationResult locationResult) {
              Log.i("onLocationResult",locationResult + "");
  
              btnShowLocation.setOnClickListener(new View.OnClickListener() {
  
                  @Override
                  public void onClick(View v) {
                      lblLocation.setText(locationResult.getLocations() + "");
                  }
              });
          }
  
          @Override
          public void onLocationAvailability(LocationAvailability locationAvailability) {
              Log.i("onLocationAvailability", "onLocationAvailability: isLocationAvailable =  " + locationAvailability.isLocationAvailable());
          }
      }, null);
  }
  
  @Override
  public void onConnectionSuspended(int i) {
      mGoogleApiClient.connect();
  }
  
  @Override
  public void onConnectionFailed(ConnectionResult result) {
      Log.i(TAG, "Connection failed: ConnectionResult.getErrorCode() = "
              + result.getErrorCode());
  }
  
  
  @Override
  protected void onStart() {
      super.onStart();
  
      if (mGoogleApiClient != null) {
          mGoogleApiClient.connect();
          Log.i(TAG, "mGoogleApiClient.connect()");
      }
  }
  </code></pre>
  
  <p><strong>Build.gradle(Module:app)</strong>
  PS. I've tested using build version 21.1.2 as well but no luck</p>
  
  <pre><code>apply plugin: 'com.android.application'
  
  android {
      compileSdkVersion 26
      buildToolsVersion "26.0.0"
  
      defaultConfig {
          applicationId "com.bbeck.bbeck.fuseapinew"
          minSdkVersion 14
          targetSdkVersion 26
          versionCode 1
          versionName "1.0"
      }
      buildTypes {
          release {
              minifyEnabled false
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
          }
      }
  }
  
  dependencies {
      compile fileTree(dir: 'libs', include: ['*.jar'])
      compile 'com.android.support:appcompat-v7:22.0.+'
      compile 'com.google.android.gms:play-services:11.0.4'
  }
  </code></pre>
  
  <p><strong>AndroidManifest.xml</strong></p>
  
  <p>Below is the permission I've used</p>
  
  <pre><code>&lt;uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /&gt;
  &lt;uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /&gt;
  </code></pre>
  
  <p><strong>Error log:</strong></p>
  
  <pre><code>08-07 15:00:28.901: E/AndroidRuntime(14987): FATAL EXCEPTION: main
  08-07 15:00:28.901: E/AndroidRuntime(14987): Process: com.test.test.fuseapinew, PID: 14987
  08-07 15:00:28.901: E/AndroidRuntime(14987): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.test.test.fuseapinew/com.test.test.fuseapinew.MainActivity}: android.content.res.Resources$NotFoundException: File res/drawable/abc_vector_test.xml from drawable resource ID #0x7f020052
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2404)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2464)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread.access$900(ActivityThread.java:172)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1308)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.os.Handler.dispatchMessage(Handler.java:102)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.os.Looper.loop(Looper.java:146)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread.main(ActivityThread.java:5653)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at java.lang.reflect.Method.invokeNative(Native Method)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at java.lang.reflect.Method.invoke(Method.java:515)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1291)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1107)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at dalvik.system.NativeStart.main(Native Method)
  08-07 15:00:28.901: E/AndroidRuntime(14987): Caused by: android.content.res.Resources$NotFoundException: File res/drawable/abc_vector_test.xml from drawable resource ID #0x7f020052
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.content.res.Resources.loadDrawable(Resources.java:3376)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.content.res.Resources.getDrawable(Resources.java:1872)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v4.content.ContextCompat.getDrawable(ContextCompat.java:374)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.widget.AppCompatDrawableManager.getDrawable(AppCompatDrawableManager.java:202)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.widget.AppCompatDrawableManager.getDrawable(AppCompatDrawableManager.java:190)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.widget.AppCompatDrawableManager.checkVectorDrawableSetup(AppCompatDrawableManager.java:711)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.widget.AppCompatDrawableManager.getDrawable(AppCompatDrawableManager.java:195)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.widget.TintTypedArray.getDrawableIfKnown(TintTypedArray.java:81)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegateImplBase.&lt;init&gt;(AppCompatDelegateImplBase.java:131)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegateImplV9.&lt;init&gt;(AppCompatDelegateImplV9.java:151)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegateImplV11.&lt;init&gt;(AppCompatDelegateImplV11.java:31)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegateImplV14.&lt;init&gt;(AppCompatDelegateImplV14.java:55)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegate.create(AppCompatDelegate.java:205)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatDelegate.create(AppCompatDelegate.java:185)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatActivity.getDelegate(AppCompatActivity.java:519)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.support.v7.app.AppCompatActivity.onCreate(AppCompatActivity.java:71)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at com.test.test.fuseapinew.MainActivity.onCreate(MainActivity.java:58)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.Activity.performCreate(Activity.java:5541)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1093)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2368)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    ... 11 more
  08-07 15:00:28.901: E/AndroidRuntime(14987): Caused by: org.xmlpull.v1.XmlPullParserException: Binary XML file line #17: invalid drawable tag vector
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:986)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.graphics.drawable.Drawable.createFromXml(Drawable.java:930)
  08-07 15:00:28.901: E/AndroidRuntime(14987):    at android.content.res.Resources.loadDrawable(Resources.java:3372)
  </code></pre>