Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Package configuration with Portage: indepth exploration
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
gzoumix
n00b
n00b


Joined: 22 Dec 2017
Posts: 14

PostPosted: Sat Dec 23, 2017 1:07 am    Post subject: Package configuration with Portage: indepth exploration Reply with quote

I recently explored in detail the mechanisms portage uses for configuring the core data of a package: its USE flag and visibility (keywords, mask, license).
I didn't see any documentation on the wiki or anywhere compiling this data, so I had a go at it: https://github.com/HyVar/gentoo_to_mspl/blob/master/PORTAGE.md

I'm sure this document can be greatly improved and suggestions for enhancement are very welcome.
Also, I wrote this document on Github for convenience, I will put it on the wiki as soon as possible.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31288
Location: here

PostPosted: Sat Dec 23, 2017 11:33 am    Post subject: Reply with quote

First welcome to gentoo forum!

You have see this documentation
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
gzoumix
n00b
n00b


Joined: 22 Dec 2017
Posts: 14

PostPosted: Sat Dec 23, 2017 1:37 pm    Post subject: Reply with quote

fedeliallalinea wrote:
First welcome to gentoo forum!


Thank you

fedeliallalinea wrote:
You have see this documentation


Yes, and indeed this documentation contains much information on package configuration.
However, it is not very clear on which are the data contained in a package, which are configurable, and how portage, not only the user, configures them.
For instance, I discovered that the package IUSE is extended by portage and can be extended by the user (such extension is useless, but possible).
I also discovered that package configuration is done by portage in 7 steps (/etc/portage being just one of them), executed in the order defined in the USE_ORDER variable.
This variable is documented in https://dev.gentoo.org/%7Ezmedico/portage/doc/man/make.conf.5.html and https://wiki.gentoo.org/wiki/USE_ORDER but it took me some time to find this information.

The document I wrote is thus a compilation of many information scattered in manpages and the wiki, trying to give a complete overview of how portage configures its packages.
I didn't find a clear documentation for some information, like how the USE flags are declared in a profile, and I looked it up in portage's implementation.

I guess my document can be interesting for anyone who wants to have a global and detailed overview of portage's package configuration mechanisms.
For me, I needed to compile this document for my project of an alternative dependency solver for emerge.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31288
Location: here

PostPosted: Sat Dec 23, 2017 1:57 pm    Post subject: Reply with quote

I haven't read yet your document in detail, but is very interesting.
In my opinion the document mix user and developer concepts making it difficult reading for "new users".
Indeed in wiki usually is for user and devmanual for developer.
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
gzoumix
n00b
n00b


Joined: 22 Dec 2017
Posts: 14

PostPosted: Sun Jan 07, 2018 11:20 pm    Post subject: Reply with quote

fedeliallalinea wrote:
I haven't read yet your document in detail, but is very interesting.
In my opinion the document mix user and developer concepts making it difficult reading for "new users".
Indeed in wiki usually is for user and devmanual for developer.


Do you think I should remove the part about the user concerns, refactor the more technical part that goes in depth into the portage configuration mechanism and submit it to the devmanual?
Do you have suggestions for improving the terminology I use?

Also, I would be very interested to know the motivation behind some design choices in the portage configuration mechanism, like why using make.defaults to declare USE flags instead of an eclass, why use.force/use.mask are necessary, why the syntax for keywords is a bit ambiguous, etc. I think having such information in a document would be very useful to understand portage's configuration mechanism, its complexity and how it can be improved.
Does anyone have information on these topics?

Finally, I recently discovered the portage specification: I should compare it to my document...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum