Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
公告
FPGA community forums and blogs have moved to the Altera Community. Existing Intel Community members can sign in with their current credentials.

[FGSL] [Brent's method]

ignacio82
初學者
1,094 檢視
I'm trying to use FGSL to maximize a function.
When compiling I get the following error:
ifort -L/share/apps/contrib/fgsl/intel12/lib64 -o dissertation.X agents.o dissertation.o -lfgsl_ifort -lgsl -lgslcblas
agents.o: In function `agents_mp_c_child_':
agents.f90:(.text+0x2f8b): undefined reference to `m_'
make: *** [dissertation.X] Error 1
ifort -L/share/apps/contrib/fgsl/intel12/lib64 -o dissertation.X agents.o dissertation.o -lfgsl_ifort -lgsl -lgslcblasagents.o: In function `agents_mp_c_child_':agents.f90:(.text+0x2f8b): undefined reference to `m_'make: *** [dissertation.X] Error 1
Thanks for the help!
0 積分
6 回應
mecej4
榮譽貢獻者 III
1,094 檢視
Please contact GSL support. The source code that you provided has many bugs in it and cannot be compiled; nor would one want to divine the intent of the programmer by reading the code.

Packing parameters of the same type into an array is the standard method of passing parameters to a solver that calls user-defined functions. However, one can only pass such parameters if the solver interface is designed to accept them. If it is not, you will have to add this capability using the source code of the solver, or (error-prone and not recommended) pass the parameters through a COMMON block or a shared module.

Usually, two or more arrays are used: for integer parameters, for real/double parameters, and others. You can use the debugger/WRITE statements to check whether the user-defined function is receiving the proper parameters.
Steven_L_Intel1
1,094 檢視
Is there such a thing as GSL support? I thought the whole idea of a GNU library is you're on your own...
mecej4
榮譽貢獻者 III
1,094 檢視
In one sense, there is no support line similar to those for commercial software, but they have Bugzillas and Usenet newsgroups for GNU software !
ignacio82
初學者
1,094 檢視
I made progress fixing a lot of the bugs but now I'm getting this when trying to compile
ifort -L/share/apps/contrib/fgsl/intel12/lib64 -o dissertation.X agents.o dissertation.o -lfgsl_ifort -lgsl -lgslcblas
agents.o: In function `agents_mp_c_child_':
agents.f90:(.text+0x2f8b): undefined reference to `m_'
make: *** [dissertation.X] Error 1
ifort -L/share/apps/contrib/fgsl/intel12/lib64 -o dissertation.X agents.o dissertation.o -lfgsl_ifort -lgsl -lgslcblasagents.o: In function `agents_mp_c_child_':agents.f90:(.text+0x2f8b): undefined reference to `m_'make: *** [dissertation.X] Error 1
Could someone explain me whatthat erroris?
Thanks!
PS: I could't find bugzilla nor usenet for FGSL. If you have a link i would appreciate it.
mecej4
榮譽貢獻者 III
1,094 檢視
It is likely that you have used the variable m with a subscript in one or more places in agents.f90 but there is no corresponding declaration of m as an array.

An "undefined external" linker error naming a symbol that you know to be a variable (rather than a function name) is a telltale sign of a missing array declaration.
ignacio82
初學者
1,094 檢視
I found all the bugs.
Thanks!
回覆