yurtesen

Compiling programs which utilize ACML 5.x

Discussion created by yurtesen on May 21, 2012
Latest reply on Sep 7, 2012 by santosh.zanjurne

I have tried to follow the example at:

http://developer.amd.com/tools/open64/AppsAndLibraries/Documents/building_with_acml.html

but it just wouldnt work. I have to add -lfortran and -lffio . So my question is, why do I have to add -lfortran and -lffio to the command line? (and why not with gcc etc. but only with opencc?

 

-bash-4.1$ opencc -O3 matrixmult_double.c matrixutil.o -o matrixmult_double -I$ACML_INCLUDE -lacml 
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_TRANSFER'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_index90'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_F90_STOP'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_FRF'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `s_cmp'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `s_copy'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `s_cat'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `__powri'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_FWF'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `_DEALLOC'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `__powii'
/export/modules/devel/ACML/5.1.0/amd/open64_64/lib/libacml.so: undefined reference to `__powdi'
collect2: ld returned 1 exit status
-bash-4.1$ opencc -O3 matrixmult_double.c matrixutil.o -o matrixmult_double -I$ACML_INCLUDE -lacml -lfortran -lffio
-bash-4.1$ 

 

Thanks,

Evren

Outcomes