Skip to content

More flexible handling of GTest in test suite #94

@ghisvail

Description

@ghisvail

Right now, clFFT requires libgtest to be detectable via its corresponding cmake find module.The test suite is then compiled and linked with the available pre-compiled version of libgtest.

This approach contradicts with the official recommendation in [1], which advise to build and use GTest on a per project basis. As a consequence, Debian and other downstream OS only provides the source for GTest instead of a pre-compiled binary of it, in accordance with what upstream recommends.

It would be nice if the build system could be somewhat adapted to use this workflow by:

  • enabling the location of the GTest source directory to be passed as an argument to the build system,
  • performing the build of libgtest with the suitable build flags for the project,
  • linking the existing test suite with the project-wise build of libgtest.

I believe ArrayFire [2] does that properly, although they use git submodules to provide the source for GTest.

Many thanks,

[1] https://code.google.com/p/googletest/wiki/V1_7_FAQ#Why_is_it_not_recommended_to_install_a_pre-compiled_copy_of_Goog
[2] https://github.com/arrayfire/arrayfire/blob/devel/test/CMakeLists.txt

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions