Active Topics

 


Reply
Thread Tools
Posts: 1,269 | Thanked: 3,961 times | Joined on May 2011 @ Brazil
#1
The goal of this topic is to know what we need to do to have Fortran on Sailfish OS.

I've found that gcc-fortran is not available on Mer :
list of last Mer packages/
Project Mer-core/gcc
The reason seems to be simply the compilation time on ARM :
Drop fortran support. On armv7l, this drops gcc compile time from 34minutes to 17minute
In June 2013 I've contacted Jolla by email (but I've received no answer) asking the return of gcc-fortran (package which includes gfortran and libraries) to Mer, because :
- the above decision was in 11/2011, now we have faster CPU's (on PC's and smartphones), etc;
- gcc-fortran is :
* useful to anyone who needs to compile Fortran code on device;
* needed as dependency for R-base (statistics language), python-scipy (Python scientific module), etc, or optional dependency for python-numpy (so some NumPy functions become faster) which is dependency of python-pygame (python module for games), python-matplotlib (2D/3D graphics in Python), etc.

What are the options ?
- gcc-fortran should be included by the Mer project when rebuilding "mer-core/gcc.git" (by the Mer-core maintainers) ?
- or gcc-fortran package can be added by the community ?
- or another Fortran (other than gcc-fortran, like g77, f77, etc) can be compiled and package by the community ?
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo/Sailfish :
Integral, Derivative, Limit - calculating mathematical integrals, derivatives and limits. SymPy - Computer Algebra System.
MatPlotLib - 2D & 3D plots in Python. IPython - Python interactive shell.
-- My blog about mobile & scientific computing ---
Sailfish : Sony Xperia X, Gemini, Jolla, Jolla C, Jolla Tablet, Nexus 4. Nokia N9, N900, N810.

Last edited by rcolistete; 2014-09-25 at 15:13.
 

The Following 10 Users Say Thank You to rcolistete For This Useful Post:
Posts: 1,269 | Thanked: 3,961 times | Joined on May 2011 @ Brazil
#2
Reserved for future use.
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo/Sailfish :
Integral, Derivative, Limit - calculating mathematical integrals, derivatives and limits. SymPy - Computer Algebra System.
MatPlotLib - 2D & 3D plots in Python. IPython - Python interactive shell.
-- My blog about mobile & scientific computing ---
Sailfish : Sony Xperia X, Gemini, Jolla, Jolla C, Jolla Tablet, Nexus 4. Nokia N9, N900, N810.
 
Posts: 1,269 | Thanked: 3,961 times | Joined on May 2011 @ Brazil
#3
Citing questions about Fortran from other topics :
- from MatPlotLib for Sailfish topic, about possibility of R-base on Sailfish :
Originally Posted by Kabouik View Post
Thanks for that! I hope you'll port R to Sailfish too someday, can't wait to run/fiddle my scripts on the Jolla!
I've tried to package R-base(-devel) .rpm package, but it seems to need Fortran compiler, which is not available on Mer/Sailfish.

Fortran is optional dependency for some packages (NumPy), and obligatory for others (SciPy, etc).
Originally Posted by nodevel View Post
That's the problem I ran into as well, when trying to package R-base. I'd love to see SciPy too, so it's a bit of a bummer.

I don't know much about Fortran, though. Is it solvable by simply packaging gcc-fortran or does gcc need to be rebuilt altogether?
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo/Sailfish :
Integral, Derivative, Limit - calculating mathematical integrals, derivatives and limits. SymPy - Computer Algebra System.
MatPlotLib - 2D & 3D plots in Python. IPython - Python interactive shell.
-- My blog about mobile & scientific computing ---
Sailfish : Sony Xperia X, Gemini, Jolla, Jolla C, Jolla Tablet, Nexus 4. Nokia N9, N900, N810.
 

