WIMSD5 compilation

Everything else here, including comments about the website and this forum
Post Reply
subterfug3x
Posts: 31
Joined: Thu Oct 04, 2018 7:53 am
Security question 1: No
Security question 2: 96
Location: Tomsk, Russia

WIMSD5 compilation

Post by subterfug3x » Mon Feb 04, 2019 3:55 pm

Hello,
I can't compile WIMSD5 code from NEA http://www.oecd-nea.org/tools/abstract/detail/nea-1507/. I tried to compile the code using g95 compiler in Windows and using f95 compiler in Ubuntu, but all my attempts were unsuccessful.

My loadsrcnea.bat file with g95 compiler.

Code: Select all

    @echo off
REM  ----------------------------------
REM  PROGRAM-NAME: WIMSD-5B(2003)              
REM  PACKAGE-ID:   NEA 1507/04         
REM  ----------------------------------
REM
REM  PROGRAM SOURCE AND EXECUTABLE INSTALLATION TO HARD DISK
REM
REM  A.Trkov, Institute Jozef Stefan, Ljubljana, Slovenia (1998)
REM
REM          Adapted to this distribution package 
REM           by J.M.Galan NEA-Data Bank (02/2004)
REM
REM
REM  The installation procedure assumes that the UPD Update
REM  emulator and the Lahey/Fujitsu Fortran 95 Compiler Release 5.50h
REM  are installed and set.
REM
REM ==================================================================
REM
REM  The distribution files location and the UPD emulator location
REM  are assumed to be as indicated in the distribution package
REM  (DETAILED FILE DESCRIPTION).
REM
REM
REM ==================================================================
REM  Shortcuts to subsequent steps may be entered as a parameter
REM  to the batch procedure as follows:
REM     sort  - copy files to decks (step 4)
REM     merge - merge decks to make the source (step 5)
REM     mkftn - make Fortran source (step 6)
REM     mkexe - make executable (step 7)
REM     test  - run all test cases (step 9)
REM
  if not %1.==. goto %1
REM
REM ==================================================================
REM
REM 1. The following files are assumed to exist on the current
REM    directory:
REM      Wimsd5b.upd  - a complete set of update directives for
REM                     the WIMSD-5B source, extensions and
REM                     machine-dependent features, if required.
REM      Makefile.dos - the Lahey compile Makefile utility 
REM                     instructions file.
REM      wd5.bat      - DOS batch procedure to run Wimsd5b for
REM                     the input file, specified by the first
REM                     parameter
REM
REM ==================================================================
REM
REM 2. A subdirectory "source" of the current directory is created.
REM    It is used as a working directory for all subsequent operations.
  mkdir work
  cd    work
