pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/devel/cmake



Module Name:    pkgsrc
Committed By:   rhialto
Date:           Sun Oct  9 12:06:05 UTC 2022

Modified Files:
        pkgsrc/devel/cmake: Makefile distinfo
Added Files:
        pkgsrc/devel/cmake/patches: patch-Modules_FindOpenGL.cmake

Log Message:
devel/cmake: add patch to Modules/FindOpenGL

In order to use libEGL, it looks for libOpenGL, but NetBSD and pkgsrc's
MesaLib don't have that, they have libGL instead. This causes issues in
x11/wxGTK32. See
https://github.com/wxWidgets/wxWidgets/issues/22841
https://gitlab.kitware.com/cmake/cmake/-/issues/24019


To generate a diff of this commit:
cvs rdiff -u -r1.198 -r1.199 pkgsrc/devel/cmake/Makefile
cvs rdiff -u -r1.200 -r1.201 pkgsrc/devel/cmake/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/devel/cmake/patches/patch-Modules_FindOpenGL.cmake

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/devel/cmake/Makefile
diff -u pkgsrc/devel/cmake/Makefile:1.198 pkgsrc/devel/cmake/Makefile:1.199
--- pkgsrc/devel/cmake/Makefile:1.198   Mon Aug 22 19:08:10 2022
+++ pkgsrc/devel/cmake/Makefile Sun Oct  9 12:06:05 2022
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.198 2022/08/22 19:08:10 adam Exp $
+# $NetBSD: Makefile,v 1.199 2022/10/09 12:06:05 rhialto Exp $
 
 .include "Makefile.common"
 
+PKGREVISION=   1
 COMMENT=       Cross platform make
 
 USE_TOOLS+=            gmake

Index: pkgsrc/devel/cmake/distinfo
diff -u pkgsrc/devel/cmake/distinfo:1.200 pkgsrc/devel/cmake/distinfo:1.201
--- pkgsrc/devel/cmake/distinfo:1.200   Mon Sep 26 13:37:32 2022
+++ pkgsrc/devel/cmake/distinfo Sun Oct  9 12:06:05 2022
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.200 2022/09/26 13:37:32 adam Exp $
+$NetBSD: distinfo,v 1.201 2022/10/09 12:06:05 rhialto Exp $
 
 BLAKE2s (cmake-3.24.2.tar.gz) = b863499a7acf9e8d88ed73bc34c5df8232f9df3461b6de3488541452fafab9af
 SHA512 (cmake-3.24.2.tar.gz) = 6f0e8e29bf0336f555ba72c4d83f35d820f8a5159cc999d48795dc57a6627b4ee3966dda84ca97d39906e35dd476ea00cf80023672cc0fad862e2996194c0674
@@ -10,6 +10,7 @@ SHA1 (patch-Modules_FindBLAS.cmake) = 08
 SHA1 (patch-Modules_FindCurses.cmake) = 98cac805a6abafcfb8b61e441b50a1d6aec27ad0
 SHA1 (patch-Modules_FindGTK2.cmake) = 51b7520d35fdec2a7bfcf494fe35ce0e3863e4ee
 SHA1 (patch-Modules_FindLAPACK.cmake) = ded20237fdc8b3e9c488102367c0ee33713c21be
+SHA1 (patch-Modules_FindOpenGL.cmake) = 365d422b50a1b1279cab04a8fd11e05633f52833
 SHA1 (patch-Modules_FindPythonInterp.cmake) = d1b39bdcd654f2a4fc63463cd20de656cce3cf8f
 SHA1 (patch-Modules_FindPythonLibs.cmake) = b5cedc6a2354beaf08e06d416c150154a7dc1f05
 SHA1 (patch-Modules_FindPython_Support.cmake) = aaec7767cad795dd269c851bd110ccefbfc87eb3

Added files:

Index: pkgsrc/devel/cmake/patches/patch-Modules_FindOpenGL.cmake
diff -u /dev/null pkgsrc/devel/cmake/patches/patch-Modules_FindOpenGL.cmake:1.1
--- /dev/null   Sun Oct  9 12:06:05 2022
+++ pkgsrc/devel/cmake/patches/patch-Modules_FindOpenGL.cmake   Sun Oct  9 12:06:05 2022
@@ -0,0 +1,31 @@
+$NetBSD: patch-Modules_FindOpenGL.cmake,v 1.1 2022/10/09 12:06:05 rhialto Exp $
+
+Despite complicated wording in the module, pkgsrc's MesaLib has no libOpenGL
+but does have (conditionally) libGL. Possibly all conditions and dependencies
+on (Open)GL should even be removed here.
+
+https://github.com/wxWidgets/wxWidgets/issues/22841
+https://gitlab.kitware.com/cmake/cmake/-/issues/24019
+
+--- Modules/FindOpenGL.cmake.orig      2022-08-17 16:54:57.000000000 +0000
++++ Modules/FindOpenGL.cmake
+@@ -520,7 +520,9 @@ if(OPENGL_FOUND)
+   # Note we test for OpenGL::OpenGL as a target.  When this module is updated to
+   # support GLES, we would additionally want to check for the hypothetical GLES
+   # target and enable EGL if either ::GLES or ::OpenGL is created.
+-  if(TARGET OpenGL::OpenGL AND OpenGL_EGL_FOUND AND NOT TARGET OpenGL::EGL)
++  # Pkgsrc note: despite complicated wording above, pkgsrc's MesaLib
++  # has no libOpenGL but does have (conditionally) libGL.
++  if(TARGET OpenGL::GL AND OpenGL_EGL_FOUND AND NOT TARGET OpenGL::EGL)
+     if(IS_ABSOLUTE "${OPENGL_egl_LIBRARY}")
+       add_library(OpenGL::EGL UNKNOWN IMPORTED)
+       set_target_properties(OpenGL::EGL PROPERTIES IMPORTED_LOCATION
+@@ -531,7 +533,7 @@ if(OPENGL_FOUND)
+                             "${OPENGL_egl_LIBRARY}")
+     endif()
+     set_target_properties(OpenGL::EGL PROPERTIES INTERFACE_LINK_LIBRARIES
+-                          OpenGL::OpenGL)
++                          OpenGL::GL)
+     # Note that EGL's include directory is different from OpenGL/GLX's!
+     set_target_properties(OpenGL::EGL PROPERTIES INTERFACE_INCLUDE_DIRECTORIES
+                           "${OPENGL_EGL_INCLUDE_DIR}")



Home | Main Index | Thread Index | Old Index