Output the book in utf-8 encoding

Also fix doctype being removed by tidy in longindex by removing a wrong
attribute (xmlns:xlink) in a div element in the index.
This commit is contained in:
Pierre Labastie 2024-01-15 09:47:56 +01:00
parent ce4020410f
commit 1df87eede9
4 changed files with 2 additions and 8 deletions

View File

@ -108,6 +108,7 @@ $(BASEDIR)/index.html: $(RENDERTMP)/$(BLFSHTML) version
--stringparam base.dir $(BASEDIR)/ \ --stringparam base.dir $(BASEDIR)/ \
stylesheets/blfs-chunked.xsl \ stylesheets/blfs-chunked.xsl \
$(RENDERTMP)/$(BLFSHTML) $(RENDERTMP)/$(BLFSHTML)
$(Q)sed -i 's/xmlns:xlink.*xlink"//' $(BASEDIR)/longindex.html
@echo "Copying CSS code and images..." @echo "Copying CSS code and images..."
$(Q)if [ ! -e $(BASEDIR)/stylesheets ]; then \ $(Q)if [ ! -e $(BASEDIR)/stylesheets ]; then \
@ -141,6 +142,7 @@ $(BASEDIR)/$(NOCHUNKS_OUTPUT): $(RENDERTMP)/$(BLFSHTML) version
--output $(BASEDIR)/$(NOCHUNKS_OUTPUT) \ --output $(BASEDIR)/$(NOCHUNKS_OUTPUT) \
stylesheets/blfs-nochunks.xsl \ stylesheets/blfs-nochunks.xsl \
$(RENDERTMP)/$(BLFSHTML) $(RENDERTMP)/$(BLFSHTML)
$(Q)sed -i 's/xmlns:xlink.*xlink"//' $(BASEDIR)/$(NOCHUNKS_OUTPUT)
@echo "Running Tidy and obfuscate.sh on non-chunked XHTML..." @echo "Running Tidy and obfuscate.sh on non-chunked XHTML..."
$(Q)tidy -config tidy.conf $(BASEDIR)/$(NOCHUNKS_OUTPUT) || true $(Q)tidy -config tidy.conf $(BASEDIR)/$(NOCHUNKS_OUTPUT) || true

View File

@ -10,9 +10,6 @@
<!-- Upstream XHTML presentation templates --> <!-- Upstream XHTML presentation templates -->
<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl"/> <xsl:import href="http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl"/>
<!-- Use ISO-8859-1 for output instead of default UTF-8 -->
<xsl:param name="chunker.output.encoding" select="'ISO-8859-1'"/>
<!-- Including our customized elements templates --> <!-- Including our customized elements templates -->
<xsl:include href="common.xsl"/> <xsl:include href="common.xsl"/>
<xsl:include href="xhtml/lfs-admon.xsl"/> <xsl:include href="xhtml/lfs-admon.xsl"/>

View File

@ -10,9 +10,6 @@
<!-- Upstream XHTML templates --> <!-- Upstream XHTML templates -->
<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl"/> <xsl:import href="http://docbook.sourceforge.net/release/xsl/current/xhtml/docbook.xsl"/>
<!-- Fix encoding issues with default UTF-8 output of the xhtml stylesheet -->
<xsl:output method="html" encoding="ISO-8859-1" indent="no" />
<!-- Including our others customized templates --> <!-- Including our others customized templates -->
<xsl:include href="common.xsl"/> <xsl:include href="common.xsl"/>
<xsl:include href="xhtml/lfs-index.xsl"/> <xsl:include href="xhtml/lfs-index.xsl"/>

View File

@ -4,8 +4,6 @@
indent-spaces: 2 indent-spaces: 2
wrap: 78 wrap: 78
tab-size: 8 tab-size: 8
input-encoding: latin1
output-encoding: latin1
newline: LF newline: LF
write-back: yes write-back: yes
markup: yes markup: yes