REM
REM ==================================================================
REM
REM 3. The files from the Winfrith WIMSD-5B original Unix distribution
REM    are copied to the disk.
REM
  copy ..\..\source\externals\main_fixed.f a.150
  copy ..\..\source\prelude\timer.f a.165
  copy ..\..\source\prelude\today.f a.167
  copy ..\..\source\wimsdlib\clock.f a.185
  copy ..\..\source\wimsdlib\daytim.f a.187
  copy ..\..\source\readdata\error.f a.170         
  copy ..\..\source\readdata\getbuf.f a.171          
  copy ..\..\source\readdata\inchan.f a.172          
  copy ..\..\source\readdata\lnflow.f a.173          
  copy ..\..\source\readdata\offkey.f a.174            
  copy ..\..\source\readdata\rdchan.f a.175            
  copy ..\..\source\readdata\readin.f a.176            
  copy ..\..\source\readdata\readjn.f a.177           
  copy ..\..\source\readdata\readln.f a.178            
  copy ..\..\source\readdata\readno.f a.179            
  copy ..\..\source\readdata\reread.f a.180            
  copy ..\..\source\readdata\skipsp.f a.181            
  copy ..\..\source\readdata\type.f a.182              
  copy ..\..\source\readdata\wrchan.f a.183            
  copy ..\..\source\prelude\chain.f a.160
  copy ..\..\source\prelude\nuprel.f a.162
  copy ..\..\source\prelude\prelud.f a.163
  copy ..\..\source\prelude\prolog.f a.164
  copy ..\..\source\prelude\tlpage.f a.166
  copy ..\..\source\prelude\wimsd4.f a.168
  copy ..\..\source\prelude\wimsdm.f a.169
  copy ..\..\source\wimsdlib\bat.f a.184
  copy ..\..\source\wimsdlib\comp.f a.186
  copy ..\..\source\wimsdlib\kg.f a.188
  copy ..\..\source\wimsdlib\matinv.f a.189
  copy ..\..\source\wimsdlib\pc.f a.190
  copy ..\..\source\wimsdlib\sffort.f a.191
  copy ..\..\source\wimsdlib\tapwra.f a.192
  copy ..\..\source\wimsdlib\tpage.f a.193
  copy ..\..\source\wimsdlib\w.f a.194
  copy ..\..\source\wimsdlib\werror.f a.195
  copy ..\..\source\chain01\atq.f a.020
  copy ..\..\source\chain01\burnds.f a.021
  copy ..\..\source\chain01\circle.f a.022
  copy ..\..\source\chain01\craig.f a.023
  copy ..\..\source\chain01\datag.f a.024
  copy ..\..\source\chain01\dsaki3.f a.025
  copy ..\..\source\chain01\ichn01.f a.026
  copy ..\..\source\chain01\libin.f a.027
  copy ..\..\source\chain01\mprei3.f a.028
  copy ..\..\source\chain01\one.f a.029
  copy ..\..\source\chain01\plot.f a.030
  copy ..\..\source\chain01\realin.f a.031
  copy ..\..\source\chain01\restar.f a.032
  copy ..\..\source\chain01\sqifc.f a.033
  copy ..\..\source\chain01\vcalc.f a.034
  copy ..\..\source\chain02\add.f a.035
  copy ..\..\source\chain02\adder.f a.036
  copy ..\..\source\chain02\dip.f a.037
  copy ..\..\source\chain02\ichn02.f a.038
  copy ..\..\source\chain02\two.f a.039
  copy ..\..\source\chain03\dasqhe.f a.040
  copy ..\..\source\chain03\e3.f a.041
  copy ..\..\source\chain03\ichn03.f a.042
  copy ..\..\source\chain03\leffe.f a.043
  copy ..\..\source\chain03\resalt.f a.044
  copy ..\..\source\chain03\resint.f a.045
  copy ..\..\source\chain03\respol.f a.046
  copy ..\..\source\chain03\rtifc.f a.047
  copy ..\..\source\chain03\three.f a.048
  copy ..\..\source\chain04\datin.f a.049
  copy ..\..\source\chain04\difenr.f a.050
  copy ..\..\source\chain04\four.f a.051
  copy ..\..\source\chain04\hfs.f a.052
  copy ..\..\source\chain04\ichn04.f a.053
  copy ..\..\source\chain04\pip1.f a.054
  copy ..\..\source\chain04\qcal.f a.055
  copy ..\..\source\chain04\ripple.f a.056
  copy ..\..\source\chain04\solve.f a.057
  copy ..\..\source\chain04\thes3.f a.058
  copy ..\..\source\chain05\five.f a.059
  copy ..\..\source\chain05\gave.f a.060
  copy ..\..\source\chain05\ichn05.f a.061
  copy ..\..\source\chain05\rare.f a.062
  copy ..\..\source\chain05\save.f a.063
  copy ..\..\source\chain05\xsec.f a.064
  copy ..\..\source\chain06\beta.f a.065
  copy ..\..\source\chain06\datpr.f a.066
  copy ..\..\source\chain06\disc.f a.067
  copy ..\..\source\chain06\dsn.f a.068
  copy ..\..\source\chain06\dsna.f a.069
  copy ..\..\source\chain06\fprint.f a.070
  copy ..\..\source\chain06\gdsn.f a.071
  copy ..\..\source\chain06\gprint.f a.072
  copy ..\..\source\chain06\hps.f a.073
  copy ..\..\source\chain06\hpsa.f a.074
  copy ..\..\source\chain06\ichn06.f a.075
  copy ..\..\source\chain06\invert.f a.076
  copy ..\..\source\chain06\mprint.f a.077
  copy ..\..\source\chain06\multxy.f a.078
  copy ..\..\source\chain06\sixhps.f a.079
  copy ..\..\source\chain07\edit.f a.080
  copy ..\..\source\chain07\ichn07.f a.081
  copy ..\..\source\chain07\pdatin.f a.082
  copy ..\..\source\chain07\pers.f a.083
  copy ..\..\source\chain07\pincap.f a.084
  copy ..\..\source\chain07\pip12.f a.085
  copy ..\..\source\chain07\pqcal.f a.086
  copy ..\..\source\chain07\pscat.f a.087
  copy ..\..\source\chain07\psolve.f a.088
  copy ..\..\source\chain07\pthes3.f a.089
  copy ..\..\source\chain07\purple.f a.090
  copy ..\..\source\chain08\eight.f a.091
  copy ..\..\source\chain08\ichn08.f a.092
  copy ..\..\source\chain08\pij.f a.093
  copy ..\..\source\chain08\r1.f a.094
  copy ..\..\source\chain08\r3.f a.095
  copy ..\..\source\chain08\track.f a.096
  copy ..\..\source\chain08\v5.f a.097
  copy ..\..\source\chain09\ichn09.f a.098
  copy ..\..\source\chain09\prizej.f a.099
  copy ..\..\source\chain11\athes3.f a.100
  copy ..\..\source\chain11\expert.f a.101
  copy ..\..\source\chain11\ichn11.f a.102
  copy ..\..\source\chain11\pcz.f a.103
  copy ..\..\source\chain11\tore.f a.104
  copy ..\..\source\chain11\unsmer.f a.105
  copy ..\..\source\chain12\bthes.f a.106
  copy ..\..\source\chain12\chn12.f a.107
  copy ..\..\source\chain12\fc08b.f a.108
  copy ..\..\source\chain12\ichn12.f a.109
  copy ..\..\source\chain12\ingres.f a.110
  copy ..\..\source\chain12\minip.f a.111
  copy ..\..\source\chain12\minipd.f a.112
  copy ..\..\source\chain12\ppeak.f a.113
  copy ..\..\source\chain12\wimsb1.f a.114
  copy ..\..\source\chain12\wimsb2.f a.115
  copy ..\..\source\chain12\wimsb3.f a.116
  copy ..\..\source\chain12\wimsb4.f a.117
  copy ..\..\source\chain12\wimsbx.f a.118
  copy ..\..\source\chain12\zajago.f a.119
  copy ..\..\source\chain13\bamult.f a.120
  copy ..\..\source\chain13\chn13.f a.121
  copy ..\..\source\chain13\datar.f a.122
  copy ..\..\source\chain13\epri.f a.123
  copy ..\..\source\chain13\farfir.f a.124
  copy ..\..\source\chain13\geomet.f a.125
  copy ..\..\source\chain13\ichn13.f a.126
  copy ..\..\source\chain13\punch.f a.127
  copy ..\..\source\chain13\sprint.f a.128
  copy ..\..\source\chain14\chn14.f a.129
  copy ..\..\source\chain14\colaps.f a.130
  copy ..\..\source\chain14\endcap.f a.131
  copy ..\..\source\chain14\ichn14.f a.132
  copy ..\..\source\chain14\leakag.f a.133
  copy ..\..\source\chain14\p1prep.f a.134
  copy ..\..\source\chain14\rhs.f a.135
  copy ..\..\source\chain15\chn15.f a.136
  copy ..\..\source\chain15\datorg.f a.137
  copy ..\..\source\chain15\expand.f a.138
  copy ..\..\source\chain15\ichn15.f a.139
  copy ..\..\source\chain15\react.f a.140
  copy ..\..\source\chain15\rprint.f a.141
  copy ..\..\source\chain15\rrprep.f a.142
  copy ..\..\source\chain16\chn16.f a.143
  copy ..\..\source\chain16\consig.f a.144
  copy ..\..\source\chain16\forfiv.f a.145
  copy ..\..\source\chain16\ichn16.f a.146
  copy ..\..\source\chain16\intsig.f a.147
  copy ..\..\source\chain16\redsig.f a.148
  copy ..\..\source\chain16\ritsig.f a.149
REM
:sort
REM
REM ==================================================================
REM
REM 4. The relevant files that constitute logical modules are
REM    sorted together to make "deck" files with extension "*.dck".
REM    Each of these files is preceeded by a record of the form
REM      "*deck 'name'"
REM    where 'name' is the assigned logical deckname. For compatibility
REM    with the UPD Update emulator program the decknames are limited
REM    to six characters.
REM
  copy a.150 wimsd5.dck
  copy a.165+a.167+a.185+a.187 timing.dck
  copy a.170+a.171+a.172+a.173+a.174+a.175+a.176+a.177+a.178+a.179+a.180+a.181+a.182+a.183 readda.dck
  copy a.160+a.162+a.163+a.164      +a.166      +a.169+a.168 prelud.dck
  copy a.184      +a.186      +a.188+a.189+a.190+a.191+a.192+a.193+a.194+a.195 wimsdl.dck
  copy a.020+a.021+a.022+a.023+a.024+a.025+a.026+a.027+a.028+a.029+a.030+a.031+a.032+a.033+a.034 chain1.dck
  copy a.035+a.036+a.037+a.038+a.039 chain2.dck
  copy a.040+a.041+a.042+a.043+a.044+a.045+a.046+a.047+a.048 chain3.dck
  copy a.049+a.050+a.051+a.052+a.053+a.054+a.055+a.056+a.057+a.058 chain4.dck
  copy a.059+a.060+a.061+a.062+a.063+a.064 chain5.dck
  copy a.065+a.066+a.067+a.068+a.069+a.070+a.071+a.072+a.073+a.074+a.075+a.076+a.077+a.078+a.079 chain6.dck
  copy a.080+a.081+a.082+a.083+a.084+a.085+a.086+a.087+a.088+a.089+a.090 chain7.dck
  copy a.091+a.092+a.093+a.094+a.095+a.096+a.097 chain8.dck
  copy a.098+a.099 chain9.dck
  copy a.100+a.101+a.102+a.103+a.104+a.105 chai11.dck
  copy a.106+a.107+a.108+a.109+a.110+a.111+a.112+a.113+a.114+a.115+a.116+a.117+a.118+a.119 chai12.dck
  copy a.120+a.121+a.122+a.123+a.124+a.125+a.126+a.127+a.128 chai13.dck
  copy a.129+a.130+a.131+a.132+a.133+a.134+a.135 chai14.dck
  copy a.136+a.137+a.138+a.139+a.140+a.141+a.142 chai15.dck
  copy a.143+a.144+a.145+a.146+a.147+a.148+a.149 chai16.dck
