# Adding an external java Library

**URL:** <https://discourse.processing.org/t/adding-an-external-java-library/1594>\
**Category:** Processing\
**Created:** [July 8, 2018, 2:46pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594 "2018-07-08T14:46:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![DogeMastr](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/dogemastr/32/689_2.png) [@DogeMastr](https://discourse.processing.org/u/DogeMastr)\
**Post date:** [July 8, 2018, 2:46pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594/1 "2018-07-08T14:46:16Z")

</div>

Im trying to import the library [mp3agic](https://github.com/mpatric/mp3agic) and ive gotten to the point where ive used maven to build the .jar file and i have it in the librarys folder like this:  
`Documents/Processing/Librarys/mp3agic/library`  
When I used maven it gave me 3 snapshot jar files, one just called snapshot, one called snapshhot-javadoc and one called snapshot-sources, Processing doesn’t see the library as I cant import it with the add library button  
Ive also tried to drag and drop the file into processing making a code folder and putting the files in there but when I `ìmport mpatric.mp3agic.*`I get an error mpatric cannot be resolved

Any help would be great!

* * *

Doge

PS: I have been reading [this](https://github.com/processing/processing/wiki/How-to-Install-a-Contributed-Library), only the bottom part of the page applies to me and its not very helpful

---

<div class="post-metadata">

**Author:** ![quark](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/quark/32/26_2.png) [@quark](https://discourse.processing.org/u/quark)\
**Post date:** [July 8, 2018, 4:57pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594/2 "2018-07-08T16:57:23Z")

</div>

The path should be …

`Documents/Processing/libraries/XXX/library`  
where XXX is the name of the library jar file without the file ext (`.jar`), beware this is case-sensitive!!!

Note the spelling of `libraries`

So you have two choices

1. Change the library folder to …  
`Documents/Processing/libraries/snapshot/library`  
this assumes that the library jar is called `snapshot.jar`
2. Rename `snapshot.jar` to `mp3ajic.jar` and change the library folder to  
`Documents/Processing/libraries/mp3ajic/library`

---

<div class="post-metadata">

**Author:** ![DogeMastr](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/dogemastr/32/689_2.png) [@DogeMastr](https://discourse.processing.org/u/DogeMastr)\
**Post date:** [July 8, 2018, 6:15pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594/3 "2018-07-08T18:15:45Z")

</div>

Thank you! that did the trick!

---

<div class="post-metadata">

**Author:** ![Kevin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kevin/32/2297_2.png) [@Kevin](https://discourse.processing.org/u/Kevin)\
**Post date:** [July 8, 2018, 6:39pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594/4 "2018-07-08T18:39:14Z")

</div>

Note that you can also just drag the `.jar` file onto the Processing editor.

---

<div class="post-metadata">

**Author:** ![processingCendrum](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/processingcendrum/32/6310_2.png) [@processingCendrum](https://discourse.processing.org/u/processingCendrum)\
**Post date:** [August 31, 2019, 2:13pm UTC](https://discourse.processing.org/t/adding-an-external-java-library/1594/5 "2019-08-31T14:13:23Z")

</div>

Could you share the snapshot.jar file, or, even better, the resulting folder directly?
