From: Thomas Debesse Date: Thu, 21 Oct 2021 12:11:32 +0000 (+0200) Subject: cmake: fix gtkglex build configuration issues X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=2134e1e306be6bcf12cecf16af539781fa99cc01;p=xonotic%2Fnetradiant.git cmake: fix gtkglex build configuration issues --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 0f766cab..fe345ca4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -374,11 +374,10 @@ if (BUILTIN_GTKGLEXT) set(GTKGLEXT_CFLAGS "$ENV{CFLAGS} ${GTKGLEXT_CFLAGS}") - set(CONFIGURE_OPTIONS --disable-gtk-doc --disable-gtk-doc-html --disable-gtk-doc-pdf - --disable-dependency-tracking --without-x) + set(CONFIGURE_OPTIONS --disable-gtk-doc --disable-gtk-doc-html --disable-gtk-doc-pdf --disable-dependency-tracking --without-x) - if (NOT CMAKE_BUILD_TYPE MATCHES Release) - set(CONFIGURE_OPTIONS "${CONFIGURE_OPTIONS} --disable-debug") + if (CMAKE_BUILD_TYPE MATCHES Release) + set(CONFIGURE_OPTIONS ${CONFIGURE_OPTIONS} --disable-debug) endif () if (APPLE) @@ -388,16 +387,14 @@ if (BUILTIN_GTKGLEXT) endif () if (APPLE) - set(GTKGLEXT_CFLAGS "${GTKGLEXT_CFLAGS} -DGL_SILENCE_DEPRECATION=1") - # FIXME: OpenGL deprecation warnings are not silenced - # in Objective C code. + set(GTKGLEXT_CFLAGS "${GTKGLEXT_CFLAGS} -DGL_SILENCE_DEPRECATION=1 -Wno-deprecated-declarations") endif () ExternalProject_Add(gtkglext GIT_REPOSITORY https://gitlab.gnome.org/illwieckz/gtkglext.git GIT_TAG ${GTKGLEXT_GIT_TAG} BUILD_IN_SOURCE ON - CONFIGURE_COMMAND export CFLAGS=${GTKGLEXT_CFLAGS} + CONFIGURE_COMMAND export CCFLAGS=${GTKGLEXT_CFLAGS} CONFIGURE_COMMAND && export LDFLAGS=${GTKGLEXT_LDFLAGS} CONFIGURE_COMMAND && export NOCONFIGURE=1 CONFIGURE_COMMAND && ./autogen.sh