Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 02 Apr 2023 06:13:15 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 270594] textproc/fcitx5 ignores the options
Message-ID:  <bug-270594-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D270594

            Bug ID: 270594
           Summary: textproc/fcitx5 ignores the options
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: khng@freebsd.org
          Reporter: hellomao@outlook.com
             Flags: maintainer-feedback?(khng@freebsd.org)
          Assignee: khng@freebsd.org

Created attachment 241256
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D241256&action=
=3Dedit
The patch to the Makefile in textproc/fcitx5

textproc/fcitx5 port provides three options ENCHANT, WAYLAND, and X11. If I
explicitly mark WAYLAND or X11 off, the build still look for WAYLAND or X11=
 and
fails if they doesn't exist.

Repro steps:
1. Make WAYLAND off. For example, below is the config I'm using
```
fcitx5 $ sudo make showconfig
Password:
=3D=3D=3D> The following configuration options are available for fcitx5-5.0=
.11_2:
     ENCHANT=3Don: Dictionary/spellchecking framework
     WAYLAND=3Doff: Wayland (graphics) support
     X11=3Don: X11 (graphics) support
=3D=3D=3D> Use 'make config' to modify these settings
```

2. Build it (the machine must not have wayland install)
Here is the error
```
-- Could NOT find Wayland_Client (missing: Wayland_Client_LIBRARY
Wayland_Client_INCLUDE_DIR) (found version "") -- Could NOT find Wayland_Egl
(missing: Wayland_Egl_LIBRARY Wayland_Egl_INCLUDE_DIR Wayland_Client_FOUND)
(found version "") CMake Error at
/usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:230
(message): Could NOT find Wayland (missing: Wayland_LIBRARIES Client Egl) C=
all
Stack (most recent call first):

/usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:594
(_FPHSA_FAILURE_MESSAGE)
/usr/local/share/ECM/find-modules/FindWayland.cmake:110
(find_package_handle_standard_args) CMakeLists.txt:157 (find_package)

-- Configuring incomplete, errors occurred!
```

Root Cause

fcitx5 source code uses the options `ENABLE_X11` and `ENABLE_WAYLAND`. As s=
hown
in the code at https://github.com/fcitx/fcitx5/blob/master/CMakeLists.txt
Here is the code snippet
```
option(ENABLE_X11 "Enable X11 support" On)
option(ENABLE_WAYLAND "Enable wayland support" On)
```

By default FreeBSD port convert the option using the option name. fcitxt5
source code has "ENABLE_" before the name. So neither ENABLE_X11 or
ENABLE_WAYLAND is set and they're always "On" even if I mark them off in
FreeBSD port.

I added the following two lines in the Makefile in the port and it builds
without WAYLAND
```
X11_CMAKE_BOOL=3D         ENABLE_X11
WAYLAND_CMAKE_BOOL=3D     ENABLE_WAYLAND
```
I also attach the diff of the Makefile for the port textproc/fcitx5.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-270594-7788>