<?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 Linking IPP with MinGW_64 for Windows undefined reference errors in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/Linking-IPP-with-MinGW-64-for-Windows-undefined-reference-errors/m-p/1126019#M25655</link>
    <description>&lt;P&gt;We are using Qt 5.12.0 and MinGW 64bit for our Windows application.&amp;nbsp; We statically link IPP libraries to perform FFTs.&lt;/P&gt;&lt;P&gt;If I use MSVC2017 I get no link errors, however when I use mingw73_64 I get 234 errors, e.g. undefined reference to `__security_check_cookie',&amp;nbsp;undefined reference to `__GSHandlerCheck' and&amp;nbsp;undefined reference to `__chkstk'.&lt;/P&gt;&lt;P&gt;Note that to get just these errors, it is important to link the following libraries in this order: 1. ippsmt.lib 2. ippvmt.lib 3. ippcoremt.lib; otherwise you get more errors.&amp;nbsp; The library order does not matter if using MSVC2017.&lt;/P&gt;&lt;P&gt;I find if I include the following code I can successfully link to the IPP libraries for Windows using mingw_64:&lt;/P&gt;
&lt;PRE class="brush:cpp; class-name:dark;"&gt;#ifdef __MINGW64__
void __chkstk() {}
void __GSHandlerCheck() {}
void __security_check_cookie() {}
#endif //__MINGW64__
&lt;/PRE&gt;

&lt;P&gt;1. Does Intel IPP support MinGW?&amp;nbsp; If not, does it only support MSVC&amp;nbsp;compilers?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2. Can you (Intel) clearly post what compilers IPP does support? Or point me where it is documented as I can't seem to&amp;nbsp;find it?&lt;/P&gt;
&lt;P&gt;3. Does the above "void _functionName() {}" workaround have any negative consequences?&lt;/P&gt;
&lt;P&gt;4. Is there a better workaround than&amp;nbsp;"void _functionName() {}"?&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;-Joe&lt;/P&gt;
&lt;P&gt;Test Code:&lt;/P&gt;

&lt;PRE class="brush:cpp; class-name:dark;"&gt;#include &amp;lt;stdint.h&amp;gt;
#include &amp;lt;ipps.h&amp;gt;
int main()
{
  int size_fft_spec, size_fft_init_buffer, size_fft_work_buffer;
  ippsFFTGetSize_C_64fc(4, IPP_FFT_NODIV_BY_ANY, ippAlgHintNone, &amp;amp;size_fft_spec, &amp;amp;size_fft_init_buffer, &amp;amp;size_fft_work_buffer);

  return 0;
}

Compile and Link commands:
gcc -c -fno-keep-inline-dllexport -O2 -g -Wall -W -Wextra -DUNICODE -D_UNICODE -DWIN32 -DMINGW_HAS_SECURE_API=1 -DQT_QML_DEBUG -I..\ippTest -I. -I..\include -I..\include -IC:\Qt\5.12.0\mingw73_64\mkspecs\win32-g++  -o release\main.o ..\ippTest\main.c
g++ -Wl,-subsystem,console -mthreads -o release\ippTest.exe release/main.o  -LC:\&amp;lt;path&amp;gt;\ipp\lib -lippsmt -lippvmmt -lippcoremt &lt;/PRE&gt;

&lt;P&gt;Errors:&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/dfti_get_size_k0/dfti_get_size_k0---mkl_dft_avx512_dfti_get_size_dc1d.obj):(.text[k0_mkl_dft_avx512_dfti_get_size_dc1d]+0x1cd): undefined reference to `__security_check_cookie'&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/dfti_get_size_k0/dfti_get_size_k0---mkl_dft_avx512_dfti_get_size_dc1d.obj):(.xdata+0x14): undefined reference to `__GSHandlerCheck'&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/pscmndft_dftsfactmicca_k0/pscmndft_dftsfactmicca_k0---ownscDftInv_Prime14_32fc.obj):(.text[k0_ownscDftInv_Prime14_32fc]+0x10c9): undefined reference to `__chkstk'&lt;/P&gt;</description>
    <pubDate>Fri, 04 Jan 2019 00:36:54 GMT</pubDate>
    <dc:creator>Barrus__Joe</dc:creator>
    <dc:date>2019-01-04T00:36:54Z</dc:date>
    <item>
      <title>Linking IPP with MinGW_64 for Windows undefined reference errors</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Linking-IPP-with-MinGW-64-for-Windows-undefined-reference-errors/m-p/1126019#M25655</link>
      <description>&lt;P&gt;We are using Qt 5.12.0 and MinGW 64bit for our Windows application.&amp;nbsp; We statically link IPP libraries to perform FFTs.&lt;/P&gt;&lt;P&gt;If I use MSVC2017 I get no link errors, however when I use mingw73_64 I get 234 errors, e.g. undefined reference to `__security_check_cookie',&amp;nbsp;undefined reference to `__GSHandlerCheck' and&amp;nbsp;undefined reference to `__chkstk'.&lt;/P&gt;&lt;P&gt;Note that to get just these errors, it is important to link the following libraries in this order: 1. ippsmt.lib 2. ippvmt.lib 3. ippcoremt.lib; otherwise you get more errors.&amp;nbsp; The library order does not matter if using MSVC2017.&lt;/P&gt;&lt;P&gt;I find if I include the following code I can successfully link to the IPP libraries for Windows using mingw_64:&lt;/P&gt;
