[Scilab-Dev] [Scilab-users] Issue on Scilab Compilation on Raspbery Pi
Chin Luh Tan
chinluh.tan at bytecode-asia.com
Tue May 12 08:06:22 CEST 2020
Hi Clement,
I was trying a few distribution of the linux available for Raspberry Pi 4, and with the binary Scilab 6.1 obtained from each repository, all of the would have the issue of crashing when enter a = 0 (Change https://codereview.scilab.org/21446 )
So I was trying to recompile the Scilab from scratch with the libraries installed with apt-get, and a few challenges I faced:
1. Some jar file was there but could not be detected, some could be resolved by removing the version checking in the configure.ac file, such as jlatexmath.
2. fop detected using the fop-transcoder.jar which fail the following detection
3. Xcos cant be build, error during make.
After all these has been fulfilled, the compilation done but scilab launch with segmentation fault.
So my current work around is to use the libsciast.so from the compiled version to replace the binary version in order to workaround on the '0' issue, so far it seems like working, will test more.
If there is any more guidance to build everything properly and permanent for future build, it will be much appreciated.
Thanks again.
Regards,
Chin Luh
---- On Mon, 11 May 2020 15:09:42 +0800 Clément David <Clement.David at esi-group.com> wrote ----
Hi Tan,
AFAIK configure on macOS does not check the dylibs [1]. The jar file detected on the thirdparty directory should be enough.
[1]: https://cgit.scilab.org/scilab/tree/scilab/configure.ac#n954
Thanks,
--
Clément
From: dev <mailto:dev-bounces at lists.scilab.org> On Behalf Of Chin Luh Tan
Sent: Friday, May 8, 2020 11:31 AM
To: List dedicated to the development of Scilab <mailto:dev at lists.scilab.org>
Subject: Re: [Scilab-Dev] [Scilab-users] Issue on Scilab Compilation on Raspbery Pi
Hi Stephane,
Just some updates, I was trying create the thirdparty folder and lib\thirdparty folder to manually put the jar and libraries in but unfortunately the configure script did not
pick up the folders. I will look further into the codes.
Thanks.
Regards,
Chin Luh
---- On Thu, 07 May 2020 22:02:48 +0800 Stéphane Mottelet <mailto:stephane.mottelet at utc.fr> wrote ----
Le 07/05/2020 à 15:51, Chin Luh Tan a écrit :
Hi Stephane,
Thanks, I will give a try on that.
As there are no repository for 2.2,
All versions of JoGL are available on the official site. E.g. latests 2.2.x is here:
https://jogamp.org/deployment/v2.2.4/archive/
base on your experience in Mac, do we need to recompile the whole lib, or we could just use the binary/libs from the jogl web? If so, how should we place the libs and jar in
the system?
in the scilab/thirdparty (for jars) and scilab/lib/thidparty (for jni libs)
The previous Mac compilation the dylib were place in the thirdparty folder, but now as I am not using any thirparty from the scilab github, how should I get the scilab to refer
to the locations?
Just uninstall the .deb JoGL package and the configure script will hopefully find its way to the version you put in thirdparty folders.
S.
Thanks again for advice.
Regards,
Chin Luh
---- On Thu, 07 May 2020 20:44:33 +0800 Stéphane Mottelet mailto:stephane.mottelet at utc.fr wrote ----
Hi,
Le 07/05/2020 à 14:29, Chin Luh Tan a écrit :
Hi Stephane,
I applied the patch Change https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/codereview.scilab.org/17530 but
not the Change https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/codereview.scilab.org/21438,
as the original configure.ac still searching for Jogl 2.2.
I tried the path set 5 and 8 from changes 17530, both compile the scilab with minor modification on the fop (to enable detection).
As I am trying to compile in Arm environment, I have to install the 3rd parties from apt-get, and with those libs installed, "configure" was able to "pass" for the make.
i think the issue is on the jogl now? The parts which differentiate 2.2. and 2.3 were mentioned in the configure.ac:
AC_JAVA_CHECK_JAR([jogl2],[javax.media.opengl.glu.GLUnurbs],[Scilab 3D rendering - Version 2.0], [], [], [2.2])
AC_JAVA_CHECK_JAR([jogl2],[jogamp.opengl.x11.glx.GLX],[Scilab 3D rendering - Version 2.3], [], [], 2.3)
On the source point of view, 2.3 version changed all class headers, but there are surely may other changes in the implementation.
AC_JAVA_CHECK_JAR([gluegen2-rt],[jogamp.common.os.MachineDescriptionRuntime],[Scilab 3D rendering])
AC_JAVA_CHECK_JAR([gluegen2-rt],[com.jogamp.common.os.Platform],[Scilab 3D rendering])
Should I use the Jogl2.2 for the compilation and use the original configure.ac?
I think so. Just to test that the problem still occurs (or not) with 2.2.
S.
Thanks.
Regards,
Chin Luh
---- On Thu, 07 May 2020 01:42:51 +0800 Stéphane Mottelet mailto:stephane.mottelet at utc.fr wrote ----
If you apply the JoGL patch then third parties have to be updated as well. I think you did it. But since this patch is not needed for Linux, I would try to compile with previous
version.
S.
Le 6 mai 2020 à 18:52, Chin Luh Tan <mailto:chinluh.tan at bytecode-asia.com>
a écrit :
sorry pls ignore the previous incomplete email which has been accidentally sent:
I tried to compile scilab 6.1 under raspberry pi 4, and the compilation completed with scilab lauched with following messages:
Caught handled GLException: EGLGLXDrawableFactory - Could not initialize shared resources for EGLGraphicsDevice[type .egl, v1.4.0,
connection :0.0, unitID 0, handle 0xffffffffa8b148f0, owner true, ResourceToolkitLock[obj 0xb29daf, isOwner true, <1fa6506, f15db4>[count 1, qsz 0, owner <main-SharedResourceRunner>]]] on thread main-SharedResourceRunner
[0]: jogamp.opengl.egl.EGLDrawableFactory$SharedResourceImplementation.createSharedResource(EGLDrawableFactory.java:518)
[1]: jogamp.opengl.SharedResourceRunner.run(SharedResourceRunner.java:353)
[2]: java.lang.Thread.run(Thread.java:748)
Caused[0] by NoSuchMethodError: java.nio.IntBuffer.rewind()Ljava/nio/IntBuffer; on thread main-SharedResourceRunner
[0]: com.jogamp.common.nio.Buffers.newDirectIntBuffer(Buffers.java:146)
[1]: com.jogamp.common.nio.Buffers.newDirectIntBuffer(Buffers.java:150)
[2]: com.jogamp.common.nio.Buffers.newDirectIntBuffer(Buffers.java:154)
[3]: jogamp.opengl.egl.EGLGraphicsConfiguration.EGLConfig2Capabilities(EGLGraphicsConfiguration.java:221)
[4]: jogamp.opengl.egl.EGLGraphicsConfigurationFactory.eglConfigs2GLCaps(EGLGraphicsConfigurationFactory.java:481)
[5]: jogamp.opengl.egl.EGLDrawableFactory.getAvailableEGLConfigs(EGLDrawableFactory.java:962)
[6]: jogamp.opengl.egl.EGLDrawableFactory.access$800(EGLDrawableFactory.java:88)
[7]: jogamp.opengl.egl.EGLDrawableFactory$SharedResourceImplementation.mapAvailableEGLESConfig(EGLDrawableFactory.java:679)
[8]: jogamp.opengl.egl.EGLDrawableFactory$SharedResourceImplementation.createEGLSharedResourceImpl(EGLDrawableFactory.java:613)
[9]: jogamp.opengl.egl.EGLDrawableFactory$SharedResourceImplementation.createSharedResource(EGLDrawableFactory.java:516)
[10]: jogamp.opengl.SharedResourceRunner.run(SharedResourceRunner.java:353)
[11]: java.lang.Thread.run(Thread.java:748)
Caught handled GLException: X11GLXDrawableFactory - Could not initialize shared resources for X11GraphicsDevice[type .x11, connection
:0.0, unitID 0, handle 0x0, owner false, ResourceToolkitLock[obj 0x1f4f0f8, isOwner false, <1c08638, 40f0>[count 0, qsz 0, owner <NULL>]]] on thread main-SharedResourceRunner
[0]: jogamp.opengl.x11.glx.X11GLXDrawableFactory$SharedResourceImplementation.createSharedResource(X11GLXDrawableFactory.java:306)
[1]: jogamp.opengl.SharedResourceRunner.run(SharedResourceRunner.java:353)
[2]: java.lang.Thread.run(Thread.java:748)
while I am still able to launch the Scilab and perform most operation, however, when I tried to plot a figure, i get:
java.lang.reflect.InvocationTargetException
at java.awt.EventQueue.invokeAndWait(EventQueue.java:1349)
at java.awt.EventQueue.invokeAndWait(EventQueue.java:1324)
at javax.swing.SwingUtilities.invokeAndWait(SwingUtilities.java:1353)
at org.scilab.modules.gui.SwingView.updateObject(Unknown Source)
at org.scilab.modules.graphic_objects.graphicController.GraphicController$2.run(Unknown Source)
at org.scilab.modules.graphic_objects.graphicController.GraphicController.objectUpdate(Unknown Source)
at org.scilab.modules.graphic_objects.graphicController.GraphicController.setGraphicObjectRelationship(Unknown Source)
at org.scilab.modules.graphic_objects.builder.Builder.cloneAxesModel(Unknown Source)
at org.scilab.modules.graphic_objects.builder.Builder.createNewFigureWithAxes(Unknown Source)
Caused by: com.jogamp.opengl.GLException: Profile GL_DEFAULT is not available on X11GraphicsDevice[type .x11, connection :0.0, unitID
0, handle 0x0, owner false, ResourceToolkitLock[obj 0x1f4f0f8, isOwner false, <1c08638, 40f0>[count 0, qsz 0, owner <NULL>]]], but: []
at com.jogamp.opengl.GLProfile.get(GLProfile.java:991)
at com.jogamp.opengl.GLProfile.getDefault(GLProfile.java:722)
at com.jogamp.opengl.awt.GLJPanel.<init>(GLJPanel.java:363)
at com.jogamp.opengl.awt.GLJPanel.<init>(GLJPanel.java:337)
at com.jogamp.opengl.awt.GLJPanel.<init>(GLJPanel.java:325)
at org.scilab.modules.gui.bridge.canvas.SwingScilabCanvasImpl$SafeGLJPanel.<init>(Unknown Source)
at org.scilab.modules.gui.bridge.canvas.SwingScilabCanvasImpl$SafeGLJPanel.<init>(Unknown Source)
at org.scilab.modules.gui.bridge.canvas.SwingScilabCanvasImpl.createOpenGLComponent(Unknown Source)
.
Any suggestion what I need to change for the compilation?
I compile scilab with:
1. gcc, g++, gfortran v 8, and also another try on v9
2. openjdk-8-jdk
3. Tried Raspbian, Ubuntu for Pi 18.04 , same issue.
4. Applied jogl 2.3.2 patch.
Thanks.
Rgds,
CL
---- On Thu, 07 May 2020 00:45:23 +0800 Chin Luh Tan <mailto:chinluh.tan at bytecode-asia.com> wrote ----
Hi,
I tried to compile scilab 6.1 under raspberry pi 4, and the compilation completed with scilab lauched with following messages:
_______________________________________________
users mailing list
mailto:users at lists.scilab.org
https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/dev
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/dev
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/dev
--
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/www.utc.fr/~mottelet
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
http://lists.scilab.org/mailman/listinfo/dev
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/dev
--
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
http://www.utc.fr/~mottelet
_______________________________________________
dev mailing list
mailto:dev at lists.scilab.org
http://lists.scilab.org/mailman/listinfo/dev
_______________________________________________
dev mailing list
dev at lists.scilab.org
http://lists.scilab.org/mailman/listinfo/dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/dev/attachments/20200512/5e8db55d/attachment.htm>
More information about the dev
mailing list