Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Portage & Programming
  • Search

dev-libs/boost removal of static-libs

Problems with emerge or ebuilds? Have a basic programming question about C, PHP, Perl, BASH or something else?
Post Reply
Advanced search
7 posts • Page 1 of 1
Author
Message
lisyarus
n00b
n00b
Posts: 1
Joined: Sun Dec 19, 2021 9:45 am

dev-libs/boost removal of static-libs

  • Quote

Post by lisyarus » Sun Dec 19, 2021 9:57 am

Today I learned that the static-libs use flag was removed for dev-libs/boost-1.77 and higher. Boost officially supports building and linking its static version, and many people (myself included) use that for various purposes.

There's already a bug reported with a status of RESOLVED WONTFIX. The dev-libs/boost maintainer just says that the flag won't be restored, explaining his decision with a link to gentoo policy guide which, however, doesn't explain anything: the guide says
If both shared and static libraries are supported, shared libraries must be installed by default and USE=static-libs may be added for static libraries if they are necessary.
and I don't see how does this justify the removal of this use flag.

As other users in the linked bug already said, I feel that this removal goes against the main advantage of gentoo, which is the amount of choice it provides. Is there anything that can be done to return the flag to the official gentoo repository? Surely I could make an overlay or just build Boost locally, but then what's the point.
Top
sam_
Developer
Developer
User avatar
Posts: 2814
Joined: Fri Aug 14, 2020 12:33 am

  • Quote

Post by sam_ » Sun Dec 19, 2021 11:21 am

Because it's not necessary for any package in the Gentoo repository, is the reasoning.

Package maintainers are allowed to decide what they will/won't support bugs for.
Top
Anon-E-moose
Watchman
Watchman
User avatar
Posts: 6566
Joined: Fri May 23, 2008 7:31 pm
Location: Dallas area

  • Quote

Post by Anon-E-moose » Sun Dec 19, 2021 12:55 pm

So make a local ebuld and modify to re-add the static libs, not that difficult
UM780 xtx, 6.18 zen kernel, gcc 15, openrc, wayland
minixforum m1-s1 max -- same software as above but used for ai learning


Zealots are gonna be zealots, just like haters are gonna be haters
Top
Hu
Administrator
Administrator
Posts: 24385
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Sun Dec 19, 2021 5:43 pm

With the caveat that I generally dislike static linking where avoidable, I think the maintainer could have handled this a bit better on the communications front. I pulled the Gentoo git history for this package, and found that the first ebuild of boost-1.77 already lacked IUSE=static-libs. I see no comment in the ebuild, nor in the git log message, explaining the absence. The response in the bug report is likewise uninformative. sam_'s comment seems like a reasonable explanation, and in my opinion, it would have been nice if that was put in git, in the response to the bug, or both. Similarly, it would have been helpful if the maintainer had expressed a position on whether IUSE=static-libs could be restored, such as:
  • I lack the resources (time, experience, etc.) to support this flag. I would put it back if I could support it.
  • I don't want to support this flag, but if someone else wants to support it, they are welcome to enable it in Portage.
  • I think this flag is a bad idea, and I object to anyone adding it back to this package.
  • I believe this flag has these problems (list some here), and they need to be addressed before this flag can be added again.
Without a position statement, it's unclear whether users should live with the absence, try to convince the existing maintainer to support it, or try to find a new maintainer to support it.
Top
mike155
Advocate
Advocate
Posts: 4438
Joined: Fri Sep 17, 2010 11:33 pm
Location: Frankfurt, Germany

  • Quote

Post by mike155 » Sun Dec 19, 2021 5:50 pm

Interesting!

The Gentoo Guidelines say:
Installation of static libraries

Packages must not install static libraries unless they are explicitly required, either by themselves or their reverse dependencies. If both shared and static libraries are supported, shared libraries must be installed by default and USE=static-libs may be added for static libraries if they are necessary.

Rationale: static linking is strongly discouraged as it makes security support for packages practically impossible. It may be used whenever really necessary (e.g. for recovery tools) but otherwise proliferating it is considered harmful. There is no point in installing static libraries if they are never going to be used.
Rust and Go developers prefer quite the opposite: static linking.

Why?

Because dynamic linking is considered harmful and as a source of security and stability bugs.

Who is right?
Top
Ionen
Developer
Developer
User avatar
Posts: 3012
Joined: Thu Dec 06, 2018 2:23 pm

  • Quote

Post by Ionen » Sun Dec 19, 2021 5:57 pm

There's no explanation to do from maintainers, as pointed above avoiding static-libs unless needed by something (can be other reasons, but typically as dependency of static rescue tools, or if upstream is not providing a shared version of the library) is currently policy.

Can agree or disagree with policies and debate them, but there's no reason to complain about maintainers just following them.

Historically it was kept, so there's still a lot of cleanup to do though -- often done at same time as bumps and other changes, not everyone even bothers making a note of it anymore given it's so common.
Top
netfab
Advocate
Advocate
Posts: 2066
Joined: Thu Mar 03, 2005 1:27 pm
Location: 127.0.0.1

  • Quote

Post by netfab » Fri Mar 20, 2026 7:30 pm

I'm discovering this bug today (21 years on Gentoo).

I'm doing C++ development. Today I needed to build a software and link to boost static libraries.
What a surprise to discover that the static-libs useflag was removed without any valid explanation.

I do not understand what is the benefit of removing a working option that is disabled by default.
Now, each time boost libraries will be updated, I will have to remember to patch the ebuild before doing the update.

Anyway, thank you for your work.
Top
Post Reply

7 posts • Page 1 of 1

Return to “Portage & Programming”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic