A new memo has been put together to help with installation of NONMEM
with Powerstation Fortran. Parts of it (nmlink.for and nmfe.bat) may
be of interest to existing licensees. I also want to remind all
recipients of this memo that the nmusers@c255.ucsf.edu exists mainly
for you, not for the NONMEM Project Group. Bill Bachman asks:
Obviously, you and others (including myself) have lots of tips &
suggestions for running NONMEM, not only under DOS & windows but
UNIX & other OS's. Why is no one sharing any of this wealth of
knowledge? The mechanisms exist for easy distribution. The only
thing I see distributed on the nmusers list is job announcements (&
a few VAX related queries for help). This is also a good use of
nmusers, but, why not a few "this is what I discovered, maybe it
will help you" items?
Alison Boeckmann alison@c255.ucsf.edu
=============================================================
INSTALLATION NOTES FOR NONMEM VERSION IV UNDER DOS OR MICROSOFT WINDOWS
USING MICROSOFT FORTRAN POWERSTATION
Bill Bachman
Division of Biopharmaceutics, FDA
January 18, 1994
Alison Boeckmann
NONMEM Project Group, UCSF
January 25, 1994
This memo does not replace Users Guide III. The installer of NONMEM
should still study Guide III and perform the tests recommended in that
guide.
All the instructions below are designed to be executed from the DOS
prompt or in a DOS window running under Microsoft Windows.
There is another memo, similar to this one, concerning Microsoft
Fortran 5.1. One major difference between the two memos is that
this memo suggests the optional use of a program "nmlink.for" to
create linker response files. (This program is fairly general and
can be adapted to other platforms.) It also suggests the optional
use of batch file "nmfe.bat" to run NM-TRAN, build the
NONMEM/PREDPP executable, and run it. Nmlink.for and nmfe.bat can
be found in Appendices 2 and 3 of this document, and must be
keyed-in by the installer.
Change the files statement in the config.sys file to "files=64".
Installing NONMEM:
1. Create a directory structure with a main directory (e.g.
c:\nmiv) and subdirectories for the NONMEM object modules
(e.g. c:\nmiv\nm), the PREDPP object modules (e.g.
c:\nmiv\pr), nmtran (e.g. c:\nmiv\nt), a utilities directory
(e.g. c:\nmiv\util) and a run directory (e.g. c:\nmiv\run).
2. Copy the "nmd" file from the NONMEM distribution disk 1 to
the c:\nmiv\nm directory. Copy the "ppd1" and "ppd2" files
from disk 1 to the c:\nmiv\pr directory. Copy the "tran" and
"trld" files to the c:\nmiv\nt directory from disk 3. Copy
all the remaining files from disk 3 (except "trls") to the
c:\nmiv\util directory.
3. Change line 11 of the "sep" file from '.f' to '.FOR'.
Insert a line before line 5, and change line 5 itself as follows:
OPEN (2,FILE=' ')
10 READ (2,800,ERR=20,END=30) IREC
Rename "sep" to "sep.for" and compile. ("fl32 sep.for") Copy
"sep.exe" to the \nm, \pr and \nt subdirectories.
[Optional: compile nmlink.for. Copy nmlink.exe and nmfe.bat
to \run.]
4. Change to the \nm subdirectory and separate the "nmd" file.
sep nmd
5. Edit "blkdat.for":
a. On line 23, change the DATA FNSTP,FNINT statement from
'/dev/null','/dev/null' to 'nul','con'.
b. Comment out the IEEE machine-dependent constants.
c. Activate the INTEL chip machine constants.
6. Edit "ofiles.for". Instead of the line:
REWIND 5
Insert:
OPEN(5,FILE='FCON')
REWIND 5
OPEN(6,FILE='OUTPUT',ACCESS='SEQUENTIAL',FORM='FORMATTED')
REWIND 6
7. Compile the NONMEM object modules:
fl32 /c /G4 /Ox /Op *.for > emsgs
[Use /G3 when compiling for an 80386.]
Examine the "emsgs" file. There should be no error messages.
Warning messages can be ignored.
Installing PREDPP:
1. Change to the \pr subdirectory and separate the "ppd1" and
"ppd2" files:
sep ppd1
sep ppd2
2. Compile the PREDPP object modules:
fl32 /c /G4 /Ox /Op *.for > emsgs
Examine the "emsgs" file. There should be no error messages.
Warning messages can be ignored.
Installing NMTRAN:
1. Change to the \nt subdirectory and separate the "tran" files:
sep tran
2. Edit "nmtran.for". After line 152 (after the DATA statements
and before MAXTMP=DIMTMP), insert:
OPEN(5,FILE='INPUT')
3. Compile and link the NMTRAN object modules to create the nmtran
executable:
fl32 /G4 /Ox /Op *.for > emsgs
Examine the "emsgs" file. There should be no error messages.
Warning messages can be ignored. Rename the executable file:
ren ablock.exe nmtran.exe
Running a NONMEM problem:
1. Copy the following files to the \run subdirectory:
"nmtran.exe" from \nt and "control3" and "data3" from \util.
2. Rename or copy "control3" to a file named "input".
3. Run nmtran.exe:
nmtran
4. Rename or copy "fsubs" to "fsubs.for".
5. Create a linker response file containing the PREDPP object
modules be linked to create the nonmem executable.
See Appendix 1 for the generic linker file created for running
ADVAN 2 and TRANS 1 that was used to run
the example problem, "adv2tr1.lnk".
6. Compile fsubs and link the object modules to create the nonmem
executable:
fl32 /G4 /Ox /Op fsubs.for @adv2tr1.lnk \nmiv\nm\*.obj
7. Run the NONMEM executable ("fsubs.exe"):
fsubs
8. Rename "output" to a unique filename so it will not be over-
written by subsequent runs.
9. Similar linker response files to adv2tr1.lnk should be created
for all ADVAN/TRANS combinations if nmlink is not used. See
Users Guide VI (PREDPP), pages 76-91.
Alternate to steps 2 - 9 (if nmlink.for and nmfe.bat are used):
nmfe control3 report3
Appendix 1 - "adv2tr1.lnk" linker response file.
\nmiv\pr\PRED.OBJ
\nmiv\pr\PREDI.OBJ
\nmiv\pr\CHECK.OBJ
\nmiv\pr\SADVAN.OBJ
\nmiv\pr\SSS0.OBJ
\nmiv\pr\ADVAN2.OBJ
\nmiv\pr\TRANS1.OBJ
\nmiv\pr\INFN.OBJ
INSTALLATION NOTES FOR NONMEM VERSION IV UNDER DOS OR MICROSOFT WINDOWS
USING MICROSOFT FORTRAN POWERSTATION
January 25, 1994
Appendix 2 - "nmlink.for"
C WRITTEN BY ALISON BOECKMANN NONMEM PROJECT GROUP
C & BILL BACHMAN FDA DIVISION OF BIOPHARMACEUTICS JAN 1994
C TO COMPILE WITH SUN FORTRAN 2.0.1, USE f77 -xl NMLINK.f
C (WITHOUT -xl, f77 SUPPRESSES BACKSLASH \ IN CONSTANTS)
PROGRAM NMLINK
CHARACTER*72 TEMP
CHARACTER*9 A(16)
CHARACTER*1 B
B=' '
OPEN (10,FILE = 'FREPORT')
OPEN (11,FILE = 'LINK.LNK')
READ (10,100,END=99) TEMP
READ (10,100,END=99) TEMP
READ (10,100) A
TEMP='\NMIV\PR\'
DO 10 I=1,16
IF (A(I).EQ.B.OR.A(I)(9:9).NE.B) GOTO 99
TEMP(10:)=A(I)(2:)
J=INDEX(TEMP,B)
TEMP(J:)='.OBJ'
WRITE (11,*) TEMP
10 CONTINUE
100 FORMAT (8A9)
99 END
Appendix 3 - "nmfe.bat"
copy %1 input
nmtran.exe
ren fsubs fsubs.for
nmlink.exe
fl32 /G4 /Ox /Op fsubs.for @link.lnk \nmiv\nm\*.obj
fsubs.exe
copy output %2
del fsubs.*
del input
del output
del prderr
del fcon
del fdata
del flib
del freport
del fstream
del link.lnk