-
-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Working on Windows...? #241
Comments
Any errors? |
None - there's no output, no nothing. I'm pretty sure it's not actually 'connecting' properly as the bot never appears to even go online in the channel I've invited it to. |
Can you try debugging and walking through the code and see if run() ever gets called and runs? |
The run command does trigger but appears to end up in default_functions.cpp, where the run() is empty. |
Looks like the library thinks you are using custom for async and websockets. Can I see your CMakeLists.txt? |
My project unfortunately isn't generated using CMake, as the framework it's based on (libcinder) generates its own Visual Studio solution. It sounds like not having the right flags is causing these issues then. |
The library is generally configured using CMake, it's how the library knows what library to use for async, websockets, and https. |
I basically build |
I found this online https://libcinder.org/docs/guides/cmake/cmake.html |
I appreciate the effort. I think that guide is for building the Cinder framework itself. Not applications built on top of Cinder. Cinder provides a toolkit to generate the visual studio project files for projects built on top of cinder - which is my use case. In other words, the CMake file I'm missing is not for Cinder, but for the application I have to use Cinder. I think I might know what to do. When I build sleepy-discord externally using CMake, it's provided the So if I understand things - all I need to do, is to manually add the |
There's more to it than that, There's a number of variables that the library uses that's generated by CMake. Doing this manually isn't something I recommend. I read the article I linked, it says "Building your application with CMake" so it's not just building Cinder but your app with Cinder. |
You're right @yourWaifu . I'll have a look further into it. Really appreciate the prompt and helpful feedback! |
After about 4 days of work (which I initially estimated to take 1 day - sigh), I managed to fully port my project to build with CMake and eagerly added the linking code for sleepy discord. Unfortunately, I ran into some issues and opted to then reduce the problem down the bare essentials. My project relies on boost and curl, and thus includes these libraries on its own accord. My current understanding is that some of the definitions in CMake and possibly in the C++ project don't trigger as intended in sleepy discord for me. I'm wondering if I've neglected to manually set some options in sleepy discord, but so far looking over the code I would think things should work as expected. I can confirm that the When the project is finally compiled I run into two errors: Severity Code Description Project File Line Suppression State and Severity Code Description Project File Line Suppression State The first one is easy enough to fix, as I reckon I need to add boost to my included folders. The other one I'm far more puzzled about. Despite supposedly using boost for ASIO, the define Am I missing some other settings I need to apply? Here's my CMake code just in case:
|
I like to see the commands that the build tool is running, it should define sleepy-discord/include/sleepy_discord/asio_include.h Lines 25 to 37 in 247f1bd
sleepy-discord/sleepy_discord/CMakeLists.txt Lines 84 to 88 in 247f1bd
|
Here's the build command that's part of the
It does define I've tracked I'm still a CMake novice, so I'm not sure if the problem is perhaps that some boost header which is expected to define |
Any thoughts on the issue? I intend to further investigate the matter this weekend myself. |
After further investigation, it appears that some of the defines in sleepy-discord intersect with defines in the framework I use as part of my application. When I figure out exactly where it goes sideways, I'll post something here to help others. |
Related to microsoft/vcpkg#20372. @yourWaifu, sleepy-discord supported in vcpkg. Currently it could build on windows, linux and osx. From https://github.com/yourWaifu/sleepy-discord/blob/develop/CMakeLists.txt#L35. it looks USE_BOOST_ASIO is OFF by default, and enabled when use USE_UWEBSOCKETS and USE_WEBSOCKETPP, however, from https://github.com/yourWaifu/sleepy-discord/blob/develop/sleepy_discord/CMakeLists.txt#L2 adds asio_udp unconditionally. I want double confirm what's the expected behavior here? |
My own need for resolution on the issue has ended. It might be worth opening a separate issue for the matter you're inquiring about @PhoebeHui ? I'll keep this open for a few more days, but if there's no follow up I prefer to close it off. |
First and foremost - this library looks like just what I've been searching for. Thank you very much for all the effort made thus far.
However, I'm unable to get it do seemingly do anything on Windows. I've compiled the code into my project and it seems to compile fine but even the basic example appears to do nothing (and also be a bit out of date on the master branch)
https://github.com/yourWaifu/sleepy-discord/blob/master/examples/hello/example0.cpp
Perhaps it's because I'm trying to use master as opposed to v0...?
The text was updated successfully, but these errors were encountered: