Quantcast

Platform-independent config package

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Platform-independent config package

Ghislain Vaillant
Dear all,

I am currently hit by an issue with the CMake detection of a header-only library [1]. The library is built on a 64-bit machine and packaged for all other architectures supported by Debian.

However, CMake detection fails on 32-bit platforms with the following error:

```
Any attempt to call `find_package(glm REQUIRED)` produces the following
error:

```
Could not find a configuration file for package "glm" that is
compatible with requested version "".

The following configuration files were considered but not accepted:

    /usr/lib/cmake/glm/glmConfig.cmake, version: 0.9.8 (64bit)
```

How can this be effectively solved? Can the bit-ness detection be dropped somehow? It should not be needed for a header-only target.

Cheers,
Ghis

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Platform-independent config package

Andreas Naumann
Dear Ghis,

the easiest long-term fix would be an own glmConfig.cmake file.
The command write_basic_package_version_file uses a template with those
pointer checks. The glm-developers could simply copy the template to
their source directory, remove the unneeded lines and run the
configure_file command themself on the changed template.

The short solution for debian would be a patch file,which just
uncomments the last 5 lines.

Regards,
Andreas

Am 10.01.2017 um 19:52 schrieb Ghislain Vaillant:

> Dear all,
>
> I am currently hit by an issue with the CMake detection of a
> header-only library [1]. The library is built on a 64-bit machine and
> packaged for all other architectures supported by Debian.
>
> However, CMake detection fails on 32-bit platforms with the following
> error:
>
> ```
> Any attempt to call `find_package(glm REQUIRED)` produces the following
> error:
>
> ```
> Could not find a configuration file for package "glm" that is
> compatible with requested version "".
>
> The following configuration files were considered but not accepted:
>
>     /usr/lib/cmake/glm/glmConfig.cmake, version: 0.9.8 (64bit)
> ```
>
> How can this be effectively solved? Can the bit-ness detection be
> dropped somehow? It should not be needed for a header-only target.
>
> Cheers,
> Ghis
>
>
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=850277
>
>

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Platform-independent config package

Sergiu Dotenco
In reply to this post by Ghislain Vaillant
You can temporarily unset CMAKE_SIZEOF_VOID_P before calling write_basic_package_version_file. See for instance https://bitbucket.org/eigen/eigen/src/ff6170e75ab07d74d8f7dd21af777a94799d168d/CMakeLists.txt?at=3.3&fileviewer=file-view-default#CMakeLists.txt-541:545.

On Tue, Jan 10, 2017 at 7:52 PM, Ghislain Vaillant <[hidden email]> wrote:
Dear all,

I am currently hit by an issue with the CMake detection of a header-only library [1]. The library is built on a 64-bit machine and packaged for all other architectures supported by Debian.

However, CMake detection fails on 32-bit platforms with the following error:

```
Any attempt to call `find_package(glm REQUIRED)` produces the following
error:

```
Could not find a configuration file for package "glm" that is
compatible with requested version "".

The following configuration files were considered but not accepted:

    /usr/lib/cmake/glm/glmConfig.cmake, version: 0.9.8 (64bit)
```

How can this be effectively solved? Can the bit-ness detection be dropped somehow? It should not be needed for a header-only target.

Cheers,
Ghis

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Loading...