Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android 12 - ReaderSDK - parameter exported in AndroidManifest.xml #38

Open
jantursky opened this issue Dec 22, 2021 · 0 comments
Open

Comments

@jantursky
Copy link

We are using Square ReaderSDK library for implementing communication of Reader with our Point of Sale Android application. We set these two fields for the building of the app to the latest version, because of the need of other libraries, which are requiring it for the correct working:

compileSdkVersion 31
buildToolsVersion 31

Then we also implemented latest Square libs for the above functionality:
implementation "com.squareup.sdk.reader:reader-sdk-$SQUARE_READER_SDK_APPLICATION_ID:1.5.1"
runtimeOnly "com.squareup.sdk.reader:reader-sdk-internals:1.5.1"

Unfortunately, once we tried to build the app even for debug purposes, we received the error message:
Manifest merger failed : android:exported needs to be explicitly specified for . Apps targeting Android 12 and higher are required to specify an explicit value for android:exported when the corresponding component has an intent filter defined. See <activity> | Android Developers 1 for details.

We found, that it’s caused by missing the field android:exported for any component in AndroidManifest.xml file which includes parameter with the body. So we went through the merged manifest (once we decreased/reverted the build version and tried to find which components are missing this field and are blocking us from success building). And it looks like, that this files defined within dependent libraries are missing it:

com.squareup.ui.ApiActivity
com.squareup.ui.LocationActivity
com.squareup.ui.main.ApiMainActivity
com.squareup.queue.QueueService$BootReceiver
com.squareup.notification.LocaleChangeReceiver
com.squareup.cardreader.ble.lock.PosMarkerReceiver

Is there a possibility to add that exported field into this SquareReaderSDK library with also all their dependencies so that it will support also the latest Android version 12 (build version code 31)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant