Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: "Raphaël Mélotte via buildroot" <buildroot@buildroot.org>
Cc: "James Hilliard" <james.hilliard1@gmail.com>,
	"Raphaël Mélotte" <raphael.melotte@mind.be>,
	"Asaf Kahlon" <asafka7@gmail.com>
Subject: Re: [Buildroot] [PATCH v2 5/5] package/python-pymupdf: bump to version 1.23.22
Date: Sat, 13 Jul 2024 22:38:23 +0200	[thread overview]
Message-ID: <20240713223823.06f7a5dc@windsurf> (raw)
In-Reply-To: <20240607163208.1445715-5-raphael.melotte@mind.be>

Hello,

On Fri,  7 Jun 2024 18:32:06 +0200
Raphaël Mélotte via buildroot <buildroot@buildroot.org> wrote:

> This new python-pymupdf version fails at runtime when mupdf builds
> static libraries. This should not be possible as xorg anyway depends
> on !BR2_STATIC_LIBS, but let's be explicit and forbid python-pymupdf
> to be built with BR2_STATIC_LIBS as well.

I dropped the last sentence because X.org is no longer a dependency.


> -# python-pymupdf's version must match mupdf's version
> +# python-pymupdf's version be compatible with mupdf's version

*must be*

> diff --git a/package/python-pymupdf/0001-pipcl.py-allow-providing-python-config-externally.patch b/package/python-pymupdf/0001-pipcl.py-allow-providing-python-config-externally.patch
> new file mode 100644
> index 0000000000..2fd72c711e
> --- /dev/null
> +++ b/package/python-pymupdf/0001-pipcl.py-allow-providing-python-config-externally.patch
> @@ -0,0 +1,125 @@
> +From ca3417b8d605ccdb2e6c516c5e0c79180381627c Mon Sep 17 00:00:00 2001
> +From: =?UTF-8?q?Rapha=C3=ABl=20M=C3=A9lotte?= <raphael.melotte@mind.be>
> +Date: Sun, 4 Feb 2024 16:13:45 +0100
> +Subject: [PATCH] pipcl.py: allow providing python-config externally
> +MIME-Version: 1.0
> +Content-Type: text/plain; charset=UTF-8
> +Content-Transfer-Encoding: 8bit
> +
> +When cross-compiling (e.g. using Buildroot), the python-config
> +executable that resides next to the host python executable provides
> +incorrect includes (the ones for the host).
> +
> +Since the correct path to python-config cannot be guessed, add an
> +additional environment variable to allow setting the path to the
> +correct python-config executable externally.
> +
> +Signed-off-by: Raphaël Mélotte <raphael.melotte@mind.be>
> +Upstream: https://github.com/pymupdf/PyMuPDF/pull/3173

I changed this to the final commit, since it got merged upstream!


> diff --git a/package/python-pymupdf/Config.in b/package/python-pymupdf/Config.in
> index 3831a25451..cfdd38ebe4 100644
> --- a/package/python-pymupdf/Config.in
> +++ b/package/python-pymupdf/Config.in
> @@ -4,6 +4,7 @@ config BR2_PACKAGE_PYTHON_PYMUPDF
>  	depends on BR2_TOOLCHAIN_HAS_SYNC_4 # mupdf -> harfbuzz
>  	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # mupdf -> harfbuzz
>  	depends on BR2_PACKAGE_XORG7
> +	depends on !BR2_STATIC_LIBS
>  	select BR2_PACKAGE_HOST_SWIG
>  	select BR2_PACKAGE_FREETYPE
>  	select BR2_PACKAGE_MUPDF

Config.in comment update was missing for the !BR2_STATIC_LIBS dependency.

