Login  Register

Re: Newbie Problem, Illegal Reflective Access Warning

Posted by Sven Gothel on Apr 27, 2019; 12:19pm
URL: https://forum.jogamp.org/Newbie-Problem-Illegal-Reflective-Access-Warning-tp4039750p4039751.html

The warnings will be resolved when we have
completed Java 11 support.
See bug 1363 (feature) <https://jogamp.org/bugzilla/show_bug.cgi?id=1363>
or
<https://jogamp.org/wiki/index.php?title=SW_Tracking_Report_Feature_Objectives_Overview#Java_11>

~Sven

On 4/27/19 3:59 AM, LuminousNutria [via jogamp] wrote:

> Hello, I'm going through a tutorial on YouTube, but my console is giving me
> warnings. I want to avoid any problems, and make my code run without warnings,
> but I'm not sure what to do. I am running jogl on Ubuntu 18.04 and IntelliJ IDEA.
>
> *The warning is:*
>
> /usr/lib/jvm/jdk-11/bin/java
> -javaagent:/home/my_name/idea-IU-183.5153.38/lib/idea_rt.jar=39027:/home/my_name/idea-IU-183.5153.38/bin
> -Dfile.encoding=UTF-8 -classpath
> /home/my_name/Desktop/My_Game/out/production/My_Game:/home/my_name/Java_Libraries/jogamp/jogl-all.jar:/home/my_name/Java_Libraries/jogamp/gluegen-rt.jar:/home/my_name/Java_Libraries/jogamp/jogl-java-src.zip:/home/my_name/Java_Libraries/jogamp/gluegen-java-src.zip:/home/my_name/Java_Libraries/jogamp/jogl-all-natives-linux-amd64.jar:/home/my_name/Java_Libraries/jogamp/gluegen-rt-natives-linux-amd64.jar
> Tutorial.Main
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by com.jogamp.common.os.NativeLibrary$3
> (file:/home/my_name/Java_Libraries/jogamp/gluegen-rt.jar) to method
> java.lang.ClassLoader.findLibrary(java.lang.String)
> WARNING: Please consider reporting this to the maintainers of
> com.jogamp.common.os.NativeLibrary$3
> WARNING: Use --illegal-access=warn to enable warnings of further illegal
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> X11Util.Display: Shutdown (JVM shutdown: true, open (no close attempt): 2/2,
> reusable (open, marked uncloseable): 0, pending (open in creation order): 2)
> X11Util: Open X11 Display Connections: 2
> X11Util: Open[0]: NamedX11Display[:0, 0x7f7510001a70, refCount 1, unCloseable
> false]
> X11Util: Open[1]: NamedX11Display[:0, 0x7f7510016160, refCount 1, unCloseable
> false]
>
> Process finished with exit code 0
>
> *The code I'm trying to run.*
>
> package Tutorial;
>
> import com.jogamp.newt.opengl.GLWindow;
> import com.jogamp.opengl.GLCapabilities;
> import com.jogamp.opengl.GLProfile;
>
>
> public class Renderer {
>
>    private static GLWindow window = null;
>
>    // I run this method in another file just by calling Renderer.init() in the
> main method.
>    public static void init () {
>
>       GLProfile.initSingleton();
>
>       GLProfile profile = GLProfile.get(GLProfile.GL2);
>       GLCapabilities caps = new GLCapabilities(profile);
>
>       window = GLWindow.create(caps);
>       window.setSize(640, 360);
>       window.setResizable(false);
>
>       window.setVisible(true);
>    }
> }
>
>
>
> *Tutorial Link:*
>
> https://www.youtube.com/watch?v=2KmAZ48-M5c&t=11s
>
>