sleepy-discord icon indicating copy to clipboard operation
sleepy-discord copied to clipboard

Cannot build self app with lib

Open d4rkd3n1337 opened this issue 2 years ago • 5 comments

Hi, i am new to CMake, but I can compiled that.

I create self app, and include "C:\path_to_sleepy_discord\include" and "C:\path_to_sleepy_discord\include\IncludeNonexistent". Also linking a static lib - "C:\path_to_sleepy_discord\Release" - sleepy-discord.lib

But if I am trying to compile, I have next error: unresolvered external symbol "public: static class SleepyDiscord::GenericSession * (__cdecl* SleepyDiscord::CustomSession::init)(void)" (?init@CustomSession@SleepyDiscord@@2Q6APEAVGenericSession@2@XZEA).

How I can solve it?

d4rkd3n1337 avatar Aug 30 '21 18:08 d4rkd3n1337

What does your CMakeLists.txt file look like

yourWaifu avatar Aug 30 '21 18:08 yourWaifu

I am use a default CMakeLists CMakeLists.txt

d4rkd3n1337 avatar Aug 30 '21 18:08 d4rkd3n1337

I'm asking for the one you wrote not the library's

yourWaifu avatar Aug 30 '21 18:08 yourWaifu

Hello :3, I am use a MSVS, dont use a cmake

d4rkd3n1337 avatar Aug 31 '21 06:08 d4rkd3n1337

https://docs.microsoft.com/en-us/cpp/build/cmake-projects-in-visual-studio?view=msvc-160

yourWaifu avatar Aug 31 '21 14:08 yourWaifu