Application built with makefile works fine, but same code built in IDE crashes

Greetings all,

I used msys64 mingw32 (on Windows 7, 64 bit) to build a 3rd party library (https://sourceforge.net/p/libosmscout/code/ci/master/tree/) using a supplied makefile.

There is a demo application which I would like to use as a starting point for building my own application in Code::Blocks IDE. The problem is that, while the auto built demo application (with makefile) runs fine, the one I try to build with Code::Blocks crashes right after running it. I used the same .cpp source file in the IDE and added required .dlls in the project directory. Also, by looking at the demo application's makefile, I tried to copy flags CFLAGS and LIBS, for example:

1
2
3
LIBOSMSCOUT_CFLAGS = -fopenmp -mmmx -msse -msse2 -mssse3
LIBOSMSCOUT_LIBS = -losmscoutmap -fopenmp -losmscout
LIBPNG_LIBS = -L/mingw32/lib -lpng16 -lz  


into project->linker settings->other linker options

Of course at first I was getting errors for missing libraries and undefined references. But I worked to solve them until I got successful build with 0 warnings/errors. But as said, the application crashes upon execution.

I am a beginner and actually don't even know how exactly to ask for help on this matter, so I apologize for the confusion and lack of clarity. I would basically like to know how to make this demo application work, when built in Code::Blocks IDE. Since now only the auto built executable works properly.

Thank you very much for help
cheers T

Last edited on
*Bump, if I may
Topic archived. No new replies allowed.