Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: James Hilliard <james.hilliard1@gmail.com>
Cc: "Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
	"Julien Olivain" <ju.o@free.fr>,
	"Raphaël Mélotte" <raphael.melotte@mind.be>,
	"Asaf Kahlon" <asafka7@gmail.com>,
	buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH 4/6] package/python-swig: new package
Date: Wed, 10 Jan 2024 15:13:22 +0100	[thread overview]
Message-ID: <ZZ6mAgM-c8Rx0Xky@landeda> (raw)
In-Reply-To: <CADvTj4oNQr+v54t4QyTpyN-jvC+DgvyXFmu9io79c3xPJ=Kybw@mail.gmail.com>

James, All,

On 2024-01-10 04:30 -0700, James Hilliard spake thusly:
> On Wed, Jan 10, 2024 at 4:01 AM Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> > On 2024-01-10 02:38 -0700, James Hilliard spake thusly:
> > > Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
> > What's the difference with the swig package we already have?
[--SNIP--]
> >   - can we instead us the existing package/swig to provide the same
> >     functionality as python-swig? I see there is a --enable-python3
> >     flag, at least.
> I don't think so

This is not very assertive...

> since we need to provide the right python package for
> the pep517 build-system.

I don't know what that means.

> >   - if not, then will the two conflict, i.e: will python-swig install
> >     the same set of files as swig does, even partially?
> Didn't seem to cause issues from what I could tell.

Ditto, not very assertive...

> >   - if not, do we need to keep both versions in sync? Currently,
> >     package/swig is still only at 4.1.1.
> Seemed to work so I presume they don't need to be.

But then again, it is not very assertive. The fact that the swig-pypi
project follows the versioning of the swig project is however very
intriguing, if they do in fact not require that they be kept in sync...

So, I had to spend some time looking into the (gory) details of
python-swig. Let's say that this package could be the poster-child of
everything that we do not like much in buildroot:

  - it is a host-python-package, but in fact under the hood it just
    calls cmake

  - which means that host-cmake should be a dependency, as well as
    quite a few others: host-bison, host-pcre2...

  - it *downloads* those dependencies at build time when missing.
    it even tries to download a pre-built bison binary!
    Hey, look, it even downloads swig itself! ;-)

  - it builds those dependencies

At which point I bailed out... All of the above could have been
trivially found by running just this:

    $ make defconfig
    $ make host-swig-configure
    $ make host-swig-build

and looking at the output, which differs quite substantially from the
usual python packages, and thus should have raised some eyebrows...

So, sorry, but this package really needs more investigations.

Regards,
Yann E. MORIN.

> > [0] https://pypi.org/project/swig/
> > [1] https://swig.org/
> > [2] https://github.com/nightlark/swig-pypi
> > [3] https://github.com/swig/swig
> >
> > Regards,
> > Yann E. MORIN.
> >
> > > ---
> > >  package/python-swig/python-swig.hash |  5 +++++
> > >  package/python-swig/python-swig.mk   | 17 +++++++++++++++++
> > >  2 files changed, 22 insertions(+)
> > >  create mode 100644 package/python-swig/python-swig.hash
> > >  create mode 100644 package/python-swig/python-swig.mk
> > >
> > > diff --git a/package/python-swig/python-swig.hash b/package/python-swig/python-swig.hash
> > > new file mode 100644
> > > index 0000000000..d60477f602
> > > --- /dev/null
> > > +++ b/package/python-swig/python-swig.hash
> > > @@ -0,0 +1,5 @@
> > > +# md5, sha256 from https://pypi.org/pypi/swig/json
> > > +md5  c2bf820a545f333d47b7be513baaee3c  swig-4.1.1.post1.tar.gz
> > > +sha256  5cbf2d4dfc413f74cac197704296a9ef065a3f81c7b3792ff11a56d312c4f652  swig-4.1.1.post1.tar.gz
> > > +# Locally computed sha256 checksums
> > > +sha256  73ba74dfaa520b49a401b5d21459a8523a146f3b7518a833eea5efa85130bf68  LICENSE
> > > diff --git a/package/python-swig/python-swig.mk b/package/python-swig/python-swig.mk
> > > new file mode 100644
> > > index 0000000000..89ede170c8
> > > --- /dev/null
> > > +++ b/package/python-swig/python-swig.mk
> > > @@ -0,0 +1,17 @@
> > > +################################################################################
> > > +#
> > > +# python-swig
> > > +#
> > > +################################################################################
> > > +
> > > +PYTHON_SWIG_VERSION = 4.1.1.post1
> > > +PYTHON_SWIG_SOURCE = swig-$(PYTHON_SWIG_VERSION).tar.gz
> > > +PYTHON_SWIG_SITE = https://files.pythonhosted.org/packages/da/b8/d1bfba3d7f75eeca60ecdcb2c214e5cdebb7477437d45db77b6dafee80f9
> > > +PYTHON_SWIG_SETUP_TYPE = setuptools
> > > +PYTHON_SWIG_LICENSE = Apache-2.0
> > > +PYTHON_SWIG_LICENSE_FILES = LICENSE
> > > +HOST_PYTHON_SWIG_DEPENDENCIES = \
> > > +     host-python-scikit-build \
> > > +     host-python-setuptools-scm
> > > +
> > > +$(eval $(host-python-package))
> > > --
> > > 2.34.1
> > >
> > > _______________________________________________
> > > buildroot mailing list
> > > buildroot@buildroot.org
> > > https://lists.buildroot.org/mailman/listinfo/buildroot
> >
> > --
> > .-----------------.--------------------.------------------.--------------------.
> > |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> > | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> > | +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> > | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> > '------------------------------^-------^------------------^--------------------'

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

  reply	other threads:[~2024-01-10 14:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-10  9:38 [Buildroot] [PATCH 1/6] package/mupdf: bump to version 1.23.8 James Hilliard
2024-01-10  9:38 ` [Buildroot] [PATCH 2/6] package/python-distro: add host build James Hilliard
2024-01-10  9:38 ` [Buildroot] [PATCH 3/6] package/python-scikit-build: new package James Hilliard
2024-01-10  9:38 ` [Buildroot] [PATCH 4/6] package/python-swig: " James Hilliard
2024-01-10 11:01   ` Yann E. MORIN
2024-01-10 11:30     ` James Hilliard
2024-01-10 14:13       ` Yann E. MORIN [this message]
2024-01-10 14:15         ` Yann E. MORIN
2024-01-10 23:55         ` James Hilliard
2024-01-10  9:38 ` [Buildroot] [PATCH 5/6] ackage/python-libclang: " James Hilliard
2024-01-10  9:38 ` [Buildroot] [PATCH 6/6] package/python-pymupdf: bump to version 1.23.9rc2 James Hilliard
2024-02-08 11:28   ` Raphaël Mélotte via buildroot
2024-02-08 21:29     ` Arnout Vandecappelle via buildroot
2024-02-09 13:15       ` 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=ZZ6mAgM-c8Rx0Xky@landeda \
    --to=yann.morin.1998@free.fr \
    --cc=asafka7@gmail.com \
    --cc=buildroot@buildroot.org \
    --cc=james.hilliard1@gmail.com \
    --cc=ju.o@free.fr \
    --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