shinyquagsire23 / OpenJKDF2

A cross-platform reimplementation of JKDF2 in C
Other
493 stars 39 forks source link

Linux64 uncessary library builds #272

Open mlauss2 opened 1 year ago

mlauss2 commented 1 year ago

Trying to build latest master:

-- Found OpenAL: /usr/lib64/libopenal.so  

ok, but now:

-- Found GLUT: /usr/lib64/libglut.so  
-- Going to build “FreeGLUT 3.4.0” from Git module
-- Could NOT find GLEW (missing: GLEW_LIBRARIES) (found suitable version "2.2.0", minimum required is "2.2.0")
-- Going to build “GLEW 2.2.0” from Git module
-- Going to build “zlib 1.2.13” from Git module
-- Going to build “PhysFS 3.2.0” from Git module
-- Going to build “protobuf 3.21.12” from Git module

The above 5 dependencies (as well as sdl2, sdl2_mixer and libpng) are available on the system (as shared libraries), and can geberally be detected by CMake in other projects.

Thanks!

shinyquagsire23 commented 1 year ago

Yeah it's ~mostly for consistency w/ the Flatpak builds (all releases on the same version etc) but build times unfortunately took a bit of an unnecessary hit, I'll have to add some CMake flags to use system libraries for ~some things like libpng/SDL2 where it's probably fine (GameNetworkingSockets though, probably will be forced to always compile because I just Do Not trust distros to keep that consistent, protobuf especially is a nightmare)

mlauss2 commented 1 year ago

Ah, I see. Why not look for system versions of the libraries first, and if their version numbers are lower than the minimum/don't match the tested versions (protobuf, GameNetworkingSockets) build them in-tree (EDIT: now that I'm thinking about it, that's an unnecessary hassle.)

I had to create a few lib->lib64 symlinks in the 3rd party libs to get it to actually link the final binary, but other than that it's great fun to play it once again after 25 years.