Please login or register.

Login with username, password and session length
gfx gfx
1617 Posts in 535 Topics by 779 Members - Latest Member: December 03, 2022, 12:56:41 AM
gfx* Home | Help | Search | Login | Register | gfx
Absoft User Forum  |  Support  |  Linux  |  Static Compilation - Missing function

Author Topic: Static Compilation - Missing function  (Read 5466 times)


  • Newbie
  • *
  • Posts: 1
Static Compilation - Missing function
« on: September 27, 2010, 06:25:11 PM »
I am trying to do a static compilation of code for distribution across other machines.  The code compiles and runs without the static option, but when the static option is invoked the following error message is returned:

/opt/absoft10.0/lib/libmv.a(vacos.o): In function `__vacos':
vacos.c:(.text+0x112): undefined reference to `sqrt'
collect2: ld returned 1 exit status
link failed.

The flags I am using are -N26 -N109 -O3 -static and I have tried linking in the following libraries: libm.a, libmv.a, libaf77math.a, libU77.a, libV77.a. All but the first are libraries from the Absoft distribution while libm.a is the usual math library.

Any thoughts on where the sqrt function may have disappeared to? I should note that the fortran DSQRT function is called frequently elsewhere in the code and this function does appear to be found.  I also tried using the -f option to see if -N109 was the problem with the identical result.


  • Administrator
  • Sr. Member
  • *****
  • Posts: 333
Re: Static Compilation - Missing function
« Reply #1 on: September 28, 2010, 06:18:07 AM »
Can you provide a short example and the compile/link command you are using?

Absoft User Forum  |  Support  |  Linux  |  Static Compilation - Missing function

gfx gfx
Powered by MySQL Powered by PHP Valid XHTML 1.0! Valid CSS!