> -# python-pymupdf's version must match mupdf's version
> -PYTHON_PYMUPDF_VERSION = 1.22.0
> +# python-pymupdf's version be compatible with mupdf's version
> +PYTHON_PYMUPDF_VERSION = 1.23.22
>  PYTHON_PYMUPDF_SOURCE = PyMuPDF-$(PYTHON_PYMUPDF_VERSION).tar.gz
> -PYTHON_PYMUPDF_SITE = https://files.pythonhosted.org/packages/28/ba/d6bb6fd678e8396d7b944870286fb25fd6f499b8cb599b5436c8f725adbf
> -PYTHON_PYMUPDF_SETUP_TYPE = setuptools
> +PYTHON_PYMUPDF_SITE = https://files.pythonhosted.org/packages/05/20/a0d1221d8f379afcc12b4d1687a8f4adb69eef659e835d781c3fa331ff46
> +PYTHON_PYMUPDF_SETUP_TYPE = pep517

This change was actually wrong. Keep "setuptools" is the same as
pep517, except that we don't have to manually add the dependency on
host-python-setuptools. Of course assuming I did not misunderstand the
Python infrastructure :-)

Applied with those changes. Thanks a lot for this series, and sorry for
the time it took to get it merged!

Best regards,

Thomas
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

  reply	other threads:[~2024-07-13 20:38 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-16 21:13 [Buildroot] [PATCH 0/5] package/python-pymupdf: bump to version 1.23.22 Raphaël Mélotte via buildroot
2024-02-16 21:13 ` [Buildroot] [PATCH 1/5] package: python-pymupdf: add missing python-zlib dependency Raphaël Mélotte via buildroot
2024-06-07 16:32   ` [Buildroot] [PATCH v2 " Raphaël Mélotte via buildroot
2024-06-07 16:32     ` [Buildroot] [PATCH v2 2/5] support/testing: add new test for python-pymupdf Raphaël Mélotte via buildroot
2024-07-13 20:35       ` Thomas Petazzoni via buildroot
2024-08-12  9:51         ` Peter Korsgaard
2024-06-07 16:32     ` [Buildroot] [PATCH v2 3/5] package/mupdf: fix building shared libraries Raphaël Mélotte via buildroot
2024-07-13 20:36       ` Thomas Petazzoni via buildroot
2024-08-12  9:14       ` Peter Korsgaard
2024-06-07 16:32     ` [Buildroot] [PATCH v2 4/5] package/mupdf: bump to version 1.23.9 Raphaël Mélotte via buildroot
2024-07-13 20:36       ` Thomas Petazzoni via buildroot
2024-06-07 16:32     ` [Buildroot] [PATCH v2 5/5] package/python-pymupdf: bump to version 1.23.22 Raphaël Mélotte via buildroot
2024-07-13 20:38       ` Thomas Petazzoni via buildroot [this message]
2024-07-13 20:34     ` [Buildroot] [PATCH v2 1/5] package: python-pymupdf: add missing python-zlib dependency Thomas Petazzoni via buildroot
2024-08-12  9:51       ` Peter Korsgaard
2024-02-16 21:13 ` [Buildroot] [PATCH 2/5] support/testing: add new test for python-pymupdf Raphaël Mélotte via buildroot
2024-02-16 21:13 ` [Buildroot] [PATCH 3/5] package/mupdf: fix building shared libraries Raphaël Mélotte via buildroot
2024-04-01 20:06   ` Arnout Vandecappelle via buildroot
2024-06-07 16:44     ` Raphaël Mélotte via buildroot
2024-02-16 21:13 ` [Buildroot] [PATCH 4/5] package/mupdf: bump to version 1.23.9 Raphaël Mélotte via buildroot
2024-02-16 21:13 ` [Buildroot] [PATCH 5/5] package/python-pymupdf: bump to version 1.23.22 Raphaël Mélotte via buildroot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240713223823.06f7a5dc@windsurf \
    --to=buildroot@buildroot.org \
    --cc=asafka7@gmail.com \
    --cc=james.hilliard1@gmail.com \
    --cc=raphael.melotte@mind.be \
    --cc=thomas.petazzoni@bootlin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox