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

Make the testsuite a standalone CMake project #208

Closed
ghisvail opened this issue Sep 1, 2016 · 14 comments
Closed

Make the testsuite a standalone CMake project #208

ghisvail opened this issue Sep 1, 2016 · 14 comments

Comments

@ghisvail
Copy link
Contributor

ghisvail commented Sep 1, 2016

More of a wishlist item than an issue actually. It would be nice to make the tests in source/tests a standlone CMake project, so that they can be run against the built target as it is now, but also against an already installed one (for instance coming from a package or an embedded version).

This would be significantly ease the Debian CI process, since all this would require is installing the libglbinding-dev package, copy the source/tests directory to the testbed and run a standard CMake configuration, build and run.

I am able to achieve this at the moment, but the following must be prepended to source/tests/CMakeLists.txt:

cmake_minimum_required(VERSION 3.0)
project(glbinding-tests)

if (POLICY CMP0063)
  cmake_policy(SET CMP0063 NEW)
endif ()

find_package(glbinding REQUIRED)
set(META_PROJECT_NAME "glbinding")

list(APPEND CMAKE_MODULE_PATH "\${CMAKE_CURRENT_SOURCE_DIR}/cmake")
include(CompileOptions)

set(OPTION_BUILD_TESTS ON)
set(OPTION_BUILD_GPU_TESTS OFF)

FYI, Debian is not the only distribution with CI in place, so addressing this should benefit a larger crowd.

Cheers,

@ghisvail
Copy link
Contributor Author

FYI, glbinding is now officially available in Debian. The CI I mentioned earlier can be monitored here.

@sbusch42
Copy link
Member

That's awesome! Thank you :)

We will most likely integrate the changes you proposed for making the deployment easier, but it will take some time ...

@ghisvail
Copy link
Contributor Author

Take your time. I might also attempt an official packaging for globjects, but I am guessing from the current version numbers that the API is not stable yet. Am I correct?

@scheibel
Copy link
Member

Partly. We're preparing the 1.0 release since several weeks and the list of missing things is surprisingly small. However, I suggest delaying a globjects packaging for Debian for a couple of weeks after the 1.0 release so we can react on first errors for other users.

@ghisvail
Copy link
Contributor Author

I suggest delaying a globjects packaging for Debian for a couple of weeks.

Understood. Let me know when it is ok.

@ghisvail
Copy link
Contributor Author

Just as an FYI, Debian will be soon entering its freeze period prior to its next stable release (in a couple of months). So, if you guys wish to have globjects packaged for Debian too, you might want to consider not delaying the release by too much so it leaves me time to work on it.

@scheibel
Copy link
Member

We expected a freeze in January 2017.
And you're right, we want to get both glbinding and globjects in the next Debian release.
Thanks for hinting; we'll re-priorize our work.

@scheibel
Copy link
Member

scheibel commented Oct 4, 2016

This issue is currently under review in cmake-init (cginternals/cmake-init#40).
Thus, the next cmake-init update for glbinding contains the feature.

@ghisvail
Copy link
Contributor Author

ghisvail commented Nov 7, 2016

Just as an FYI, globjects has just been accepted to the Debian archive and will be provided via the experimental channel for now, since you guys mentioned v0.5.0 was not fully stable yet. Once you guys have a release you consider stable enough, feel free to ping me and I'll transition the updated version of the package to unstable alongside glbinding.

Builds for all supported architectures can be monitored here. So far, the x86 and ppc families of architectures built and tested fine.

@scheibel
Copy link
Member

scheibel commented Nov 10, 2016

Thanks for the update, we're currently preparing all assets for the release (installer, documentation, press articles, demos, project health checks, ...).

@scheibel
Copy link
Member

@ghisvail We officially released globjects 1.0. Please let us know if anything hinders deployment on Debian.
The deployment issues you opened for glbinding are under development and testing from our side and after we finish them we apply them to globjects as well.

@ghisvail
Copy link
Contributor Author

Brilliant. I refreshed the Debian packaging and found no issues.

@scheibel
Copy link
Member

I updated the cmake-init project setup for glbinding and we now have a separate CMake project for the tests.

If you or anyone else want to try the tests in a completely different environment than the glbinding source directory from the repository, the cmake directory from the project root has to be copied into the external tests directory. Further, you have to explicitly tell CMake where to find the glbinding configure script (e.g., using the CMAKE_PREFIX_PATH or the glbinding_DIR environment variables).

@ghisvail
Copy link
Contributor Author

the cmake directory from the project root has to be copied into the external tests directory.

Ok

you have to explicitly tell CMake where to find the glbinding configure script (e.g., using the CMAKE_PREFIX_PATH or the glbinding_DIR environment variables)

Assuming the CMake config package is installed in the appropriate system location, it should be picked up automatically.

That's exactly the solution I expected. Thanks for rolling it out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants