commit:     d925226a528dc974b765a41d20da937b97342ea6
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Sat Jun  4 18:12:49 2022 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Fri Jun 10 17:17:31 2022 +0000
URL:        https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=d925226a

devbook.xsl: Eclass documentation needs GPL-2 in the footer

Eclasses are licensed GPL-2, therefore we need a different footer.
Hardcode this for all sub-pages of eclass-reference/.

Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>

 devbook.xsl | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/devbook.xsl b/devbook.xsl
index 9a254a7..1aebead 100644
--- a/devbook.xsl
+++ b/devbook.xsl
@@ -665,7 +665,15 @@
               <small>
                 Gentoo is a trademark of the Gentoo Foundation, Inc.
                 The text of this document is distributed under the
-                <a 
href="https://creativecommons.org/licenses/by-sa/4.0/";>Creative Commons 
Attribution-ShareAlike 4.0 International License</a>.
+                <xsl:choose>
+                  <!-- Eclasses are GPL-2, so we need a different footer -->
+                  <xsl:when test="starts-with(/guide/@self, 
'eclass-reference/') and $relative_path_depth &gt;= 2">
+                    <a href="https://www.gnu.org/licenses/gpl-2.0.html";>GNU 
General Public License, version 2</a>.
+                  </xsl:when>
+                  <xsl:otherwise>
+                    <a 
href="https://creativecommons.org/licenses/by-sa/4.0/";>Creative Commons 
Attribution-ShareAlike 4.0 International License</a>.
+                  </xsl:otherwise>
+                </xsl:choose>
                 The <a 
href="https://www.gentoo.org/inside-gentoo/foundation/name-logo-guidelines.html";>Gentoo
 Name and Logo Usage Guidelines</a> apply.
               </small>
             </div>

Reply via email to