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

Problems on Android - META-INF #528

Open
paulocoutinhox opened this issue Dec 18, 2018 · 4 comments
Open

Problems on Android - META-INF #528

paulocoutinhox opened this issue Dec 18, 2018 · 4 comments

Comments

@paulocoutinhox
Copy link

paulocoutinhox commented Dec 18, 2018

Hi,

Im trying use nanohttp on Android, but when i use and build i got this error:

More than one file was found with OS independent path 'META-INF/nanohttpd/default-mimetypes.properties'

With this dependencies:

implementation 'org.nanohttpd:nanohttpd-nanolets:2.3.1'
implementation 'org.nanohttpd:nanohttpd:2.3.1'

Can anyone help me?

@b202i
Copy link

b202i commented Jan 29, 2019

I just pasted the source code into a .java file and tailored it from there.

Example in DeepDive

@kenMarquez
Copy link

Same problem, did you solve it?

@paulocoutinhox
Copy link
Author

Hi,

I solve it using snapshot version:

implementation 'org.nanohttpd:nanohttpd:2.3.2-SNAPSHOT'
implementation 'org.nanohttpd:nanohttpd-nanolets:2.3.2-SNAPSHOT'

Thanks.

@kenMarquez
Copy link

kenMarquez commented Sep 5, 2019

After all, I understood that Android tried to generate the apk with several 'META-INF/nanohttpd/*' from several libraries, then I simply combined all of these, and it worked for me adding this on my app/build.gradle.

andorid { .... packagingOptions { merge 'META-INF/nanohttpd/*' } }

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

3 participants