这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@stsp
Copy link
Contributor

@stsp stsp commented Dec 24, 2024

This is a minimalistic libelf from here:
https://github.com/arachsys/libelf
It is an actively maintained rip-off from elfutils, called Freestanding libelf.

On Termux it sufficiently reduces build time and the amount of packages, because full elfutils builds debuginfod, which gets in curl, libnghttp3, libsqlite, libsqlite-tcl and many more. libsqlite-tcl brings in the GUI libs! (libxau, libxrender)

libelf-minimal package resolves this mess.

This is a minimalistic libelf from here:
https://github.com/arachsys/libelf
It is an actively maintained rip-off from elfutils, called
Freestanding libelf.

On Termux it sufficiently reduces build time and the amount of
packages, because full elfutils builds debuginfod, which gets in
curl, libnghttp3, libsqlite, libsqlite-tcl and many more. libsqlite-tcl
brings in the GUI libs! (libxau, libxrender)

libelf-minimal package resolves this mess.
@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

This is just something to consider.
Unless the deps are replaced in all libelf-using
packages, this doesn't add much of
the benefit. But it reduces the CI build
time for me, and reduces the amount
of packages that are built for a PR.

I suppose the problem can be solved
also the other way around: if termux
provides the binary packages for
curl, libcurl-static, libcurl, libnghttp3-static,
libnghttp3, libsqlite-static, libsqlite-tcl,
libsqlite, libxau-static, libxau, libxrender-static,
libxrender, sqlite, termux-tools.
Currently these "trash" packages are
being built for any PR that depends on
libelf.

@Biswa96
Copy link
Member

Biswa96 commented Dec 24, 2024

Software distributions do not provide random forks.

@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

I realize that, so it might be an
option to just add a pre-built packages
instead:
#22669

However please note that the current
situation with libelf package in Termux
is sub-optimal, as it builds the entire
huge elfutils project, when some package
just requires libelf!

So if you don't want the fork, it may
be possible to reduce the libelf package
to the actual libelf, rather than entire
elfutils. In fact, this fork does just that:
it simply provides another makefile.
But I suppose the same goal can be
achieved with configure tweaks.

@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

So I can try to achieve the same goal
with configure tweaks, if there are the
hopes to get it in. Otherwise I can use
this fork in my own CI.

@Biswa96
Copy link
Member

Biswa96 commented Dec 24, 2024

it may be possible to reduce the libelf package to the actual libelf

libelf package only contains the libelf shared library. The related programs are already in separate sub-packages.

@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

The related programs are already in separate sub-packages.

This is true.
But the problem is that they are built
when you just have a dep on libelf. And
not only they are built - all their deps
are built as well.
So being in a separate sub-package
doesn't help a tiny bit. If you could
build every sub-package separately,
then that helps, but its not the case.

@twaik
Copy link
Member

twaik commented Dec 24, 2024

This is true.
But the problem is that they are built
when you just have a dep on libelf. And
not only they are built - all their deps
are built as well.

Pass -I or -i flag to ./build-package.sh and all deps will be downloaded instead of being built from sources. Problem solved.

@twaik twaik closed this Dec 24, 2024
@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

The flag is already there, but I
suppose I have version mismatches.
Seems like any non-latest binary
versions are removed, so lets see
if I get the problem solved by just
updating from termux's master...

@twaik
Copy link
Member

twaik commented Dec 24, 2024

The flag is already there, but I
suppose I have version mismatches.

Packages are being updated frequently. Do git pull to update your local version of repo.

Seems like any non-latest binary
versions are removed, so lets see

Correct. We do not keep old versions of packages because of server maintenance and storage costs.

if I get the problem solved by just
updating from termux's master...

It should be solved this way.

@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

It actually did, thanks.
OK, I will remember that not doing
"git pull" leads to this...

Correct. We do not keep old versions of packages because of server maintenance and storage costs.

Could save me some time, if this
wasn't the case.
Thanks for info.

@stsp stsp deleted the libelf branch December 24, 2024 15:23
@TomJo2000
Copy link
Member

One thing to note additionally is that on top of the storage and maintenance demands that keeping multiple versions would impose we don't don't have the capacity to test compatibility between several different package and dependency versions and having to do so would exponentially increase the amount of package breakages or slow package updates down substantially.

@stsp
Copy link
Contributor Author

stsp commented Dec 24, 2024

I hope the only way to get into
such situation, is by not doing
git pull. Which means, you'll
get only the pre-existing
configurations, not some random
mix of old/new builds. So I hope
that could be safe, but as it stands,
I'll just need to put "git pull" into
some script.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants