pkgsrc-Bugs archive

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

pkg/58339: cad/kicad fails without wayland being installed



>Number:         58339
>Category:       pkg
>Synopsis:       cad/kicad fails without wayland being installed
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jun 13 01:15:00 +0000 2024
>Originator:     Robert Whitlock
>Release:        pkgsrc current, June 10 2024
>Organization:
>Environment:
NetBSD thinkpad 10.0_STABLE NetBSD 10.0_STABLE (GENERIC) #0: Sun May  5 15:20:02 EDT 2024  rob@thinkpad:/usr/netbsd/10.0/build/generic/obj/sys/arch/amd64/compile/GENERIC amd64
>Description:
cad/kicad fails to build when the wayland option is disabled. kicad's CMakeLists.txt enables support for kicad if the KICAD_USE_EGL CMake option is set, and the pkgsrc Makefile sets the KICAD_USE_EGL option if EGL is available. Since wayland's buildlink file is not included, kicad's build system fails when it tries to build the things that need wayland.
>How-To-Repeat:
Disable the wayland option for cad/kicad.
Try to build kicad.
>Fix:
Add the wayland option to cad/kicad.

Index: options.mk
===================================================================
RCS file: /cvsroot/pkgsrc/cad/kicad/options.mk,v
retrieving revision 1.1
diff -u -r1.1 options.mk
--- options.mk  6 Jun 2023 10:20:58 -0000       1.1
+++ options.mk  13 Jun 2024 01:02:54 -0000
@@ -1,7 +1,7 @@
 # $NetBSD: options.mk,v 1.1 2023/06/06 10:20:58 bouyer Exp $
 
 PKG_OPTIONS_VAR=       PKG_OPTIONS.kicad
-PKG_SUPPORTED_OPTIONS= ng-spice 
+PKG_SUPPORTED_OPTIONS= ng-spice wayland
 PKG_SUGGESTED_OPTIONS= ng-spice 
 
 .include "../../mk/bsd.options.mk"
@@ -12,3 +12,16 @@
 .else
 CMAKE_ARGS+=           -DKICAD_SPICE=OFF
 .endif
+
+.if !empty(PKG_OPTIONS:Mwayland)
+.  include "../../devel/wayland/buildlink3.mk"
+CMAKE_ARGS+=   -DKICAD_WAYLAND=ON
+   # This conditional matches the conditional in Makefile 
+   # so that it's effectively a test for whether
+   # KICAD_USE_EGL is enabled
+.  if empty(MESALIB_SUPPORTS_EGL:Myes)
+PKG_FAIL_REASON+= "Kicad requires the KICAD_USE_EGL CMake option when using the KICAD_WAYLAND CMake option. See the cmake_dependent_option() for KICAD_WAYLAND in CMakeLists.txt"
+.  endif
+.else
+CMAKE_ARGS+=   -DKICAD_WAYLAND=OFF
+.endif



Home | Main Index | Thread Index | Old Index