forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Clearwin on Linux and Windows
Goto page 1, 2  Next
 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+
View previous topic :: View next topic  
Author Message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Wed Oct 26, 2022 11:46 am    Post subject: Clearwin on Linux and Windows Reply with quote

I see Gino GUI builder works on both Windows and Linux, while Winteracter staying itself on Windows communicates with Linux via network (X Windows). How difficult to make Clearwin to work on Linux or at least on Linux virtually via X Windows?

Does Clearwin work with other compilers on Windows besides gFortran ?
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Wed Oct 26, 2022 1:32 pm    Post subject: Reply with quote

I have used ClearWin+ on Windows with Intel iFort as well as gFortran and I plan to provide a YouTube demo shortly.
Back to top
View user's profile Send private message AIM Address
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Thu Oct 27, 2022 11:40 pm    Post subject: Reply with quote

Fortran Standard 2018 pays now attention on better language interoperability of Fortran with all other languages, not just C/C++. Julia and Python could come probably next. That also automatically means better interoperability between different Fortran compilers too, not just fancy like Julia or Python .

Definitely here something has to be done right now. I tried Clearwin with gFortran and immediately got a punch into the face that my gFortran 13 can not use pre-built modules of Clearwin made with gFortran 8. If we will change versions every year this sounds like a disaster. OK, not a problem, the option was mentioned in Help to compile Clearwin themselves, but no examples were given.

Also there was mentioned the advise/requirement for parallel development of two Clearwin applications - native for FTN95 and foreign for gFortran/Intel/NAG/etc. This is i guess because something can not be done if you use different compiler. Is this advise still the live option with Clearwin in case of mixing parts of the code with different compilers ? If differences were minimal it would be OK even without two versions. Pre-compiler options come to mind but for them FTN95 has to adjust to C/C++ style for that like all other Fortran compilers already using while FTN95 still has its own ones, MUCH less capable and which will not allow broader interoperability. Curious how Gino succeeded to make an universal application for all compilers and OSes, did it miss a lot on that road ? I never used Gino, third party apps is on a long run almost always a bad idea. Somehow Gino and Winteracter in 25 years still not dead but that was due to support of big boys like Apple with Absoft and in part Intel. Both of them will go sideways from now. Absoft is dead, and Intel will not have any resources to support its Windows app, look in its disastrous shape last couple years - a total mess. Linux version though works perfectly thanks to support from even bigger big boys, like S&P 500 companies and top500 supercomputers (all but one Linux). This why FTN95, its developers and all users of Windows should look at Linux too. It became beautiful OS, it overjumped Windows finally because all billions cell phones work on Linux. Most of applications look fresh and classy, while Windows ones dull, boring and ugly. Try to install VirtualBox and customize it additionally with the Extension kit and some apps and in 1-3 hours you will see that yourselves. Just the editor Kate is a pure masterpiece. VirtualBox makes your PC Windows and Linux at the same time, you do not like it - just uninstall it and install Hyper-V with another Windows or even DOS 2.1 to play Tetris 1.0 on CGA screen Smile Very convenient and useful app.

Native PL was also not implemented as Help says. But that was years ago. Is it implemented now?


Last edited by DanRRight on Fri Oct 28, 2022 9:56 am; edited 1 time in total
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Fri Oct 28, 2022 7:15 am    Post subject: Reply with quote

Quote:
Native PL was also not implemented as Help says. But that was years ago. Is it implemented now?


In what context was it not implemented?
Back to top
View user's profile Send private message AIM Address
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Fri Oct 28, 2022 8:32 am    Post subject: Reply with quote

I do not know. I am just citing the Help file :

Code:
%pl      has not been implemented for 64 bit ClearWin+.
 


Also it says
Code:
%og  Stricter type checking in gFortran means that some scalar arguments (to OpenGL functions) must be changed to one-element arrays.
 


What that exactly means and how it will look to fix it?
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Fri Oct 28, 2022 10:18 am    Post subject: Reply with quote

%pl is available in 64 bit ClearWin+. I can't find the statement that you quote.

For %og you only need to make a change when you get a compile time failure. Then a scalar argument v must be changed to an array v with one element.
Back to top
View user's profile Send private message AIM Address
mecej4



Joined: 31 Oct 2006
Posts: 1885

PostPosted: Fri Oct 28, 2022 10:39 am    Post subject: Reply with quote

Dan, argument checking in newer versions of Gfortran can become a nuisance with old codes in which scalar arguments are passed as arguments when the corresponding dummy argument is an array. If such mismatched arguments are then passed along as arguments to other subroutines in a chain, fixing the code can be time-consuming.

