install-pkgconfig-without-lib-for-cross-compile
authorDebian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
Thu, 8 Feb 2024 16:16:19 +0000 (16:16 +0000)
committerRaspbian forward porter <root@raspbian.org>
Thu, 8 Feb 2024 16:16:19 +0000 (16:16 +0000)
Install architecture independent pkgconfig file in /usr/share/pkgconfig

This prevents lintian warning pkg-config-unavailable-for-cross-compilation
for the header only modules dune-istl, dune-localfunctions, dune-functions,
and dune-typetree.

Gbp-Pq: Name install-pkgconfig-without-lib-for-cross-compile

cmake/modules/DuneProject.cmake

index b8ae398c55f117c5c9c3bd3b63fe1235caf76797..0cf14a9f9914998c52c4b3eb3cacf148f87aedf8 100644 (file)
@@ -224,8 +224,10 @@ endif()")
   get_property(${ProjectName}_LIBRARIES GLOBAL PROPERTY ${ProjectName}_LIBRARIES)
   if(${ProjectName}_LIBRARIES)
     set(DUNE_INSTALL_LIBDIR ${CMAKE_INSTALL_LIBDIR})
+    set(DUNE_INSTALL_PKGCONFIGDIR ${CMAKE_INSTALL_LIBDIR})
   else()
     set(DUNE_INSTALL_LIBDIR ${DUNE_INSTALL_NONOBJECTLIBDIR})
+    set(DUNE_INSTALL_PKGCONFIGDIR ${CMAKE_INSTALL_DATAROOTDIR})
   endif()
 
   # Set the location of the doc file source. Needed by custom package configuration
@@ -302,7 +304,7 @@ endif()
   endif()
 
   # install pkg-config files
-  create_and_install_pkconfig(${DUNE_INSTALL_LIBDIR})
+  create_and_install_pkconfig(${DUNE_INSTALL_PKGCONFIGDIR})
 
   if(${ProjectName}_EXPORT_SET)
     # install library export set