I'm using xCode 3.0 and Mac OS X 10.5.8. I have downloaded clapack-3.2.1-CMAKE, configured and generated xCode project using cmake 2.8.0, it has configured and generated the files with no problems. I have opened the generated xCode project file, built it, and it succeeded with 5 warnings.
Following the warnings:
Compiling /Users/khaledabbas/Documents/UM/Dissertation/Software/Insight3D/Prerequisite/clapack-3.2.1-CMAKE/BLAS/SRC/xerbla.c
warning: implicit declaration of function 'printf'
warning: incompatible implicit declaration of built-in function 'printf'
warning: format '%2i' expects type 'int', but argument 3 has type 'long int'
warning: unused variable 'io___1'
At top level:
warning: 'c__1' defined but not used
After building the xCode Lapack project I get a number of Unix executable files and and the following 4 libraries as products: libf2c.a, libblas.a, liblapack.a, libtmglib.a
I'm using Blas and Lapack as a prerequisite for another open source project for stereo 3D reconstruction from multiple images called Insight3D (project also uses several other libraries as prerequisites). Insight3D also uses sba library, and I think that is the library which uses Lapack. I'm also compiling my project in xCode.
I add the 4 Lapack libraries into my project. When I build my project, I get no compilation errors, but I get the following linking error:
Undefined symbols:
"_MAIN__", referenced from:
_main in libf2c.a(main.o)
ld: symbol(s) not found
collect2: ld returned 1 exit status
I have tried to solve the problem for several days but I couldn't. Please provide me with any help.

