Skip to content

Commit

Permalink
Add internal links to eclass documentation
Browse files Browse the repository at this point in the history
Signed-off-by: Ulrich Müller <ulm@gentoo.org>
  • Loading branch information
ulm committed Dec 7, 2024
1 parent 18a8425 commit 017da21
Show file tree
Hide file tree
Showing 15 changed files with 59 additions and 52 deletions.
5 changes: 3 additions & 2 deletions ebuild-maintenance/package-moves/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,9 @@ and update them. These include:
<ul>
<li>
<uri link="::general-concepts/dependencies/">dependencies</uri>,
<c>optfeature.eclass</c> uses, <c>has_version</c> and <c>best_version</c>
uses in other ebuilds and eclasses
<c><uri link="::eclass-reference/optfeature.eclass/"/></c> uses,
<c>has_version</c> and <c>best_version</c> uses in other ebuilds and
eclasses
</li>
<li>
all <c>profiles/</c> tree entries (e.g. <c>profiles/package.mask</c>)
Expand Down
14 changes: 8 additions & 6 deletions ebuild-writing/common-mistakes/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ There are several ways to fix non-verbose build logs depending on the build syst
<ul>
<li>
For <c>cmake</c>-based build systems, it should be sufficient that the
ebuild calls cmake_src_compile which picks up the cmake.eclass variable
ebuild calls cmake_src_compile which picks up the
<c><uri link="::eclass-reference/cmake.eclass/"/></c> variable
<c>CMAKE_VERBOSE=1</c> by default. If you call emake directly for whatever
reason, you can do <c>emake VERBOSE=1</c> (note that 'cmake_src_compile'
takes arguments as well which are passed to make).
Expand Down Expand Up @@ -183,10 +184,11 @@ To fix the affected build system you should try the following methods:
upstream)
</li>
<li>
use <e>append-flags -Wno-error</e> (needs flag-o-matic.eclass); for this
to work the environment flags have to be respected and placed after build
system flags; this method is not preferred as it will disable all
"-Werror=specific-warning" flags as well, see next section
use <e>append-flags -Wno-error</e>
(needs <c><uri link="::eclass-reference/flag-o-matic.eclass/"/></c>);
for this to work the environment flags have to be respected and placed
after build system flags; this method is not preferred as it will disable
all "-Werror=specific-warning" flags as well, see next section
</li>
</ul>
<p>
Expand Down Expand Up @@ -531,7 +533,7 @@ the ebuild's quality and ease review.
You should not call <c>pkg-config</c> directly in ebuilds because this is
problematic for e.g. cross-compiling. The correct helper respects
<c>${PKG_CONFIG}</c>. Instead, use <c>tc-getPKG_CONFIG</c> from
<c>toolchain-funcs.eclass</c>, e.g.
<c><uri link="::eclass-reference/toolchain-funcs.eclass/"/></c>, for example.
</p>

<codesample lang="ebuild">
Expand Down
3 changes: 2 additions & 1 deletion ebuild-writing/eapi/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1422,7 +1422,8 @@ $(usev foo --enable-foo)

<p>
Packages using these format for distfiles must now unpack them manually.
Using <c>unpacker.eclass</c> is recommended for this.
Using <c><uri link="::eclass-reference/unpacker.eclass/"/></c> is
recommended for this.
</p>
</dd>
</dl>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ functions can be used here.
</codesample>

