1

STATUS: RESOLVED by @CommonsWare in the comments

I've got the following manifest file

    <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.test.example">

    <uses-permission android:name="android.permission.CAMERA" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

    <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">
        <activity
            android:name=".activities.HomeActivity"
            android:label="@string/app_name"
            android:screenOrientation="portrait">
            <intent-filter android:label="@string/app_name">
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity
            android:name=".activities.SecondActivity"
            android:label="Example"
            android:screenOrientation="portrait" />
        <activity
            android:name=".activities.ThirdActivity"
            android:label="Test"
            android:screenOrientation="portrait" />
        <activity
            android:name=".activities.FourthActivity"
            android:label="Results"
            android:screenOrientation="portrait" />
    </application>
</manifest>

The problem is that when I try to build I am receiving

Error: error: unknown element < library > found.

Error: error: unknown element < action > found.

Error: error: unknown element < category > found.

I've already check those topics answers: https://stackoverflow.com/a/47017313/9355244 https://stackoverflow.com/a/46948576/9355244

But I am still unable to resolve the problem.

P.S. I am looking for an actual solution not just disabling the AAPT2

Community
  • 1
  • 1
Matt D.
  • 175
  • 1
  • 9
  • 2
    Since this manifest does not have a `` element, it must be coming from some dependency. Examine the "Merged Manifest" sub-tab of the manifest editor in Android Studio and see if you can find the `` element and where it came from. – CommonsWare Mar 15 '18 at 13:05
  • 1
    @CommonsWare thank you very much. The problem was coming from one of the libraries that I was using. – Matt D. Mar 15 '18 at 13:10

0 Answers0