<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Dynamic linking works but static linking fails in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Dynamic-linking-works-but-static-linking-fails/m-p/894146#M10707</link>
    <description>&lt;DIV style="margin:0px;"&gt;
&lt;DIV id="quote_reply" style="width: 100%; margin-top: 5px;"&gt;
&lt;DIV style="margin-left:2px;margin-right:2px;"&gt;Quoting - &lt;A href="https://community.intel.com/en-us/profile/290918"&gt;sangamesh&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV style="background-color:#E5E5E5; padding:5px;border: 1px; border-style: inset;margin-left:2px;margin-right:2px;"&gt;&lt;EM&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;With Intel MKL-10.0.5.025 and ifort-10.1.008, when static linking is used(Sequntial linking, link line is: $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread) &lt;BR /&gt;&lt;BR /&gt;the compilation fails with following error:&lt;BR /&gt;&lt;BR /&gt;/opt/mpi/openmpi/1.3.3/intel/bin/mpif90 -I/opt/libs/netcdf/4.0.1/intel/include -o transiesta &lt;BR /&gt; automatic_cell.o atom_options.o arw.o atomlwf.o bands.o basis_enthalpy.o bessph.o bonds.o born_charge.o m_ts_aux_rout.o m_ts_kpoints.o m_ts_io.o m_ts_scattering.o m_ts_contour.o m_ts_electrode.o m_ts_in_siesta.o libfdf.a &lt;BR /&gt; libmpi_f90.a &lt;BR /&gt; &lt;STRONG&gt;dc_lapack.a liblapack.a libblas.a &lt;/STRONG&gt; `FoX/FoX-config --libs --wcml` /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_scalapack_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_solver_lp64_sequential.a -Wl,--start-group /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_intel_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_sequential.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread /opt/libs/netcdf/4.0.1/intel/lib/libnetcdf.a&lt;BR /&gt;/opt/intel/fce/10.1.008/lib/libimf.so: warning: warning: feupdateenv is not implemented and will always fail&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgesv.o): In function `mkl_lapack_zgesv':&lt;BR /&gt;__tmp_zgesv.f:(.text+0xbf): undefined reference to `mkl_lapack_zgetrf'&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgetrs.o): In function `mkl_lapack_zgetrs':&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x1fe): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x27f): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x30b): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x386): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;&lt;BR /&gt;But if the same link line is added with dynamic libraries, then it compiles successfully.&lt;BR /&gt;&lt;BR /&gt;MKLPRL=-L$(MKLPATH) -lmkl_lapack -lmkl_core $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread&lt;BR /&gt;&lt;BR /&gt;Why so?&lt;BR /&gt;&lt;BR /&gt;Please justify am I doing anything wrong? or its a problem with static library?&lt;BR /&gt;&lt;BR /&gt;Thank you&lt;/EM&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
sangamesh,&lt;BR /&gt;Can you remove "dc_lapack.a liblapack.a libblas.a" libraries from your linking line? &lt;BR /&gt;--Gennady&lt;BR /&gt;</description>
    <pubDate>Thu, 05 Nov 2009 15:09:06 GMT</pubDate>
    <dc:creator>Gennady_F_Intel</dc:creator>
    <dc:date>2009-11-05T15:09:06Z</dc:date>
    <item>
      <title>Dynamic linking works but static linking fails</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Dynamic-linking-works-but-static-linking-fails/m-p/894145#M10706</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;With Intel MKL-10.0.5.025 and ifort-10.1.008, when static linking is used(Sequntial linking, link line is: $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread) &lt;BR /&gt;&lt;BR /&gt;the compilation fails with following error:&lt;BR /&gt;&lt;BR /&gt;/opt/mpi/openmpi/1.3.3/intel/bin/mpif90 -I/opt/libs/netcdf/4.0.1/intel/include -o transiesta \&lt;BR /&gt; automatic_cell.o atom_options.o arw.o atomlwf.o bands.o basis_enthalpy.o bessph.o bonds.o born_charge.o m_ts_aux_rout.o m_ts_kpoints.o m_ts_io.o m_ts_scattering.o m_ts_contour.o m_ts_electrode.o m_ts_in_siesta.o libfdf.a \&lt;BR /&gt; libmpi_f90.a \&lt;BR /&gt; dc_lapack.a liblapack.a libblas.a `FoX/FoX-config --libs --wcml` /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_scalapack_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_solver_lp64_sequential.a -Wl,--start-group /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_intel_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_sequential.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread /opt/libs/netcdf/4.0.1/intel/lib/libnetcdf.a&lt;BR /&gt;/opt/intel/fce/10.1.008/lib/libimf.so: warning: warning: feupdateenv is not implemented and will always fail&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgesv.o): In function `mkl_lapack_zgesv':&lt;BR /&gt;__tmp_zgesv.f:(.text+0xbf): undefined reference to `mkl_lapack_zgetrf'&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgetrs.o): In function `mkl_lapack_zgetrs':&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x1fe): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x27f): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x30b): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x386): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;&lt;BR /&gt;But if the same link line is added with dynamic libraries, then it compiles successfully.&lt;BR /&gt;&lt;BR /&gt;MKLPRL=-L$(MKLPATH) -lmkl_lapack -lmkl_core $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread&lt;BR /&gt;&lt;BR /&gt;Why so?&lt;BR /&gt;&lt;BR /&gt;Please justify am I doing anything wrong? or its a problem with static library?&lt;BR /&gt;&lt;BR /&gt;Thank you</description>
      <pubDate>Wed, 04 Nov 2009 15:16:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Dynamic-linking-works-but-static-linking-fails/m-p/894145#M10706</guid>
      <dc:creator>Sangamesh_B_</dc:creator>
      <dc:date>2009-11-04T15:16:48Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic linking works but static linking fails</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Dynamic-linking-works-but-static-linking-fails/m-p/894146#M10707</link>
      <description>&lt;DIV style="margin:0px;"&gt;
