From: Ralf Habacker Date: Tue, 9 Nov 2021 23:49:21 +0000 (+0100) Subject: cmake: fix find_package related naming mismatch for GLIB2 X-Git-Tag: dbus-1.13.20~34^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dccd628321b9f47ab0971f059c0f6baf74a843e7;p=thirdparty%2Fdbus.git cmake: fix find_package related naming mismatch for GLIB2 The package name passed to `find_package_handle_standard_args` (GLIB2) did not match the name of the calling package (GLib2). This could lead to problems when calling code that expects `find_package`. result variables (e.g. `_FOUND`) expect to follow a certain pattern. fixes #319 --- diff --git a/CMakeLists.txt b/CMakeLists.txt index d86b8ac46..dc5d60d67 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -191,7 +191,7 @@ endif() find_package(EXPAT) find_package(X11) -find_package(GLib2) +find_package(GLIB2) if(GLIB2_FOUND) option(DBUS_WITH_GLIB "build with glib" ON) endif() diff --git a/cmake/modules/FindGLib2.cmake b/cmake/modules/FindGLIB2.cmake similarity index 100% rename from cmake/modules/FindGLib2.cmake rename to cmake/modules/FindGLIB2.cmake