REM
  echo Original decks sorted
REM
:merge
REM
REM ==================================================================
REM
REM 5. The deck files are merged to the file "Wimsd5b.src", which
REM    represents the original source in the process of preparing
REM    the machine-independent master WIMSD5B source file.
REM
  echo *deck wimsd5     >Wimsd5b.src
  type wimsd5.dck      >>Wimsd5b.src
  echo *deck timing    >>Wimsd5b.src
  type timing.dck      >>Wimsd5b.src
  echo *deck readda    >>Wimsd5b.src
  type readda.dck      >>Wimsd5b.src
  echo *deck prelud    >>Wimsd5b.src
  type prelud.dck      >>Wimsd5b.src
  echo *deck wimsdl    >>Wimsd5b.src
  type wimsdl.dck      >>Wimsd5b.src
  echo *deck chain1    >>Wimsd5b.src
  type chain1.dck      >>Wimsd5b.src
  echo *deck chain2    >>Wimsd5b.src
  type chain2.dck      >>Wimsd5b.src
  echo *deck chain3    >>Wimsd5b.src
  type chain3.dck      >>Wimsd5b.src
  echo *deck chain4    >>Wimsd5b.src
  type chain4.dck      >>Wimsd5b.src
  echo *deck chain5    >>Wimsd5b.src
  type chain5.dck      >>Wimsd5b.src
  echo *deck chain6    >>Wimsd5b.src
  type chain6.dck      >>Wimsd5b.src
  echo *deck chain7    >>Wimsd5b.src
  type chain7.dck      >>Wimsd5b.src
  echo *deck chain8    >>Wimsd5b.src
  type chain8.dck      >>Wimsd5b.src
  echo *deck chain9    >>Wimsd5b.src
  type chain9.dck      >>Wimsd5b.src
  echo *deck chai11    >>Wimsd5b.src
  type chai11.dck      >>Wimsd5b.src
  echo *deck chai12    >>Wimsd5b.src
  type chai12.dck      >>Wimsd5b.src
  echo *deck chai13    >>Wimsd5b.src
  type chai13.dck      >>Wimsd5b.src
  echo *deck chai14    >>Wimsd5b.src
  type chai14.dck      >>Wimsd5b.src
  echo *deck chai15    >>Wimsd5b.src
  type chai15.dck      >>Wimsd5b.src
  echo *deck chai16    >>Wimsd5b.src
  type chai16.dck      >>Wimsd5b.src