&lt;DIV id="quote_reply" style="width: 100%; margin-top: 5px;"&gt;
&lt;DIV style="margin-left:2px;margin-right:2px;"&gt;Quoting - &lt;A href="https://community.intel.com/en-us/profile/290918"&gt;sangamesh&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV style="background-color:#E5E5E5; padding:5px;border: 1px; border-style: inset;margin-left:2px;margin-right:2px;"&gt;&lt;EM&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;With Intel MKL-10.0.5.025 and ifort-10.1.008, when static linking is used(Sequntial linking, link line is: $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread) &lt;BR /&gt;&lt;BR /&gt;the compilation fails with following error:&lt;BR /&gt;&lt;BR /&gt;/opt/mpi/openmpi/1.3.3/intel/bin/mpif90 -I/opt/libs/netcdf/4.0.1/intel/include -o transiesta &lt;BR /&gt; automatic_cell.o atom_options.o arw.o atomlwf.o bands.o basis_enthalpy.o bessph.o bonds.o born_charge.o m_ts_aux_rout.o m_ts_kpoints.o m_ts_io.o m_ts_scattering.o m_ts_contour.o m_ts_electrode.o m_ts_in_siesta.o libfdf.a &lt;BR /&gt; libmpi_f90.a &lt;BR /&gt; &lt;STRONG&gt;dc_lapack.a liblapack.a libblas.a &lt;/STRONG&gt; `FoX/FoX-config --libs --wcml` /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_scalapack_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_solver_lp64_sequential.a -Wl,--start-group /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_intel_lp64.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_sequential.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a /opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread /opt/libs/netcdf/4.0.1/intel/lib/libnetcdf.a&lt;BR /&gt;/opt/intel/fce/10.1.008/lib/libimf.so: warning: warning: feupdateenv is not implemented and will always fail&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgesv.o): In function `mkl_lapack_zgesv':&lt;BR /&gt;__tmp_zgesv.f:(.text+0xbf): undefined reference to `mkl_lapack_zgetrf'&lt;BR /&gt;/opt/intel/mkl/10.0.5.025/lib/em64t/libmkl_core.a(zgetrs.o): In function `mkl_lapack_zgetrs':&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x1fe): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x27f): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x30b): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;__tmp_zgetrs.f:(.text+0x386): undefined reference to `mkl_blas_ztrsm'&lt;BR /&gt;&lt;BR /&gt;But if the same link line is added with dynamic libraries, then it compiles successfully.&lt;BR /&gt;&lt;BR /&gt;MKLPRL=-L$(MKLPATH) -lmkl_lapack -lmkl_core $(MKLPATH)/libmkl_scalapack_lp64.a $(MKLPATH)/libmkl_solver_lp64_sequential.a -Wl,--start-group $(MKLPATH)/libmkl_intel_lp64.a $(MKLPATH)/libmkl_sequential.a $(MKLPATH)/libmkl_core.a $(MKLPATH)/libmkl_blacs_openmpi_lp64.a -Wl,--end-group -lpthread&lt;BR /&gt;&lt;BR /&gt;Why so?&lt;BR /&gt;&lt;BR /&gt;Please justify am I doing anything wrong? or its a problem with static library?&lt;BR /&gt;&lt;BR /&gt;Thank you&lt;/EM&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
sangamesh,&lt;BR /&gt;Can you remove "dc_lapack.a liblapack.a libblas.a" libraries from your linking line? &lt;BR /&gt;--Gennady&lt;BR /&gt;</description>
      <pubDate>Thu, 05 Nov 2009 15:09:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Dynamic-linking-works-but-static-linking-fails/m-p/894146#M10707</guid>
      <dc:creator>Gennady_F_Intel</dc:creator>
      <dc:date>2009-11-05T15:09:06Z</dc:date>
    </item>
  </channel>
</rss>

