Signed-off-by: Göktürk Yüksek <gokt...@binghamton.edu> --- ebuild-writing/misc-files/metadata/text.xml | 50 +++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+)
diff --git a/ebuild-writing/misc-files/metadata/text.xml b/ebuild-writing/misc-files/metadata/text.xml index 3d135a6..486af11 100644 --- a/ebuild-writing/misc-files/metadata/text.xml +++ b/ebuild-writing/misc-files/metadata/text.xml @@ -549,6 +549,56 @@ is demonstrated. </body> </subsubsection> +<subsubsection> +<title>Slots and Subslots</title> +<body> + +<p> +The main focus of this example is to demonstrate how slots and +subslots are specified, by examining the metadata of +<path>media-libs/libpng</path>. There may be multiple reasons for +slotting depending on the nature of the package. For this particular +package, it can be seen that the slots are used to provide different +versions of the library with varying binary compatibility and that +developers are advised to build against the slot 0. Furthermore, +different versions of this package with the same subslot provide the +same Application Binary Interface (ABI), according to the description +specified in the <c><subslots></c> tag. +</p> + +<codesample lang="sgml"> +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>base-sys...@gentoo.org</email> + <name>Gentoo Base System</name> + </maintainer> + <use> + <flag name="apng">support unofficial APNG (Animated PNG) spec</flag> + </use> + <upstream> + <remote-id type="cpe">cpe:/a:libpng:libpng</remote-id> + <remote-id type="sourceforge">apng</remote-id> + </upstream> + <slots> + <slot name="0"> + For building against. This is the only slot + that provides headers and command line tools. + </slot> + <slot name="1.2"> + For binary compatibility, provides libpng12.so.0 only. + </slot> + <slot name="1.5"> + For binary compatibility, provides libpng15.so.15 only. + </slot> + <subslots>Reflect ABI compatibility for libpng.so.</subslots> + </slots> +</pkgmetadata> +</codesample> + +</body> +</subsubsection> </body> </subsection> <subsection> -- 2.7.3