REM
  echo WIMSD5B master source file on "Wimsd5b.src"
REM
:mkftn
REM
REM ==================================================================
REM
REM 6. The source is copied to the "src" file and the update
REM    directives are copied to the "upn" file. The "upd" update
REM    emulator is executed to generate the Fortran source.
REM
  copy    Wimsd5b.src src.
  copy ..\Wimsd5b.upd upn.
  copy ..\upd.for upd.for
REM
 g95 upd.for -Wall -ftrace=full
REM
  upd
REM
:mkexe
REM
REM ==================================================================
REM
REM 7. Compile and link the code source to make the Wimsd5b executable.
REM
  mkdir prog
  copy chain1.for prog\chain1.for
  copy chain2.for prog\chain2.for
  copy chain3.for prog\chain3.for
  copy chain4.for prog\chain4.for
  copy chain5.for prog\chain5.for
  copy chain6.for prog\chain6.for
  copy chain7.for prog\chain7.for
  copy chain8.for prog\chain8.for
  copy chain9.for prog\chain9.for
  copy chai11.for prog\chai11.for
  copy chai12.for prog\chai12.for
  copy chai13.for prog\chai13.for
  copy chai14.for prog\chai14.for
  copy chai15.for prog\chai15.for
  copy chai16.for prog\chai16.for
  copy wimsd5.for prog\wimsd5.for
  copy timing.for prog\timing.for
  copy readda.for prog\readda.for
  copy prelud.for prog\prelud.for
  copy wimsdl.for prog\wimsdl.for
REM
  cd /prog
  g95 -o wimsd5b.exe *.for -Wall -ftrace=full
  copy wimsd5b.exe ..\wimsd5b.exe
  del/Q *.*
  cd ..
  rmdir/Q prog
REM
REM ==================================================================
REM
REM 8. Compile and link the WILLIE library maintenance code.
REM    Copy the library file.
REM
  copy ..\..\library\wdn29.asc wdn29.asc
  copy ..\..\library\willie.for willie.for
REM
  g95 -o willie.exe willie.for -Wall -ftrace=full
REM 
:test
REM
REM ==================================================================
REM
REM 9. Create a subdirectory "test", copy the input files and the
REM    batch procedures to this directory and run all the test cases. 
REM
  mkdir test
REM
  echo FOBI            >inp.
  echo wdn29.asc      >>inp.
  echo test\wimsdlib. >>inp.
  echo END            >>inp.
  willie<inp.
  del  inp.
REM
  cd test
REM TEST01
  copy    ..\..\..\verin\test01      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test01.out
REM TEST02
  copy    ..\..\..\verin\test02      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test02.out
REM TEST03
  copy    ..\..\..\verin\test03      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test03.out
REM TEST04
  copy    ..\..\..\verin\test04      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test04.out
REM TEST05
  copy    ..\..\..\verin\test05      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test05.out
REM TEST06
  copy    ..\..\..\verin\test06      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test06.out
REM TEST07
  copy    ..\..\..\verin\test07      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test07.out
REM TEST08
  copy    ..\..\..\verin\test08      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test08.out
REM TEST09
  copy    ..\..\..\verin\test09      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test09.out
REM TEST10
  copy    ..\..\..\verin\test10      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test10.out
REM TEST11
  copy    ..\..\..\verin\test11      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test11.out
REM TEST12
  copy    ..\..\..\verin\test12      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test12.out
REM TEST13
  copy    ..\..\..\verin\test13      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test13.out
REM TEST14
  copy    ..\..\..\verin\test14      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test14.out
REM TEST15
  copy    ..\..\..\verin\test15      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test15.out
REM TEST16
  copy    ..\..\..\verin\test16      wimsdinp
  ..\wimsd5b
  copy    wimsdout      test16.out
REM
  del wimsdinp
  del wimsdout
  del for*
  cd  ..
REM
REM ==================================================================
REM
REM 10. Delete the unnecessary files
REM
  del  a.???
  del *.dck
  del src.
  del upn.
  del *.map
  del *.obj
REM
REM ==================================================================
REM
  echo.
  echo ==============================
  echo Wimsd-5b installation complete
  echo ==============================
  echo.
:end
pause

Few errors during compilation.

Code: Select all

Warning (115): Line 1651 of upd.for is being truncated
In file upd.for:1580

            num1=lcde(jdx1)-lcds(jdx1)
            1
Warning (112): Variable 'num1' at (1) is set but never use

Code: Select all

 upd: vers: 2.0
At line 199 of file upd.for file: "src"
Traceback: not available, compile with -ftrace=frame or -ftrace=full
Fortran runtime error: ═х єфрхЄё  эрщЄш єърчрээ√щ Їрщы.
Any advices?

Thanks
- Igor

User avatar
Jaakko Leppänen
Site Admin
Posts: 2179
Joined: Thu Mar 18, 2010 10:43 pm
Security question 2: 0
Location: Espoo, Finland
Contact:

Re: WIMSD5 compilation

Post by Jaakko Leppänen » Tue Feb 05, 2019 6:15 pm

Please note that this is not the correct forum to discuss the compilation of WIMS.
- Jaakko

subterfug3x
Posts: 31
Joined: Thu Oct 04, 2018 7:53 am
Security question 1: No
Security question 2: 96
Location: Tomsk, Russia

Re: WIMSD5 compilation

Post by subterfug3x » Sun Feb 10, 2019 10:48 am

Hello Dr.Jaakko, It's clear, I'm sorry for the offtop question.

I found an error in the NEA DB loadsrcnea.bat file... And I compiled the code using Lahey/Fujitsu Fortran trial version in Windows 10 x64

line 359, use cd prog instead of cd /prog
- Igor

Post Reply