Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(+1)

Hi,

This error is due to mixing 32 and 64 binaries. Make sure that Tilengine.dll and SDL2.dll you put in the same folder than the executable file match the CPU architecture.

gcc in windows can only generate 32-bit binaries, that's why you get the linker errors when trying to link to 64-bit version. There's something called mingw64 that can work 64-bit binaries, but for my daily tasks I use Tiny C Compiler that supports both architectures, has small footprint and mostly a drop-in replacement for gcc:

https://bellard.org/tcc/

Here you can see a screenshoot building test sample:

  • tcc builds correctly for both 32-bit and 64-bit bit
  • gcc builds correctly for 32-bit but fails for 64-bit


I was actually using gcc from my mingw64 install, but perhaps that isn't right.  I'll try tcc and see how that works out for me.  Not sure if this is a mistake or not, but SDL2.dll is not in the lib folder for the 64 bit version.  I know I'm not mixing binaries though as I have two separate installs for the 32 and 64 bit versions.