<p>
See <uri link="::eclass-reference/flag-o-matic.eclass/"/> for a full reference.
See <c><uri link="::eclass-reference/flag-o-matic.eclass/"/></c> for a full
reference.
</p>
</body>
</section>
Expand Down
2 changes: 1 addition & 1 deletion ebuild-writing/functions/src_compile/building/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ some MIPS and SPARC systems.
<p>
Sometimes a package will try to use a bizarre compiler, or will need to be told
which compiler to use. In these situations, the <c>tc-getCC()</c> function from
<uri link="::eclass-reference/toolchain-funcs.eclass/"/> should be used.
<c><uri link="::eclass-reference/toolchain-funcs.eclass/"/></c> should be used.
Other similar functions are available <d/> these are documented in
<c>man toolchain-funcs.eclass</c>.
</p>
Expand Down
4 changes: 2 additions & 2 deletions ebuild-writing/functions/src_compile/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ src_compile() {
</codesample>
<note>
You also need to inherit the
<uri link="::eclass-reference/flag-o-matic.eclass/">flag-o-matic</uri>
eclass in order to use the <c>append-ldflags</c> function.
<c><uri link="::eclass-reference/flag-o-matic.eclass/"/></c> in order to
use the <c>append-ldflags</c> function.
</note>
</li>
</ul>
Expand Down
4 changes: 2 additions & 2 deletions ebuild-writing/functions/src_configure/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ src_configure() {

<note>
You also need to inherit the
<uri link="::eclass-reference/flag-o-matic.eclass/">flag-o-matic</uri>
eclass in order to use the <c>append-ldflags</c> function.
<c><uri link="::eclass-reference/flag-o-matic.eclass/"/></c> in order to use
the <c>append-ldflags</c> function.
</note>

</body>
Expand Down
10 changes: 5 additions & 5 deletions ebuild-writing/functions/src_test/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -256,11 +256,11 @@ src_test() {
</codesample>

<p>
If the package actually requires a running X11 server to run
the complete test suite, you can use the <c>virtualx</c> eclass to
provide an isolated Xvfb environment for the tests to use. It provides
a virtual X11 display that is not connected to any physical device
and that programs can use reliably.
If the package actually requires a running X11 server to run the complete test
suite, you can use the <c><uri link="::eclass-reference/virtualx.eclass/"/></c>
to provide an isolated Xvfb environment for the tests to use. It provides
a virtual X11 display that is not connected to any physical device and that
programs can use reliably.
</p>

<codesample lang="ebuild">
Expand Down
6 changes: 3 additions & 3 deletions ebuild-writing/functions/src_unpack/rpm-sources/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ inherit rpm
</codesample>

<p>
If you don't need to do anything in the unpack phase, then you are
finished as the <c>rpm.eclass</c> exports a default <c>src_unpack</c>
that will unpack the RPM files.
If you don't need to do anything in the unpack phase, then you are finished
as the <c><uri link="::eclass-reference/rpm.eclass/"/></c> exports a default
<c>src_unpack</c> that will unpack the RPM files.
</p>

<p>
Expand Down
10 changes: 5 additions & 5 deletions ebuild-writing/functions/src_unpack/vcs-sources/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ variables.
</p>

<ul>
<li><uri link="::eclass-reference/cvs.eclass/"/></li>
<li><uri link="::eclass-reference/darcs.eclass/"/></li>
<li><uri link="::eclass-reference/git-r3.eclass/"/></li>
<li><uri link="::eclass-reference/mercurial.eclass/"/></li>
<li><uri link="::eclass-reference/subversion.eclass/"/></li>
<li><c><uri link="::eclass-reference/cvs.eclass/"/></c></li>
<li><c><uri link="::eclass-reference/darcs.eclass/"/></c></li>
<li><c><uri link="::eclass-reference/git-r3.eclass/"/></c></li>
<li><c><uri link="::eclass-reference/mercurial.eclass/"/></c></li>
<li><c><uri link="::eclass-reference/subversion.eclass/"/></c></li>
</ul>

<note>
Expand Down
11 changes: 6 additions & 5 deletions ebuild-writing/users-and-groups/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
<p>
Creating users and groups is governed by
<uri link="https://gentoo.org/glep/glep-0081.html">GLEP 81</uri>. It is
implemented via <c>acct-user</c> and <c>acct-group</c> eclasses. New users
and groups are created as packages respectively in <c>acct-user</c> and
<c>acct-group</c> categories.
implemented via <c><uri link="::eclass-reference/acct-user.eclass/"/></c> and
<c><uri link="::eclass-reference/acct-group.eclass/"/></c>. New users and
groups are created as packages in the <c>acct-user</c> and <c>acct-group</c>
categories, respectively.
</p>

<p>
Expand All @@ -32,8 +33,8 @@ Afterwards, you can push the new ebuilds.
</p>

<p>
The historical way of using <c>user.eclass</c> directly is now deprecated
and must not be used for new packages.
The historical way of using <c><uri link="::eclass-reference/user.eclass/"/></c>
directly is now deprecated and must not be used for new packages.
</p>
</body>

Expand Down
13 changes: 6 additions & 7 deletions ebuild-writing/using-eclasses/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,12 @@ Note the <c>inherit</c> immediately after the header.
</p>

<p>
The <c>autotools</c> eclass
(see <uri link="::eclass-reference/autotools.eclass/"/>) is needed to get the
<c>eautoreconf</c> function. The <c>flag-o-matic</c> eclass
(see <uri link="::eclass-reference/flag-o-matic.eclass/"/>) is needed for
<c>replace-flags</c>, and the <c>bash-completion-r1</c> eclass
(<uri link="::eclass-reference/bash-completion-r1.eclass/"/>) is used to handle
the bash completion file via <c>dobashcomp</c>.
The <c><uri link="::eclass-reference/autotools.eclass/"/></c> is needed to get
the <c>eautoreconf</c> function,
the <c><uri link="::eclass-reference/flag-o-matic.eclass/"/></c> is needed for
<c>replace-flags</c>, and the
<c><uri link="::eclass-reference/bash-completion-r1.eclass/"/></c> is used to
handle the bash completion file via <c>dobashcomp</c>.
</p>

</body>
Expand Down
11 changes: 6 additions & 5 deletions general-concepts/autotools/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,12 @@ the <c>configure</c> script to exist.

<p>
The <c>autoreconf</c> tool supposedly runs <c>autoconf</c> (and <c>automake</c>,
<c>autoheader</c>, <c>aclocal</c>, <c>autopoint</c> and <c>libtoolize</c>) as necessary.
Sometimes it works. Some packages ship a shell script named <c>autogen.sh</c> which
does the same thing (this is <e>not</e> related to <c>autogen</c>).
The autotools.eclass contains helper functions for the stand-alone tools with their
corresponding names e.g. <c>eautoconf</c> and <c>eautomake</c>.
<c>autoheader</c>, <c>aclocal</c>, <c>autopoint</c> and <c>libtoolize</c>)
as necessary. Sometimes it works. Some packages ship a shell script named
<c>autogen.sh</c> which does the same thing (this is <e>not</e> related to
<c>autogen</c>). The <c><uri link="::eclass-reference/autotools.eclass/"/></c>
contains helper functions for the stand-alone tools with their corresponding
names e.g. <c>eautoconf</c> and <c>eautomake</c>.
</p>

<warning>
Expand Down
8 changes: 4 additions & 4 deletions tasks-reference/completion/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
<body>

<p>
Since v2.05a, <c>bash</c> has offered intelligent programmable completion. Writing
such completions for your own programs/things you maintain is relatively easy
provided you know bash already. See
<uri link="::eclass-reference/bash-completion-r1.eclass/"/>
Since v2.05a, <c>bash</c> has offered intelligent programmable completion.
Writing such completions for your own programs/things you maintain is
relatively easy provided you know bash already.
See <c><uri link="::eclass-reference/bash-completion-r1.eclass/"/></c>
for how to install completion files.
</p>
</body>
Expand Down
7 changes: 4 additions & 3 deletions tasks-reference/pam/text.xml
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,10 @@ and takes care of executing it.
<body>

<p>
The right place for <c>pamd</c> files is <c>/etc/pam.d</c>, but installing them by
hand checking for <c>pam</c> USE flag is tricky and doesn't follow the same path as
initd and confd files, so the solution is to use the <c>pam</c> eclass.
The right place for <c>pamd</c> files is <c>/etc/pam.d</c>, but installing them
by hand checking for <c>pam</c> USE flag is tricky and doesn't follow the same
path as initd and confd files, so the solution is to use the
<c><uri link="::eclass-reference/pam.eclass/"/></c>.
</p>

<p>
Expand Down

0 comments on commit 017da21

Please sign in to comment.