0

I am receiving the LNK 2019 error in VS2010 while trying to build the project.I have included the header files from other project using external dependencies.Each time at build time the LNK 2019 rises for the function defined in those header files.Any idea how to fix it?

Hammad Ali Butt
  • 75
  • 4
  • 13

1 Answers1

0

This error is caused by the linker which cannot find call address of an external function. So it "doesn't know" where is located the implementation of the function declared in your external header file. To fix this apart from specifying external header files you should also specify the paths to the binary files (".dll" in your case) built from your external project sources. In order to do this use context menu of your project in Visual Studio - {Properties -> Configuration Properties -> Linker -> General}, then add to the "Additional Library Directories" field paths to the directory where your extenal libraries located. After that use {Properties -> Configuration Properties -> Linker -> Input} and add to the "Additional Dependencies" field names of your external libraries ".lib" files. This should help.

Ivan
  • 588
  • 5
  • 20