主题:-mcmodel=medium怎么设置啊?
郁闷!!Lunix下运行程序出现问题
: relocation truncated to fit: R_X86_64_32S .bss
网上搜了下,说有个设置,设置的大点就行了。
here are error message as follows:
/tmp/cco64FBE.o(.text+0x16ed): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32S .bss
/tmp/cco64FBE.o(.text+0x171f): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32S .bss
/tmp/cco64FBE.o(.text+0x1d83): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32 .bss
/tmp/cco64FBE.o(.text+0x1ea1): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32 .bss
collect2: ld returned 1 exit status
This is due to the status data is large than 2G.
The problom can be solve by check the program and change the dimensions of array。 I check the program and find no problom in the program。
So the another way is to create more space for the program by using “-mcmodel=medium”。Then i changed the compile message :g77 -o vel -mcmodel=medium vel_add.f the problem was solved。Congratulations !!!
但是该怎么操作呢?
: relocation truncated to fit: R_X86_64_32S .bss
网上搜了下,说有个设置,设置的大点就行了。
here are error message as follows:
/tmp/cco64FBE.o(.text+0x16ed): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32S .bss
/tmp/cco64FBE.o(.text+0x171f): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32S .bss
/tmp/cco64FBE.o(.text+0x1d83): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32 .bss
/tmp/cco64FBE.o(.text+0x1ea1): In function `MAIN__':
: relocation truncated to fit: R_X86_64_32 .bss
collect2: ld returned 1 exit status
This is due to the status data is large than 2G.
The problom can be solve by check the program and change the dimensions of array。 I check the program and find no problom in the program。
So the another way is to create more space for the program by using “-mcmodel=medium”。Then i changed the compile message :g77 -o vel -mcmodel=medium vel_add.f the problem was solved。Congratulations !!!
但是该怎么操作呢?