Skip to content

Conversation

@leha-bot
Copy link

@leha-bot leha-bot commented Feb 23, 2024

These targets are similar to upstream CMake's generated targets for OpenGL.

See
https://cmake.org/cmake/help/latest/module/FindOpenGL.html for details.

@leha-bot leha-bot force-pushed the feature/cmake-module-add-opengl-imported-targets branch from 53b4a52 to 369b40f Compare February 23, 2024 09:47
@leha-bot
Copy link
Author

I would like also to contribute the test, but don't know how to organize it;
I tested it locally in my own Emscripten instance with my old pet project (in-house rendering engine) which uses the OpenGL imported targets. I lazily port it into the Emscripten/WASM to make sure it would work in browser :)

@leha-bot leha-bot force-pushed the feature/cmake-module-add-opengl-imported-targets branch from 369b40f to 1a6ba91 Compare March 3, 2024 17:45
@kripken
Copy link
Member

kripken commented Mar 5, 2024

Perhaps @juj or @sbc100 can take a look at this? (I don't know enough cmake myself.)

Regarding a test, in test/test_other.py there are several tests with names beginning with test_cmake_ that could be helpful (e.g. test_cmake_compile_features).

@sbc100
Copy link
Collaborator

sbc100 commented Mar 6, 2024

I'm not a cmake expert either I'm afraid but it looks like this should be tested as part of test_cmake_find_modules.

@gracicot
Copy link
Contributor

gracicot commented Apr 1, 2024

Knowing a little bit about CMake, I can see that it matches upstream. Specifically those lines: https://gitlab.kitware.com/cmake/cmake/-/blob/d166e7d740bfb53c18221f1126e984b668923208/Modules/FindOpenGL.cmake#L693

It would make the module in line with CMake 3.29, which is a very good thing, and expected from CMake users.

@sbc100
Copy link
Collaborator

sbc100 commented Apr 1, 2024

I'm in favor of this change too.. just waiting on a test.

@leha-bot leha-bot force-pushed the feature/cmake-module-add-opengl-imported-targets branch from 1a6ba91 to 47cd260 Compare April 9, 2024 12:40
These targets are similar to upstream CMake's generated targets for
OpenGL.

See
https://cmake.org/cmake/help/latest/module/FindOpenGL.html
for details.
@leha-bot leha-bot force-pushed the feature/cmake-module-add-opengl-imported-targets branch from 47cd260 to 4f8a5dd Compare April 14, 2024 16:51
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.

4 participants