- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have compiled fortran 77 code for geophysical processing(written by other person).When I tried to change parameters file to allow for larger chunks and larger matrices to be inverted I got this
rm -f *.o
rm -f birrp
ifort -fast -Wl -o birrp birrp.f coherence.f dataft.f diagnostic.f fft.f filter.f math.f rarfilt.f response.f rtpss.f utils.f weight.f zlinpack.f
ifort: command line warning #10157: ignoring option '-W'; argument is of wrong type
filter.f(1): warning #6178: The return value of this FUNCTION has not been defined. [FILTER]
complex function filter(f,fpar,npar)
-----------------------^
utils.f(890): warning #7532: The number of arguments is incompatible with intrinsic procedure, assume 'external'. [DATE]
call date( 0, time1, year1, month1, day1, hour1, min1, sec1 )
-----------^
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu//libc.a(libc_fatal.o): In function `__libc_message.constprop.0':
(.text+0x13b): relocation truncated to fit: R_X86_64_PC32 against symbol `__abort_msg' defined in .bss section in /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu//libc.a(abort.o)
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu//libc.a(libc_fatal.o): In function `__libc_message':
(.text+0x421): relocation truncated to fit: R_X86_64_PC32 against symbol `__abort_msg' defined in .bss section in /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu//libc.a(abort.o)
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu//libc.a(gconv_db.o): In function `__gconv_get_modules_db':
I am on Ubuntu 14.04.How should I set the compilation options?My makefile
FC90 = ifort
FCFLAGS= -fast -WlTARGETS= clean birrp
OBJSOC= birrp.f coherence.f dataft.f diagnostic.f fft.f filter.f math.f rarfilt.f response.f rtpss.f utils.f weight.f zlinpack.f
all: $(TARGETS)clean:
rm -f *.o
rm -f birrpbirrp:$(OBJSOC)
$(FC90) $(FCFLAGS) -o $@ $(OBJSOC) $(LIBS)# General compile rules
.SUFFIXES: .f .o
.f90.o:
$(FC90) $(FCFLAGS) -c -o $@ $<
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The -Wl option prefix is used by some compilers to signify that what follows is an option that you want the compiler to pass to the linker (ld in Unix/Linux) as-is. You probably do not need it at all here. The warning about DATE is also something that you can ignore (you have an external subroutine with the same as an Intel-supplied intrinsic subroutine).
However, the warning about the function FILTER not returning a value is probably serious. You need to fix it and, since I do not know anything about your application or BIRRP, I have to see the lines of code where that function is used in an expression before giving any suggestions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
>> relocation truncated to fit: R_X86_64_PC32
You may have issues with static data > 2GB
You may need to change your very large arrays to ALLOCATABLE if -mcmodel=medium does not resolve the issue.
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jim
Yes,I have large arrays.Should I add -mcmodel=medium to my FCFLAGS?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Well i have managed to compile but I have this problem
milenko@milenko-X58-USB3:~/birrp$ ./birrp < in131072.mt1
./birrp: error while loading shared libraries: libifport.so.5: cannot open shared object file: No such file or directory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are you attempting to run BIRRP from an Ifort session? If not, make sure that LD_LIBRARY_PATH contains the directories of all the shared libraries that are required by your application.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes,I am running BIRRP from an ifort session. I have edited makefile like this
FCFLAGS=-mcmodel=medium
Is this wright?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The environment variable LD_LIBRARY_PATH must include the paths to all the shared libraries.
On Linux, you command shell should set this via
export LD_LIBRARY_PATH= (list of paths to search using ; separator)
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you have LD_FLAGS, you may need to add it there as well.
--Lorri
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page