# JOGL Error when running Processing 4.0b8 on external IDE with Apple Silicon

**URL:** <https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087>\
**Category:** Processing\
**Created:** [July 25, 2022, 4:15am UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087 "2022-07-25T04:15:04Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![shishironeal](https://avatars.discourse-cdn.com/v4/letter/s/8edcca/32.png) [@shishironeal](https://discourse.processing.org/u/shishironeal)\
**Post date:** [July 25, 2022, 4:15am UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087/1 "2022-07-25T04:15:04Z")

</div>

I originally had a repo for Windows that was working perfectly and I assumed that all I had to do was clone the repo and change the x86 jars to ARM, and that worked for Processing but IntelliJ isn’t recognizing Jogamp.  
I am sure that Processing is consistent with their JOGL version as Processing standalone does work, but not with IntelliJ.

java.lang.UnsatisfiedLinkError: Can’t load library: /Users/Ailun/Documents/GitHub/Tut/natives/macosx-universal/gluegen\_rt  
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2393)  
at java.base/java.lang.Runtime.load0(Runtime.java:755)  
at java.base/java.lang.System.load(System.java:1953)  
at com.jogamp.common.jvm.JNILibLoaderBase.loadLibraryInternal(JNILibLoaderBase.java:625)  
at com.jogamp.common.jvm.JNILibLoaderBase.access$000(JNILibLoaderBase.java:64)  
at com.jogamp.common.jvm.JNILibLoaderBase$DefaultAction.loadLibrary(JNILibLoaderBase.java:107)  
at com.jogamp.common.jvm.JNILibLoaderBase.loadLibrary(JNILibLoaderBase.java:488)  
at com.jogamp.common.os.DynamicLibraryBundle$GlueJNILibLoader.loadLibrary(DynamicLibraryBundle.java:427)  
at com.jogamp.common.os.Platform$1.run(Platform.java:321)  
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)  
at com.jogamp.common.os.Platform.(Platform.java:290)  
at com.jogamp.nativewindow.NativeWindowFactory$1.run(NativeWindowFactory.java:239)  
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)  
at com.jogamp.nativewindow.NativeWindowFactory.(NativeWindowFactory.java:236)  
at com.jogamp.newt.NewtFactory$1.run(NewtFactory.java:69)  
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)  
at com.jogamp.newt.NewtFactory.(NewtFactory.java:66)  
at processing.opengl.PSurfaceJOGL.initIcons(PSurfaceJOGL.java:475)  
at processing.opengl.PSurfaceJOGL.initFrame(PSurfaceJOGL.java:147)  
at processing.core.PApplet.initSurface(PApplet.java:10537)  
at processing.core.PApplet.runSketch(PApplet.java:10443)  
at processing.core.PApplet.main(PApplet.java:10187)  
at Main.main(Main.java:48)

There didn’t exist a natives/macosx-universal folder so I created it and added the gluegen-rt.jar to it, however it has not fixed the issue.  
I have added the folder to the classpath too (I’m using IntelliJ with Gradle so I also added it to the gradle.build), but that didn’t work either.

I would greatly appreciate any help!

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [July 25, 2022, 4:33am UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087/2 "2022-07-25T04:33:52Z")

</div>

Did you import the Processing ‘core’ library into IntelliJ?

---

<div class="post-metadata">

**Author:** ![shishironeal](https://avatars.discourse-cdn.com/v4/letter/s/8edcca/32.png) [@shishironeal](https://discourse.processing.org/u/shishironeal)\
**Post date:** [July 25, 2022, 6:13pm UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087/3 "2022-07-25T18:13:50Z")

</div>

Yes, I have.

```auto
import processing.core.PApplet;

public class Main extends PApplet {

    public void settings(){
        size(600,600, P2D); // If I remove P2D, it works!
    }

    public void setup(){}
    public void draw(){}

    public static void main(String[] args) {
        PApplet.main("Main");
    }
}

```

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [July 25, 2022, 9:18pm UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087/4 "2022-07-25T21:18:00Z")

</div>

I observed basically the same thing on BigSur; removing ‘P2D’ allows it to compile without error. I think `natives/macosx-universal/gluegen_rt` is a jar file. There are several versions online that may be downloaded, but so far adding these to the project folder has not fixed it.

---

<div class="post-metadata">

**Author:** ![LucaP](https://avatars.discourse-cdn.com/v4/letter/l/db5fbb/32.png) [@LucaP](https://discourse.processing.org/u/LucaP)\
**Post date:** [July 26, 2022, 7:44am UTC](https://discourse.processing.org/t/jogl-error-when-running-processing-4-0b8-on-external-ide-with-apple-silicon/38087/5 "2022-07-26T07:44:56Z")

</div>

I had to import all the JOGL and gluegen jar files to get P2D working in IntelliJ.  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/a/7/a78f009f3572fb850dbd19627158e1eecf1ffb41.png)