The Following 2 Users Say Thank You to rcolistete For This Useful Post:
Posts: 1,269 | Thanked: 3,961 times | Joined on May 2011 @ Brazil
#4
Cited this topic in Sailfish Devel mailing list.
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo/Sailfish :
Integral, Derivative, Limit - calculating mathematical integrals, derivatives and limits. SymPy - Computer Algebra System.
MatPlotLib - 2D & 3D plots in Python. IPython - Python interactive shell.
-- My blog about mobile & scientific computing ---
Sailfish : Sony Xperia X, Gemini, Jolla, Jolla C, Jolla Tablet, Nexus 4. Nokia N9, N900, N810.
 

The Following User Says Thank You to rcolistete For This Useful Post:
Guest | Posts: n/a | Thanked: 0 times | Joined on
#5
fun, I just ran into a project of mine where I need this
Guess Ill start working on porting gfortran .....
 

The Following 6 Users Say Thank You to For This Useful Post:
Posts: 1,873 | Thanked: 4,529 times | Joined on Mar 2010 @ North Potomac MD
#6
My guess is this is not how you want to go about things but I used to run fortran codes on my N900 and still do occasionly on my Andorid phones via a chroot based approach for different linux distributions. Not too worried about having de. Happy to just work from terminal. Does this approach of running fortran currently exist for the Jolla phone? Thanks for your efforts and sorry if this is too OT...
 

The Following User Says Thank You to mscion For This Useful Post:
Posts: 119 | Thanked: 412 times | Joined on Aug 2008
#7
FWIW this is a Mer issue, not a Jolla one IMHO

mer-core plain gcc should not build fortran - it's not part of the core and adds a lot of overhead in the wrong place

my suggested approach (ie how I'd start) is to fork the mer-core gcc package to a gcc-fortran package, copy the spec file to gcc-fortran.spec and modify it so it builds with fortran enabled but no other changes.

Package the delta as gcc-fortran and unpackage any std gcc files in a way that doesn't collide with mer-core gcc.

Eventually submit to mer-tools
 

The Following 8 Users Say Thank You to lbt For This Useful Post:
Posts: 1,269 | Thanked: 3,961 times | Joined on May 2011 @ Brazil
#8
Originally Posted by lbt View Post
FWIW this is a Mer issue, not a Jolla one IMHO

mer-core plain gcc should not build fortran - it's not part of the core and adds a lot of overhead in the wrong place

my suggested approach (ie how I'd start) is to fork the mer-core gcc package to a gcc-fortran package, copy the spec file to gcc-fortran.spec and modify it so it builds with fortran enabled but no other changes.

Package the delta as gcc-fortran and unpackage any std gcc files in a way that doesn't collide with mer-core gcc.

Eventually submit to mer-tools
Thanks !

But mer-tools repository is not enabled by default on device (smartphone, Jolla, Nexus 4/5, etc). So Fortran libraries could not be used as dependencies by other softwares.

Maybe nemo-mw repository would be better as a place for gcc-gfortran.
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo/Sailfish :
Integral, Derivative, Limit - calculating mathematical integrals, derivatives and limits. SymPy - Computer Algebra System.
MatPlotLib - 2D & 3D plots in Python. IPython - Python interactive shell.
-- My blog about mobile & scientific computing ---
Sailfish : Sony Xperia X, Gemini, Jolla, Jolla C, Jolla Tablet, Nexus 4. Nokia N9, N900, N810.

Last edited by rcolistete; 2014-09-26 at 16:27.
 

The Following 2 Users Say Thank You to rcolistete For This Useful Post:
Posts: 119 | Thanked: 412 times | Joined on Aug 2008
#9
before step 2, step 1
 

The Following 2 Users Say Thank You to lbt For This Useful Post:
javispedro's Avatar
Posts: 2,355 | Thanked: 5,249 times | Joined on Jan 2009 @ Barcelona
#10
Originally Posted by lbt View Post
Package the delta as gcc-fortran and unpackage any std gcc files in a way that doesn't collide with mer-core gcc.
If this is done, Mer would be the only distro I know that does this. Is the build overhead added by Fortran _that_ significant?

If I end up doing it this way, I will eventually submit the source package to OBS, so the net result is that that there's duplication of work (because now gcc-{c,c++} is built twice). Right?
 

The Following 6 Users Say Thank You to javispedro For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 21:37.