Skip to content
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

Use cmake import targets part 2 #1746

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

n-morales
Copy link
Contributor

Depends on #1737

This adds imported targets for SDL and OpenAL

@n-morales n-morales marked this pull request as ready for review November 3, 2024 20:33
@p2004a p2004a self-requested a review November 3, 2024 21:07

ADD_LIBRARY(headlessStubs STATIC EXCLUDE_FROM_ALL ${headlessStubsSources})
target_link_libraries(headlessStubs PUBLIC SDL2::SDL2)
Copy link
Collaborator

@p2004a p2004a Nov 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

headlessStubs should not be linking sdl2. I've also not noticed this in the previous PR only now, headless shouldn't be also linking GLEW. The same applies to dedicated.

So, 5e60482 started unnecessarily linking GLEW to headless and dedicated, this pr adds sdl2 to the mix.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I noticed that too -- it actually still needs headers -- cmake 3.27 introduces a "include only" link -- maybe we could do that?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you point me at the docs? Can't find it.

We can update build environment to cmake 3.27. Maximal version we can easy upgrade to is 3.28.4, because since 3.29 cmake requires python>=3.7 which the ancient ubuntu 18 doesn't have.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@n-morales
Copy link
Contributor Author

I fixed the COMPILE_ONLY flag for SDL2. I'm running into some issues testing with MSVC so I'll work on that; I'll mark this as draft so it doesn't get accidentally merged in since we don't have MSVC CI

@n-morales n-morales marked this pull request as draft November 24, 2024 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants