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

Error While Building #3

Closed
umang6891 opened this issue Apr 26, 2017 · 2 comments
Closed

Error While Building #3

umang6891 opened this issue Apr 26, 2017 · 2 comments

Comments

@umang6891
Copy link

umang6891 commented Apr 26, 2017

Lint shows this error when I build the project after adding the library.

../../../../../../.gradle/caches/modules-2/files-2.1/org.bouncycastle/bcprov-jdk15on/1.54/1acdedeb89f1d950d67b73d481eb7736df65eedb/bcprov-jdk15on-1.54.jar: Invalid package reference in library; not included in Android: javax.naming.directory. Referenced from org.bouncycastle.jce.provider.X509LDAPCertStoreSpi. ../../../../../../.gradle/caches/modules-2/files-2.1/org.bouncycastle/bcprov-jdk15on/1.54/1acdedeb89f1d950d67b73d481eb7736df65eedb/bcprov-jdk15on-1.54.jar: Invalid package reference in library; not included in Android: javax.naming. Referenced from org.bouncycastle.jce.provider.X509LDAPCertStoreSpi.

@justinludwig
Copy link
Owner

You can safely ignore this error. One of the classes in the Bouncy Castle library (which handles all the actual crypto for JPGPJ) uses a standard J2SE package (javax.naming.directory) that's not included in Android. Fortunately, this class (X509LDAPCertStoreSpi) isn't PGP-related, so the runtime won't try to load it during normal JPGPJ use.

You can suppress this error by adding a lint.xml file to the root of your Android project with the following:

<?xml version="1.0" encoding="UTF-8"?>
<lint>
    <issue id="InvalidPackage">
        <ignore regexp="X509LDAPCertStoreSpi" />
    </issue>
</lint>

@umang6891
Copy link
Author

Thanks for the update.

leehendryp added a commit to leehendryp/stone_android_challenge that referenced this issue Apr 25, 2020
Ignore issue related to Bouncy Castle Library since one
of its dependencies is not included in Android. Check
justinludwig/jpgpj#3 for further
reference.
leehendryp added a commit to leehendryp/stone_android_challenge that referenced this issue May 2, 2020
Ignore issue related to Bouncy Castle Library since one
of its dependencies is not included in Android. Check
justinludwig/jpgpj#3 for further
reference.
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

2 participants