Undefined reference to soil_load_ogl_texture


I have already included SOIL, so I tried to manually link the library, and I get MANY more errors, such as:

[Linker error] ../../../../../../../../../../Program Files (x86)/Dev-Cpp/MinGW32/lib/SOIL.lib(Debug/stb_image_aug.obj):(.text[_convert_format]+0x5b): undefined reference to `_RTC_CheckEsp'
.drectve `/DEFAULTLIB:"MSVCRTD" /DEFAULTLIB:"OLDNAMES" /EDITANDCONTINUE ' unrecognized

These errors were not there before. And ideas and/or help is appreciated.

U get these errors normally when u forget to mention the namespace:
try:
using xyznamespace;
or
xyznamespace::ur required fun or attr

I tried with Dev-C++ 5.2.0.2 TDM x64, and GL\glext.h was missing (which was needed to compile test_SOIL.cpp). But it does have GL\glaux.h, go figure.

Other than that, I can't tell where your linker errors are coming from.
Did you try putting the library in the same folder as the source code, and adding it to the project?
Project Options -> Parameters -> Add Library or Object

Now as for Orwell's Dev-C++. I think some of the higher-postcount members can confirm I've always been a big fan. until recently, when I realized 5.1+ was so full of bugs, I could start a zoo.

So how about a change, as Obama would say?

Last edited on

@anirudh sn:
I treid using namespace xyznamespace, but I got this error:
15 17 C:\Users\*my_username*\Other\flashdrive\other\MyWeb\C++\tools\OPENGL\textures\main - textures.cpp [Error] 'xyznamespace' is not a namespace-name

You're REQUIRED fun or attr?? I never used either. If it helps, my includes are:
1
2
3
4
5
6
7
8
9
10
11
12
13

@Catfish2:
I tried, but it gave my the same issues as when I tried to link the library in Dev C++'s bin. However, I'm running MinGW.