Hello-
I am a newbie to Fortran, however familar with other languages, and have been quickly trying to learn how to run a makefile that had originally been created for linux (not my own). I would like to run this makefile on my Dell with Microsoft Windows XP x64 edition's with an Intel Visual Fortran Compiler 64, Version 10.1.021.
After changing a few parts (.o's to .obj's and -'s to /'s... ect.) I have been attepting to run the makefile with no luck.
The command I use to run it is
nmake /f Makefile.mak.
However I get the error:
"
/exe:lindemer
The filename, directory name, or volume label syntax is incorrect.
NMAKE : fatal error U1077: '' : return code '0x1'
Stop
"
I recently exchanged the -o with /exe: as you can see in my makefile.
I have been banging my head against the monitor for a while now trying to find where i am going wrong, and would greatly appreciate some guidence.
Thank you very much!
I am a newbie to Fortran, however familar with other languages, and have been quickly trying to learn how to run a makefile that had originally been created for linux (not my own). I would like to run this makefile on my Dell with Microsoft Windows XP x64 edition's with an Intel Visual Fortran Compiler 64, Version 10.1.021.
After changing a few parts (.o's to .obj's and -'s to /'s... ect.) I have been attepting to run the makefile with no luck.
The command I use to run it is
nmake /f Makefile.mak.
However I get the error:
"
/exe:lindemer
The filename, directory name, or volume label syntax is incorrect.
NMAKE : fatal error U1077: '' : return code '0x1'
Stop
"
I recently exchanged the -o with /exe:
I have been banging my head against the monitor for a while now trying to find where i am going wrong, and would greatly appreciate some guidence.
Thank you very much!
链接已复制
5 回复数
gnu make is an easier switch, more compatible with linux usage. Add rules to deal with .obj and .exe and ifort option requirements:
FFLAGS = /assume:protect_parens,minus0,byterecl,buffered_io /Qprec-div /Qprec-sqrt
.SUFFIXES: .obj .exe
your.exe: 1.obj 2.obj
ifort $FFLAGS 1.obj 2.obj
mv 1.exe your.exe
.f.obj:
ifort $(FFLAGS) -c $*.f
or (choose one method)
your.exe: 1.o 2.o
ifort $(FFLAGS) /Fe$@.exe 1.o 2.o
.f.o:
ifort $(FFLAGS) -c $*.f
mv $*.obj $*.o
observing the gnu make rules where ctrl-T tabs are required, and likely no ctrl-R even at line ends.
If the Makefile relies on the linux convention where .F90 or .F implies pre-processing, it becomes more complicated, regardless of make utility, unless you can simply add /Qfpp to FFLAGS.
FFLAGS = /assume:protect_parens,minus0,byterecl,buffered_io /Qprec-div /Qprec-sqrt
.SUFFIXES: .obj .exe
your.exe: 1.obj 2.obj
ifort $FFLAGS 1.obj 2.obj
mv 1.exe your.exe
.f.obj:
ifort $(FFLAGS) -c $*.f
or (choose one method)
your.exe: 1.o 2.o
ifort $(FFLAGS) /Fe$@.exe 1.o 2.o
.f.o:
ifort $(FFLAGS) -c $*.f
mv $*.obj $*.o
observing the gnu make rules where ctrl-T tabs are required, and likely no ctrl-R even at line ends.
If the Makefile relies on the linux convention where .F90 or .F implies pre-processing, it becomes more complicated, regardless of make utility, unless you can simply add /Qfpp to FFLAGS.
Your makefile is not valid for nmake, as far as I can tell. For example, I think that:
%.obj %.mod: %.f90
$(F90) /c $(F90FLAGS) $<
should be:
.f90 .obj:
$(F90) /c $(F90FLAGS) $<
.f90 .mod:
$(F90) /c $(F90FLAGS) $<
