From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: Marcus Hoffmann <buildroot@bubu1.eu>
Cc: James Hilliard <james.hilliard1@gmail.com>,
Marcus Hoffmann <bubu@bubu1.eu>,
buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH v2] package/python-diskcache: new package
Date: Tue, 21 Oct 2025 13:41:03 +0200 [thread overview]
Message-ID: <20251021134103.6f1e6693@windsurf> (raw)
In-Reply-To: <4b8956d4-d402-46d6-a20b-0c380b032598@bubu1.eu>
On Tue, 21 Oct 2025 13:31:14 +0200
Marcus Hoffmann <buildroot@bubu1.eu> wrote:
> This was, unfortunately, a very common pattern in setup.py builds but
> it's going away with projects switching to declarative build definitions
> via pyproject.toml. (Which diskcache hasn't done yet, but I assume will
> do eventually, maintenance is a bit slow currently). setup.py is just a
> python script and python allows importing modules from $CWD, even if
> they are not installed. That's how that works in general.
>
> Now I was confused why past me claimed that the same doesn't work inside
> the buildroot build and the reason for that is that host-python3 doesn't
> build with sqlite support, so the diskcache import (at build-time) fails.
>
> Perhaps a less hacky, but also more wasteful, approach to solving this
> is enforcing host-python sqlite support is built when diskcache is
> selected. I just tested that and it works, unsure what approach to chose
> now. WDYT?
Sounds "meh" to me, because important diskcache during the build is
actually... useless, it's just used to retrieve the version number,
which certainly could be done another way. Having to build host-sqlite,
and sqlite support in host-python just for the sake of doing this seems
really wasteful, and is generally not a approach that would work well:
imagine something more complex than diskcache, that has more
dependencies. It means we would have not only to package these
dependencies for the target, but also for the host, just for the sake
of being able to retrieve <foo>.version? Seems not very efficient to me.
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
next prev parent reply other threads:[~2025-10-21 11:41 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-21 9:35 [Buildroot] [PATCH v2] package/python-diskcache: new package Marcus Hoffmann via buildroot
2025-10-21 9:40 ` Marcus Hoffmann via buildroot
2025-10-21 10:16 ` Thomas Petazzoni via buildroot
2025-10-21 11:31 ` Marcus Hoffmann via buildroot
2025-10-21 11:41 ` Thomas Petazzoni via buildroot [this message]
2025-10-21 12:07 ` Marcus Hoffmann via buildroot
-- strict thread matches above, loose matches on Subject: below --
2025-02-26 12:20 Marcus Hoffmann 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=20251021134103.6f1e6693@windsurf \
--to=buildroot@buildroot.org \
--cc=bubu@bubu1.eu \
--cc=buildroot@bubu1.eu \
--cc=james.hilliard1@gmail.com \
--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