Compile bombs out!

  • Videogamer555
    6th Oct 2012 Member 0 Permalink
    I just tried the latest available source code of TPT (80.3) that has been prepared for for Codeblocks (not the absolute latest version of TPT, but it is the latest available in a project format designed for Codeblocks).

    However when I try to built it, it fails after compiling, just when it starts linking. I even made the changes recommended for an older version to get rid of some compiling problems (namely I removed -DGRAVFFT from compile options, and removed -lfftw3f from linker options). But it didn't work. I thought maybe a change fixed that old bug, and maybe even mandate those options, so I put those options back in, and it still didn't work. Below is the part of its compile log showing the errors:

    Compiling: src\powder.c
    Compiling: src\save.c
    Compiling: src\update.c
    Linking executable: bin\Release\Powder.exe
    lib\libregex.a(regex.o):regex.c:(.text+0x6ee5): undefined reference to `__chkstk_ms'
    lib\libregex.a(regex.o):regex.c:(.text.unlikely+0x66f): undefined reference to `__chkstk_ms'
    lib\libfftw3f.a(generic.o):generic.c:(.text+0x1b3): undefined reference to `__chkstk_ms'
    lib\libfftw3f.a(lt8-generic.o):generic.c:(.text+0xe0): undefined reference to `__chkstk_ms'
    lib\libfftw3f.a(lt8-generic.o):generic.c:(.text+0x260): undefined reference to `__chkstk_ms'
    lib\libfftw3f.a(transpose.o):transpose.c:(.text+0xa96): more undefined references to `__chkstk_ms' follow
    collect2: ld returned 1 exit status
    Process terminated with status 1 (0 minutes, 49 seconds)
    6 errors, 0 warnings (0 minutes, 49 seconds)

    With those extra options removed, the errors look like this instead:

    Compiling: src\powder.c
    Compiling: src\save.c
    Compiling: src\update.c
    Linking executable: bin\Release\Powder.exe
    lib\libregex.a(regex.o):regex.c:(.text+0x6ee5): undefined reference to `__chkstk_ms'
    lib\libregex.a(regex.o):regex.c:(.text.unlikely+0x66f): undefined reference to `__chkstk_ms'
    lib\libbz2.a(bzlib.o): In function `bzopen_or_bzdopen':
    c:\bzip2-1.0.6/bzlib.c:1388: undefined reference to `__chkstk_ms'
    lib\libbz2.a(blocksort.o): In function `mainSort':
    c:\bzip2-1.0.6/blocksort.c:758: undefined reference to `__chkstk_ms'
    lib\libbz2.a(huffman.o): In function `BZ2_hbMakeCodeLengths':
    c:\bzip2-1.0.6/huffman.c:67: undefined reference to `__chkstk_ms'
    collect2: ld returned 1 exit status
    Process terminated with status 1 (0 minutes, 46 seconds)
    5 errors, 0 warnings (0 minutes, 46 seconds)

    In any case, they all are of the "undefined reference to `__chkstk_ms'" variety. PLEASE tell me what to do to fix the errors called "undefined reference to `__chkstk_ms'". Thanks in advance.
  • Videogamer555
    8th Oct 2012 Member 0 Permalink
    Bump. I still need help with this. Thanks in advance.
  • abczyx123987
    8th Oct 2012 Member 0 Permalink
    Here, try reading this:
    https://powdertoy.co.uk/Discussions/Thread/View.html?Thread=14844
    In particular, read the second post of that thread.

    I know it's kinda messed up that you have to have a specific version of MinGW in order to compile, but...(sorry about that, not much I can do at this point)

    If you need any help, just ask...(and if you choose to upgrade your compiler and can't find the correct version (4.6.x), try looking here: http://sourceforge.net/projects/tdm-gcc/files/TDM-GCC%20Installer/Previous/1.1006.0/ ).