Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 446740 - EAPI5 subslots should be described in devmanual slotting and dependency sections
Summary: EAPI5 subslots should be described in devmanual slotting and dependency sections
Status: RESOLVED FIXED
Alias: None
Product: Documentation
Classification: Unclassified
Component: Devmanual (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo Devmanual Team
URL:
Whiteboard:
Keywords: PATCH, REVIEWED
Depends on:
Blocks:
 
Reported: 2012-12-10 14:30 UTC by Alexandre Rostovtsev (RETIRED)
Modified: 2013-01-19 10:21 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
proposed patch (0001-general-concepts-dependencies-slotting-document-EAPI.patch,4.69 KB, patch)
2012-12-10 14:31 UTC, Alexandre Rostovtsev (RETIRED)
Details | Diff
proposed patch, v2 (0001-dependencies-slotting-eapi-improve-sub-slot-and-slot.patch,8.16 KB, patch)
2012-12-11 07:05 UTC, Alexandre Rostovtsev (RETIRED)
Details | Diff
proposed patch, v3 (0001-dependencies-slotting-eapi-improve-sub-slot-and-slot.patch,8.58 KB, patch)
2012-12-28 04:45 UTC, Alexandre Rostovtsev (RETIRED)
Details | Diff
proposed patch, v4 (0001-dependencies-slotting-eapi-improve-sub-slot-and-slot.patch,9.40 KB, patch)
2012-12-29 02:49 UTC, Alexandre Rostovtsev (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-10 14:30:06 UTC
As pointed out by Jeroen Roovers, the devmanual currently documents EAPI5-style subslots and slot operators in the EAPI description section, but doesn't mention them at all e.g. in the slotting and dependency syntax section, where a new developer would probably expect to look for them.

IMHO, the slotting and dependency sections should have some reasonable explanation of what subslots are and why you might want to use them.
Comment 1 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-10 14:31:44 UTC
Created attachment 331962 [details, diff]
proposed patch
Comment 2 Pacho Ramos gentoo-dev 2012-12-10 20:06:46 UTC
(In reply to comment #1)
> Created attachment 331962 [details, diff] [details, diff]
> proposed patch

Thanks for the patch

Would be possible to also add some examples to the section in:
http://devmanual.gentoo.org/ebuild-writing/eapi/index.html

I use that page a lot for remember how to properly use new eapis functions and I think and example about subslotting would be really nice
Comment 3 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-11 07:05:28 UTC
Created attachment 332030 [details, diff]
proposed patch, v2

(In reply to comment #2)
> Would be possible to also add some examples to the section in:
> http://devmanual.gentoo.org/ebuild-writing/eapi/index.html

Sure.

I also changed some phrasings in the current "dependency atom slot operators" section a bit to be more clear and less PMS-like, and rewrote my proposed addition to the "dependency" chapter to use terminology more consistently.
Comment 4 Arfrever Frehtes Taifersar Arahesis 2012-12-11 09:48:39 UTC
(In reply to comment #3)

The last hunk contains this sentence:
"Currently portage will accept an arbitrary string for the value of <c>SLOT</c>."

It is actually wrong. Portage accepts SLOT, which matches the following regular expression:
- In EAPI <5:
    r'^([\w+][\w+.-]*)$'
- In EAPI >=5:
    r'^([\w+][\w+.-]*)(/([\w+][\w+.-]*))?$'
Comment 5 Markos Chandras (RETIRED) gentoo-dev 2012-12-24 16:57:27 UTC
Can we have an updated patch please?
Comment 6 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-28 04:45:11 UTC
Created attachment 333548 [details, diff]
proposed patch, v3

(In reply to comment #5)
> Can we have an updated patch please?

Sure.
Comment 7 Arfrever Frehtes Taifersar Arahesis 2012-12-28 08:17:02 UTC
:SLOT/SUBSLOT also should be described. This can be useful in prebuilt packages (e.g. app-office/libreoffice-bin).
Comment 8 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-28 20:13:47 UTC
(In reply to comment #7)
> :SLOT/SUBSLOT also should be described. This can be useful in prebuilt
> packages (e.g. app-office/libreoffice-bin).

Should it be :SLOT/SUBSLOT or :SLOT/SUBSLOT= (and is there a difference between them)?
Comment 9 Arfrever Frehtes Taifersar Arahesis 2012-12-29 01:01:00 UTC
When ebuild of dev-libs/A-0 sets RDEPEND="dev-libs/B:*", then after installation /var/db/pkg/dev-libs/A-0/RDEPEND will contain "dev-libs/B:*".

When ebuild of dev-libs/A-0 sets RDEPEND="dev-libs/B:C/D", then after installation /var/db/pkg/dev-libs/A-0/RDEPEND will contain "dev-libs/B:C/D".

When ebuild of dev-libs/A-0 sets RDEPEND="dev-libs/B:=", then after installation /var/db/pkg/dev-libs/A-0/RDEPEND will contain "dev-libs/B:SLOT/SUBSLOT=".

When ebuild of dev-libs/A-0 sets RDEPEND="dev-libs/B:C=", then after installation /var/db/pkg/dev-libs/A-0/RDEPEND will contain "dev-libs/B:C/SUBSLOT=".

Ebuilds cannot use ":SLOT/SUBSLOT=" in dependencies. (`ebuild ${ebuild} manifest` prints 'Improper context for slot-operator "built" atom syntax' error.)
Comment 10 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-12-29 02:49:28 UTC
Created attachment 333646 [details, diff]
proposed patch, v4

(In reply to comment #9)

Thanks for the explanation! I've updated the patch to document the :SLOT/SUBSLOT syntax.
Comment 11 Markos Chandras (RETIRED) gentoo-dev 2012-12-29 14:30:01 UTC
(In reply to comment #10)
> Created attachment 333646 [details, diff] [details, diff]
> proposed patch, v4
> 
> (In reply to comment #9)
> 
> Thanks for the explanation! I've updated the patch to document the
> :SLOT/SUBSLOT syntax.

I am not that familiar with SUBSLOTS etc, but the patch looks good to me. We can always add more stuff in the future
Comment 12 Markos Chandras (RETIRED) gentoo-dev 2013-01-19 10:21:19 UTC
(In reply to comment #10)
> Created attachment 333646 [details, diff] [details, diff]
> proposed patch, v4
> 
> (In reply to comment #9)
> 
> Thanks for the explanation! I've updated the patch to document the
> :SLOT/SUBSLOT syntax.

http://git.overlays.gentoo.org/gitweb/?p=proj/devmanual.git;a=commit;h=9c3bba54f96fc96c0f3e4929b3bc84a3d84d0aa9

I also fixed the commit message as it was too long. Please try to keep it below <=72 characters in the future

Thank you!