0

I am making a small game engine in Visual Studio. As far as I am aware I have everything linked correctly, but I am still generating this in the .log file

Creating library C:\dev\Gluten\Gluten\bin\x64\Release\Gluten.lib and object C:\dev\Gluten\Gluten\bin\x64\Release\Gluten.exp
WindowsWindow.obj : error LNK2001: unresolved external symbol gladLoadGLLoader
C:\dev\Gluten\Gluten\bin\x64\Release\Gluten.dll : fatal error LNK1120: 1 unresolved externals

Here is my Additional Include Directories

$(SolutionDir)Gluten\vendor\GLAD\include\

My Additional Libraries

$(SolutionDir)Gluten\vendor\GLAD\lib\

And I am including glad.lib in my linker input

This is my project structure

enter image description here

genpfault
  • 51,148
  • 11
  • 85
  • 139
DevStuffz
  • 19
  • 9
  • Is that the only error? Did you get an error that states it can't open `glad.lib`? – drescherjm Jun 08 '21 at 18:16
  • yes, that is the only error. There are no runtime errors only build – DevStuffz Jun 08 '21 at 18:16
  • Did you apply the compiler and linker settings to all configurations (Debug, Release ...) instead of just the active configuration? The default behavior is just the active configuration. – drescherjm Jun 08 '21 at 18:17
  • Yes, I am on all configurations and only have one platform, x64 – DevStuffz Jun 08 '21 at 18:18
  • 3
    @DevStuffz I suggest you should add the `glad.c` to your solution. Go to Visual Studio > Solution Explorer > Source Files > Add > Existing Item .. – Jeaninez - MSFT Jun 10 '21 at 05:46
  • What @DevStuffz said. This is one src file project. I have it with the rest of the source files.Then you don't have any linker headache to sort out. – Michael IV Jun 10 '21 at 17:38
  • @Jeaninez-MSFT this was correct! please make an answer so I can mark it – DevStuffz Jul 17 '21 at 04:42

1 Answers1

1

I suggest you should add the glad.c to your solution.

Go to Visual Studio > Solution Explorer > Source Files > Add > Existing Item.

Jeaninez - MSFT
  • 3,210
  • 1
  • 5
  • 20