thunder-engine / thunder

Thunder Engine – Cross-platform 2D and 3D game engine with modular architecture
https://thunderengine.org/
Apache License 2.0
524 stars 34 forks source link

Ported current Master to work with the BSDs #767

Closed bedwardly-down closed 3 months ago

bedwardly-down commented 3 months ago

Two extra libraries must be installed on the user's system: libinotify (for GLFW support to work) and amath (not native to the BSDs but has a port).

They won't compile anything below GLFW 3.4 (due to platform specific fixes that were added mostly involving joystick support). That's what third-party/glfw-bsd is for (to keep from breaking compatibility).

Everything but the UI builds right now due to UIKit not having Cmake implemented yet. Once that's done, these build errors should go away.

UIKit

eprikazchikov commented 3 months ago

@bedwardly-down Thank you for your PR. I guess there is no specific limitations to keep old version of GLFW. At least I don't know any. You could put just new version in appropriate directory.

eprikazchikov commented 3 months ago

Linux and Windows targets were broken please remove "glx_context.h", "wgl_context.h", "nsgl_context.h" in (glfw.qbs) because it was removed from project

bedwardly-down commented 3 months ago

Linux and Windows targets were broken please remove "glx_context.h", "wgl_context.h", "nsgl_context.h" in (glfw.qbs) because it was removed from project

Just pushed that. Thanks for your patience. :D

bedwardly-down commented 3 months ago

Checking on the GLFW issue right now. That's what I was afraid of. If Windows fails, that means Mac and Linux probably will. Have to leave for work within the hour, so may not get to it until afterwards or tomorrow.

eprikazchikov commented 3 months ago

Sure no problem. There is some linking errors. Probably new files was not added to qbs.

bedwardly-down commented 3 months ago

Sure no problem. There is some linking errors. Probably new files was not added to qbs.

I'm thinking the glfw dynamic libraries need to be explicitly added in the build steps for glfw. According to the docs, they made some slight tweaks to that. If all else fails, everything that relies on it can be manually updated.

QBS no longer has a BSD port, so I may just have to build from source to test further. It was removed a good while back.

bedwardly-down commented 3 months ago

This last one should solve the build issues. src/posix_module.c is where those references are for Linux.

bedwardly-down commented 3 months ago

Had some formatting mistakes that I missed that I quickly rectified. I thought I grabbed all of the tabs but found 3 that were causing Github to show the code wrong.

eprikazchikov commented 3 months ago

Thank you for your contribution!

bedwardly-down commented 3 months ago

Thank you for your contribution!

You’re quite welcome. As soon as CMake is setup for UIKit, I’ll have tools to work with for a project or two. 🔥

eprikazchikov commented 3 months ago

Thank you for your contribution!

You’re quite welcome. As soon as CMake is setup for UIKit, I’ll have tools to work with for a project or two. 🔥

Will try to add it in this weekend.