Linking the libxlopt library

By default, the libxlopt library is linked with any application that you compile with the XL C compiler. However, if you are using a third-party BLAS library but want to use the BLAS routines shipped with libxlopt, you must specify the libxlopt library before any other BLAS library on the command line at link time. For example, if your other BLAS library is called libblas.a, you would compile your code with the following command:
xlc app.c -lxlopt -lblas
The compiler will call the sgemv, dgemv, sgemm, and dgemm functions from the libxlopt library and all other BLAS functions in the libblas.a library.


Voice your opinion on getting help information Ask IBM compiler experts a technical question in the IBM XL compilers forum Reach out to us