&lt;PRE class="brush:cpp; class-name:dark;"&gt;#ifdef __MINGW64__
void __chkstk() {}
void __GSHandlerCheck() {}
void __security_check_cookie() {}
#endif //__MINGW64__
&lt;/PRE&gt;

&lt;P&gt;1. Does Intel IPP support MinGW?&amp;nbsp; If not, does it only support MSVC&amp;nbsp;compilers?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2. Can you (Intel) clearly post what compilers IPP does support? Or point me where it is documented as I can't seem to&amp;nbsp;find it?&lt;/P&gt;
&lt;P&gt;3. Does the above "void _functionName() {}" workaround have any negative consequences?&lt;/P&gt;
&lt;P&gt;4. Is there a better workaround than&amp;nbsp;"void _functionName() {}"?&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;-Joe&lt;/P&gt;
&lt;P&gt;Test Code:&lt;/P&gt;

&lt;PRE class="brush:cpp; class-name:dark;"&gt;#include &amp;lt;stdint.h&amp;gt;
#include &amp;lt;ipps.h&amp;gt;
int main()
{
  int size_fft_spec, size_fft_init_buffer, size_fft_work_buffer;
  ippsFFTGetSize_C_64fc(4, IPP_FFT_NODIV_BY_ANY, ippAlgHintNone, &amp;amp;size_fft_spec, &amp;amp;size_fft_init_buffer, &amp;amp;size_fft_work_buffer);

  return 0;
}

Compile and Link commands:
gcc -c -fno-keep-inline-dllexport -O2 -g -Wall -W -Wextra -DUNICODE -D_UNICODE -DWIN32 -DMINGW_HAS_SECURE_API=1 -DQT_QML_DEBUG -I..\ippTest -I. -I..\include -I..\include -IC:\Qt\5.12.0\mingw73_64\mkspecs\win32-g++  -o release\main.o ..\ippTest\main.c
g++ -Wl,-subsystem,console -mthreads -o release\ippTest.exe release/main.o  -LC:\&amp;lt;path&amp;gt;\ipp\lib -lippsmt -lippvmmt -lippcoremt &lt;/PRE&gt;

&lt;P&gt;Errors:&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/dfti_get_size_k0/dfti_get_size_k0---mkl_dft_avx512_dfti_get_size_dc1d.obj):(.text[k0_mkl_dft_avx512_dfti_get_size_dc1d]+0x1cd): undefined reference to `__security_check_cookie'&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/dfti_get_size_k0/dfti_get_size_k0---mkl_dft_avx512_dfti_get_size_dc1d.obj):(.xdata+0x14): undefined reference to `__GSHandlerCheck'&lt;/P&gt;
&lt;P&gt;C:\&amp;lt;path&amp;gt;\ipp\lib/ippsmt.lib(C:/Temp/commander/build_lib/ipp-2019u1-rls/.build/windows/obj/intel64/ipps/mrg_cpu/k0/st/pscmndft_dftsfactmicca_k0/pscmndft_dftsfactmicca_k0---ownscDftInv_Prime14_32fc.obj):(.text[k0_ownscDftInv_Prime14_32fc]+0x10c9): undefined reference to `__chkstk'&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jan 2019 00:36:54 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Linking-IPP-with-MinGW-64-for-Windows-undefined-reference-errors/m-p/1126019#M25655</guid>
      <dc:creator>Barrus__Joe</dc:creator>
      <dc:date>2019-01-04T00:36:54Z</dc:date>
    </item>
    <item>
      <title>Hi, </title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Linking-IPP-with-MinGW-64-for-Windows-undefined-reference-errors/m-p/1126020#M25656</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;IPP does not support the MinGW.&amp;nbsp;&amp;nbsp;The "__security_check_cookie" some symbols from Microsoft libraries.&amp;nbsp; There is some workaround someone used before to pass the linkage errors:&lt;/P&gt;&lt;P&gt;&lt;A href="https://software.intel.com/en-us/forums/intel-integrated-performance-primitives/topic/288853" target="_blank"&gt;https://software.intel.com/en-us/forums/intel-integrated-performance-primitives/topic/288853&lt;/A&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;BR /&gt;Chao&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Jan 2019 08:14:13 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Linking-IPP-with-MinGW-64-for-Windows-undefined-reference-errors/m-p/1126020#M25656</guid>
      <dc:creator>Chao_Y_Intel</dc:creator>
      <dc:date>2019-01-07T08:14:13Z</dc:date>
    </item>
  </channel>
</rss>

