[Gsoc] Week 1 Blog and a few doubts

classic Classic list List threaded Threaded
5 messages Options
Divyanshu Kumar Divyanshu Kumar
Reply | Threaded
Open this post in threaded view
|

[Gsoc] Week 1 Blog and a few doubts

Hello World,

I am Divyanshu Kumar, and I am working on "signed Mac OS app" project with Scilab.

I am thankful to my mentors for allowing me to focus on my exams and practicals till 14/05. From now on I will be writing blogs on alternate days or so, and index of which can be found

I will be happy to receive comments and suggestions about my pages and blogs.
Currently there is only one blog (14-15 May): https://dvkcool.github.io/gsoc-2018/blog/1405.html

Also a few dependencies mentioned for Mac OS are either outdated/ unavailable, so I have mentioned newer version os alternate, please have a look and do let me know if there is a problem in changing the versions of same:

Regards
Divyanshu Kumar.


_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc
Paul Bignier Paul Bignier
Reply | Threaded
Open this post in threaded view
|

Re: Week 1 Blog and a few doubts


Hello dvk,

You based your instructions on https://wiki.scilab.org/Compiling%20Scilab%20under%20MacOSX, right?
It's good to use fink (insteard of port) indeed.
The wiki page is outdated, you are right to update the versions references, thank you for listing them.
Once you have an updated list of packages and make sure that compilation passes and Scilab starts OK, please update the wiki page.
But before you update it, I'll compare your new package list with mine (tonight maybe?) and give you a feedback.

Kind regards,
Paul


Paul BIGNIER
Development engineer
-----------------------------------------------------------
ESI Group - Scilab
99 rue des Solets - 94513 Rungis, France
Phone: +33.1.41.73.58.77
https://scilab.io
https://esi-group.com




From: gsoc <[hidden email]> on behalf of Divyanshu Kumar <[hidden email]>
Sent: Tuesday, May 15, 2018 10:42 AM
To: [hidden email]
Subject: [Gsoc] Week 1 Blog and a few doubts
 
Hello World,

I am Divyanshu Kumar, and I am working on "signed Mac OS app" project with Scilab.

I am thankful to my mentors for allowing me to focus on my exams and practicals till 14/05. From now on I will be writing blogs on alternate days or so, and index of which can be found

I will be happy to receive comments and suggestions about my pages and blogs.
Currently there is only one blog (14-15 May): https://dvkcool.github.io/gsoc-2018/blog/1405.html

Also a few dependencies mentioned for Mac OS are either outdated/ unavailable, so I have mentioned newer version os alternate, please have a look and do let me know if there is a problem in changing the versions of same:

Regards
Divyanshu Kumar.


_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc
Divyanshu Kumar Divyanshu Kumar
Reply | Threaded
Open this post in threaded view
|

Re: Week 1 Blog and a few doubts

Hello everyone,
I guess there has been a small connection error on the IRC, I think my messages were somehow not sent properly to my mentor.
So I am sending a mail regarding same:
I have finally completed working on the script which downloads all dependencies and also compiles and installs scilab on Mac OS, which can be found here: https://github.com/dvkcool/scilab-work/blob/master/Script/scilabDependenciesInstallerAndCompiler.sh .

I have tested for various cases, I have also included options to take choice of branch, getting different jdk path if required additional parameters from the user.

However I still have a few doubts regarding same:
1. JDK 10 won't work with Scilab compilation, because compilation of Scilab requires javah which has been discontinued, and instead javac with -h is suggested, so how to change the build process,
Its not difficult to replace `javah` with `javac -h`, but I wasn't able to figure out where, if someone could help me with which modules should I change, it could be great help.