If you do not mind taking a slight risk, and you are sure that the code being compiled is otherwise error free, try the Gfortran option -fallow-argument-mismatch .

Another solution to the mismatch problem is to surround the scalar actual argument(s) in question with brackets. For example, replace the 4th argument n in the CALL

Code:
if ( miter <= 2 ) call dlsodi(res,addafl,jacfl,n,y,ydoti,t,tout(io),itol,rtol(j),atol(j),1,    &
                              & istate,0,rwork,lrw,iwork,liw,mf)

by [n], as in
Code:
if ( miter <= 2 ) call dlsodi(res,addafl,jacfl,[n],y,ydoti,t,tout(io),itol,rtol(j),atol(j),1,    &
                              & istate,0,rwork,lrw,iwork,liw,mf)
Back to top
View user's profile Send private message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Sat Oct 29, 2022 2:04 am    Post subject: Reply with quote

Thanks for the hint, mecej4
Back to top
View user's profile Send private message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Mon Oct 31, 2022 3:46 am    Post subject: Reply with quote

Mecej4, alas, unfortunately that does not work, same problem of clrwin$.mod was created with different version of GNU Fortran compiler.

Try to create gFortran Clearwin app with this simplest example, may be i'm doing something wrong
Code:
use clrwin$
i=winio$('Hello all')
End


It was compiled this way

gfortran aaa.f90 -fallow-argument-mismatch -o g.exe
Back to top
View user's profile Send private message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Mon Oct 31, 2022 8:43 pm    Post subject: Reply with quote

All my 30+ years with this compiler I have an impression that no matter what its new feature I will try I am the first and the only user of it so far. All the features are always look like they were left unfinished but no one discusses them or requests to continue. Also I never seen in the forums a single attempt of company to attract any slightest attention to what they have done or what's new they are currently working on. Isn't this another devilry or Matrix I don't know but the fact is really unbelievable.

Now trying Clearwin for outside compilers which seems was done a half dozen years ago. I so far haven't successfully compiled a single simplest Clearwin program with gfortran compilers. How to resolve version conflict ones and for all times with compilation of libraries in foreign compilers?
Back to top
View user's profile Send private message
JohnCampbell



Joined: 16 Feb 2006
Posts: 2554
Location: Sydney

PostPosted: Tue Nov 01, 2022 3:41 am    Post subject: Re: Reply with quote

DanRRight wrote:
gfortran aaa.f90 -fallow-argument-mismatch -o g.exe
I think this usage does not include the relevant "clearwin.dll" when building g.exe
Back to top
View user's profile Send private message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Tue Nov 01, 2022 4:44 am    Post subject: Reply with quote

I tried

gfortran aaa.f90 clrwin$.mod -fallow-argument-mismatch -o g.exe

gfortran aaa.f90 clearwin64f.dll -fallow-argument-mismatch -o g.exe

All give the same error:

"Can not read module clrwin$.mod because it was created by a different version of GNU Fortran". Downgrading to version 8 from my current 13 looks not that attractive
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Tue Nov 01, 2022 7:41 am    Post subject: Reply with quote

Please await an upcoming Youtube video that I am aiming to provide this week.
Back to top
View user's profile Send private message AIM Address
mecej4



Joined: 31 Oct 2006
Posts: 1885

PostPosted: Tue Nov 01, 2022 2:18 pm    Post subject: Reply with quote

Dan, here is how I built your postage-stamp-size example on Windows 11.

1. In a working directory, place a copy of clrwin.f95 (original in the FTN95 source64 directory).

2. With your example source code, dang.f90, also in the same directory, and using the Cygwin Gfortran 11.3 that I have, I built the application with the commands

Code:
gfortran -fdollar-ok -c clrwin.f95
gfortran -fno-underscoring -fdollar-ok dang.f90 c:\LANG\FTN95\redist\clearwin64.dll -o dang


The first compilation produces a fresh clrwin$.mod for use by the second command line. Please use the correct path to clearwin64.dll in the second command line. The resulting application dang.exe can then be run to show the small output window from your program.

When you try the same procedure with your larger application, you may need in addition the Gfortran option -fallow-argument-mismatch.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Tue Nov 01, 2022 4:39 pm    Post subject: Reply with quote

Here is a link to a video that describes how to create applications from Plato using any of the compilers FTN95, gFortran and Intel iFort.

https://www.youtube.com/watch?v=50BY9gyNY2o
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+ All times are GMT + 1 Hour
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group