[Bug 274815] graphics/mupdf: build and install the python bindings

From: <bugzilla-noreply_at_freebsd.org>
Date: Mon, 30 Oct 2023 15:34:57 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=274815

            Bug ID: 274815
           Summary: graphics/mupdf: build and install the python bindings
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Many People
          Priority: ---
         Component: Individual Port(s)
          Assignee: ports-bugs@FreeBSD.org
          Reporter: bsdpr@phoe.frmug.org
                CC: uzsolt@uzsolt.hu
                CC: uzsolt@uzsolt.hu
             Flags: maintainer-feedback?(uzsolt@uzsolt.hu)

Could it be possible for the mupdf port to build and install the python
bindings? This should be made optional since it would introduce a dependency on
llvm python bindings.

$ cd ~/tmp/mupdf/
$ make extract patch configure
$ cd work/mupdf-1.20.3-source
$ gmake python
[...]
./scripts/mupdfwrap.py -d build/shared-release -b 01
(+0.2s): state.py:33:<module>: Warning: failed to import clang.cindex: e=No
module named 'clang'
(+0.2s): state.py:33:<module>: We need Clang Python to build MuPDF python.
(+0.2s): state.py:33:<module>: Install with "pip install libclang" or use the
--venv option, or:
(+0.2s): state.py:33:<module>:     OpenBSD: pkg_add py3-llvm
(+0.2s): state.py:33:<module>:     Linux:debian/devuan: apt install
python-clang
(+0.4s): -d: __main__.py:1827:main2: Have set build_dirs=<wrap.state.BuildDirs
object at 0x801617040>
(+0.4s): -b: __main__.py:1037:build:
build_dirs.dir_so=/home/elrond/tmp/mupdf/work/mupdf-1.20.3-source/build/shared-release
(+0.4s): -b: 0: __main__.py:1137:build: Generating C++ source code ...
Traceback (most recent call last):
    scripts/mupdfwrap.py:6:<module>(): wrap.__main__.main()
    scripts/wrap/__main__.py:2279:main(): jlib.exception_info()
    ^except raise:
    scripts/wrap/__main__.py:2277:main(): main2()
    scripts/wrap/__main__.py:1724:main2(): build( build_dirs, swig_command,
args)
    scripts/wrap/__main__.py:1139:build(): raise Exception('Cannot do "-b 0"
because failed to import clang.')
Exception: Cannot do "-b 0" because failed to import clang.
gmake: *** [Makefile:505: c++-release] Error 1

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