2. Also the LD_LIBRARY_PATH  doesn't work well in Mac, so I did copy all the third party to lib folder of jdk it did solve the requirement, also I did include this in my script, (line 445- 455 in scilabDependenciesInstallerAndCompiler.sh
So is it ok if I do so, I mean what if user requires the third party libs for the softwares and downloads
However the downloaded lib files don't work well with Scilab compilation in Mac.
(More details can be found on my blog, especially here https://dvkcool.github.io/gsoc-2018/blog/1905.html)

3. How to check for integrity of git clone, I can think of an alternative of md5 checksum check, but if anyone else could suggest an easier alternative, it would highly appreciated.

also my blog index can be found here: https://dvkcool.github.io/gsoc-2018/blog/index.html

I would be happy to receive suggestions for above mentioned doubts.
Regards
Divyanshu Kumar
NIT Raipur

On Tue, May 15, 2018 at 6:14 PM, Paul Bignier <[hidden email]> wrote:


Hello dvk,

You based your instructions on https://wiki.scilab.org/Compiling%20Scilab%20under%20MacOSX, right?
It's good to use fink (insteard of port) indeed.
The wiki page is outdated, you are right to update the versions references, thank you for listing them.
Once you have an updated list of packages and make sure that compilation passes and Scilab starts OK, please update the wiki page.
But before you update it, I'll compare your new package list with mine (tonight maybe?) and give you a feedback.

Kind regards,
Paul


Paul BIGNIER
Development engineer
-----------------------------------------------------------
ESI Group - Scilab
99 rue des Solets - 94513 Rungis, France
Phone: +33.1.41.73.58.77
https://scilab.io
https://esi-group.com




From: gsoc <[hidden email]> on behalf of Divyanshu Kumar <[hidden email]>
Sent: Tuesday, May 15, 2018 10:42 AM
To: [hidden email]
Subject: [Gsoc] Week 1 Blog and a few doubts
 
Hello World,

I am Divyanshu Kumar, and I am working on "signed Mac OS app" project with Scilab.

I am thankful to my mentors for allowing me to focus on my exams and practicals till 14/05. From now on I will be writing blogs on alternate days or so, and index of which can be found

I will be happy to receive comments and suggestions about my pages and blogs.
Currently there is only one blog (14-15 May): https://dvkcool.github.io/gsoc-2018/blog/1405.html

Also a few dependencies mentioned for Mac OS are either outdated/ unavailable, so I have mentioned newer version os alternate, please have a look and do let me know if there is a problem in changing the versions of same:

Regards
Divyanshu Kumar.


_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc




--
Sent from Divyanshu's Tablet pc

_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc
Clément David-3 Clément David-3
Reply | Threaded
Open this post in threaded view
|

Re: Week 1 Blog and a few doubts

Hello Divyanshu,

Thanks for the update, answered inline.

Le vendredi 25 mai 2018 à 00:23 +0530, Divyanshu Kumar a écrit :
> 1. JDK 10 won't work with Scilab compilation, because compilation of Scilab requires javah which
> has been discontinued, and instead javac with -h is suggested, so how to change the build process,
> Its not difficult to replace `javah` with `javac -h`, but I wasn't able to figure out where, if
> someone could help me with which modules should I change, it could be great help.

Great! That's the point of this GSoC, patching Scilab to avoid issue while making a macOS build. To
fix the javah detection you should :

 1. remove javah detection m4/java.m4
 2. run automake to evaluate the m4 script and store the result into configure
 
Be sure to preserve the automake version to have a good diff.

> 2. Also the LD_LIBRARY_PATH  doesn't work well in Mac, so I did copy all the third party to lib
> folder of jdk it did solve the requirement, also I did include this in my script, (line 445- 455
> in scilabDependenciesInstallerAndCompiler.sh)
> So is it ok if I do so, I mean what if user requires the third party libs for the softwares and
> downloads
> However the downloaded lib files don't work well with Scilab compilation in Mac.
> (More details can be found on my blog, especially here https://dvkcool.github.io/gsoc-2018/blog/19
> 05.html)

You should not copy Scilab libs into the system ones otherwise users with limited rights on their
systems will not be able to launch Scilab at all. This is probably related to some issues with
DYLD_LIBRARY_PATH usage on the launcher script.

> 3. How to check for integrity of git clone, I can think of an alternative of md5 checksum check,
> but if anyone else could suggest an easier alternative, it would highly appreciated.

The git clone command by itself ensure that the local data are OK. There is no extra integrity check
 to perform. If you are unsure about the "clean" status of your checked out repository, use `git
clean -fxd`. This will remove all untracked files including the Scilab thirdparties.

Thanks,

--
Clément


> On Tue, May 15, 2018 at 6:14 PM, Paul Bignier <[hidden email]> wrote:
> > Hello dvk,
> >
> > You based your instructions on https://wiki.scilab.org/Compiling%20Scilab%20under%20MacOSX,
> > right?
> > It's good to use fink (insteard of port) indeed.
> > The wiki page is outdated, you are right to update the versions references, thank you for
> > listing them.
> > Once you have an updated list of packages and make sure that compilation passes and Scilab
> > starts OK, please update the wiki page.
> > But before you update it, I'll compare your new package list with mine (tonight maybe?) and give
> > you a feedback.
> >
> > Kind regards,
> > Paul
> >
> > Paul BIGNIER
> > Development engineer
> > -----------------------------------------------------------
> > ESI Group - Scilab
> > 99 rue des Solets - 94513 Rungis, France
> > Phone: +33.1.41.73.58.77
> > https://scilab.io
> > https://esi-group.com
> >
> >
> > From: gsoc <[hidden email]> on behalf of Divyanshu Kumar <[hidden email]
> > om>
> > Sent: Tuesday, May 15, 2018 10:42 AM
> > To: [hidden email]
> > Subject: [Gsoc] Week 1 Blog and a few doubts
> >  
> > Hello World,
> >
> > I am Divyanshu Kumar, and I am working on "signed Mac OS app" project with Scilab.
> >
> > I am thankful to my mentors for allowing me to focus on my exams and practicals till 14/05. From
> > now on I will be writing blogs on alternate days or so, and index of which can be found
> > here: https://dvkcool.github.io/gsoc-2018/blog/index.html
> >
> > I will be happy to receive comments and suggestions about my pages and blogs.
> > Currently there is only one blog (14-15 May): https://dvkcool.github.io/gsoc-2018/blog/1405.html
> >
> > Also a few dependencies mentioned for Mac OS are either outdated/ unavailable, so I have
> > mentioned newer version os alternate, please have a look and do let me know if there is a
> > problem in changing the versions of same:
> > https://dvkcool.github.io/gsoc-2018/blog/1405.html#package-table
> >
> > Regards
> > Divyanshu Kumar.
> >
> >
> > _______________________________________________
> > gsoc mailing list
> > [hidden email]
> > http://lists.scilab.org/mailman/listinfo/gsoc
> >
>
>
>
> _______________________________________________
> gsoc mailing list
> [hidden email]
> http://lists.scilab.org/mailman/listinfo/gsoc
_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc
Divyanshu Kumar Divyanshu Kumar
Reply | Threaded
Open this post in threaded view
|

Re: Week 1 Blog and a few doubts

Thanks a lot for helping out,
I thought I will reply with the patch directly, but after so many tries to, I am unable to get it working with jdk10, 
I have included my most meaningful tries here: https://dvkcool.github.io/gsoc-2018/blog/406.html

I have included error log too, can some suggest how to overcome these,

Also in short of these meaningful tries: 
1. Removing javah detection from m4/java.m4 => Running autoreconf command => Running ./configure to install and check and it fails with error log: https://github.com/dvkcool/scilab-work/blob/master/outputs/configlog1.log

2. Tried with gcc5 compiler instead of clang shipped with Mac too, but still similar issue: => https://github.com/dvkcool/scilab-work/blob/master/outputs/configlog2.log

3. Also if I run the ./configure  with jdk8 and remove and install jdk10, then run ./configure again, it compiles, but while starting it results in ClassNitFound Exception, I guess that is due to compilation with jdk8 and then removing it. However I don't like this approach either because why will someone install jdk8 and then remove it just for sake of compilation.

and a bugzilla issue for same: http://bugzilla.scilab.org/show_bug.cgi?id=15328

If someone could please tell me what I might be doing wrong, please do let me know,
However I have seen most of the softwares still support jdk8 only including the gradle build for android apps, so is it very necessary to port it to jdk10.
Regards
Divyanshu Kumar
NIT Raipur





On Mon, May 28, 2018 at 2:24 PM, Clément David <[hidden email]> wrote:
Hello Divyanshu,

Thanks for the update, answered inline.

Le vendredi 25 mai 2018 à 00:23 +0530, Divyanshu Kumar a écrit :
> 1. JDK 10 won't work with Scilab compilation, because compilation of Scilab requires javah which
> has been discontinued, and instead javac with -h is suggested, so how to change the build process,
> Its not difficult to replace `javah` with `javac -h`, but I wasn't able to figure out where, if
> someone could help me with which modules should I change, it could be great help.

Great! That's the point of this GSoC, patching Scilab to avoid issue while making a macOS build. To
fix the javah detection you should :

 1. remove javah detection m4/java.m4
 2. run automake to evaluate the m4 script and store the result into configure

Be sure to preserve the automake version to have a good diff.

> 2. Also the LD_LIBRARY_PATH  doesn't work well in Mac, so I did copy all the third party to lib
> folder of jdk it did solve the requirement, also I did include this in my script, (line 445- 455
> in scilabDependenciesInstallerAndCompiler.sh)
> So is it ok if I do so, I mean what if user requires the third party libs for the softwares and
> downloads
> However the downloaded lib files don't work well with Scilab compilation in Mac.
> (More details can be found on my blog, especially here https://dvkcool.github.io/gsoc-2018/blog/19
> 05.html)

You should not copy Scilab libs into the system ones otherwise users with limited rights on their
systems will not be able to launch Scilab at all. This is probably related to some issues with
DYLD_LIBRARY_PATH usage on the launcher script.

> 3. How to check for integrity of git clone, I can think of an alternative of md5 checksum check,
> but if anyone else could suggest an easier alternative, it would highly appreciated.

The git clone command by itself ensure that the local data are OK. There is no extra integrity check
 to perform. If you are unsure about the "clean" status of your checked out repository, use `git
clean -fxd`. This will remove all untracked files including the Scilab thirdparties.

Thanks,

--
Clément


> On Tue, May 15, 2018 at 6:14 PM, Paul Bignier <[hidden email]> wrote:
> > Hello dvk,
> >
> > You based your instructions on https://wiki.scilab.org/Compiling%20Scilab%20under%20MacOSX,
> > right?
> > It's good to use fink (insteard of port) indeed.
> > The wiki page is outdated, you are right to update the versions references, thank you for
> > listing them.
> > Once you have an updated list of packages and make sure that compilation passes and Scilab
> > starts OK, please update the wiki page.
> > But before you update it, I'll compare your new package list with mine (tonight maybe?) and give
> > you a feedback.
> >
> > Kind regards,
> > Paul
> >
> > Paul BIGNIER
> > Development engineer
> > -----------------------------------------------------------
> > ESI Group - Scilab
> > 99 rue des Solets - 94513 Rungis, France
> > Phone: +33.1.41.73.58.77
> > https://scilab.io
> > https://esi-group.com
> >
> >
> > From: gsoc <[hidden email]> on behalf of Divyanshu Kumar <[hidden email]
> > om>
> > Sent: Tuesday, May 15, 2018 10:42 AM
> > To: [hidden email]
> > Subject: [Gsoc] Week 1 Blog and a few doubts
> > 
> > Hello World,
> >
> > I am Divyanshu Kumar, and I am working on "signed Mac OS app" project with Scilab.
> >
> > I am thankful to my mentors for allowing me to focus on my exams and practicals till 14/05. From
> > now on I will be writing blogs on alternate days or so, and index of which can be found
> > here: https://dvkcool.github.io/gsoc-2018/blog/index.html
> >
> > I will be happy to receive comments and suggestions about my pages and blogs.
> > Currently there is only one blog (14-15 May): https://dvkcool.github.io/gsoc-2018/blog/1405.html
> >
> > Also a few dependencies mentioned for Mac OS are either outdated/ unavailable, so I have
> > mentioned newer version os alternate, please have a look and do let me know if there is a
> > problem in changing the versions of same:
> > https://dvkcool.github.io/gsoc-2018/blog/1405.html#package-table
> >
> > Regards
> > Divyanshu Kumar.
> >
> >
> > _______________________________________________
> > gsoc mailing list
> > [hidden email]
> > http://lists.scilab.org/mailman/listinfo/gsoc
> >
>
>
>
> _______________________________________________
> gsoc mailing list
> [hidden email]
> http://lists.scilab.org/mailman/listinfo/gsoc
_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc



--
Sent from Divyanshu's Tablet pc

_______________________________________________
gsoc mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/gsoc