mirror of
https://salsa.debian.org/debian/debian-reference.git
synced 2026-01-16 23:14:19 +00:00
Makefile: "make EXPOSEMODE=yes" feature
Signed-off-by: Osamu Aoki <osamu@debian.org>
This commit is contained in:
parent
3f91223aa3
commit
b0098b9b89
1 changed files with 21 additions and 2 deletions
23
Makefile
23
Makefile
|
|
@ -51,6 +51,17 @@ BUILD_DIR := $(CURDIR)/build
|
|||
#DRAFTMODE := yes
|
||||
DRAFTMODE := maybe
|
||||
export DRAFTMODE
|
||||
|
||||
# define EXPOSEMODE to yes to expose program listings to make entity
|
||||
EXPOSEMODE ?= no
|
||||
ifeq "$(EXPOSEMODE)" "yes"
|
||||
XML_COMMENT_START=
|
||||
XML_COMMENT_END=
|
||||
else
|
||||
XML_COMMENT_START= <!--
|
||||
XML_COMMENT_END= -->
|
||||
endif
|
||||
|
||||
# Prevent external environment vriables to impact build result
|
||||
TZ := "0"
|
||||
export TZ
|
||||
|
|
@ -427,7 +438,11 @@ $(MANUAL).en.xml: $(DRAW)/$(MANUAL).rawxml $(DRAW)/header.rawxml
|
|||
$(XPNO) $(DXSL)/table.xsl $(DRAW)/$(MANUAL).rawxml |\
|
||||
$(DBIN)/colspec.py |\
|
||||
sed -e '/<!DOCTYPE /d' -e "1r $(DRAW)/header.rawxml" |\
|
||||
sed -e 's/@-@amp@-@/\&/g' -e 's/@-@\([^@]\+\)@-@/\&\1;/g' > $@
|
||||
sed -e 's/@-@amp@-@/\&/g' \
|
||||
-e 's/@-@XML_COMMENT_START@-@/$(XML_COMMENT_START)/g' \
|
||||
-e 's/@-@XML_COMMENT_END@-@/$(XML_COMMENT_END)/g' \
|
||||
-e 's/@-@\([^@]\+\)@-@/\&\1;/g' \
|
||||
> $@
|
||||
|
||||
# Replace table contents with dummy text and
|
||||
# fix URL references and table ID as the template for translation.
|
||||
|
|
@ -439,7 +454,11 @@ $(MANUAL).en.xmlt: $(DRAW)/$(MANUAL).rawxml $(DRAW)/header.rawxml
|
|||
$(XPNO) $(DXSL)/tablet.xsl $(DRAW)/$(MANUAL).rawxml |\
|
||||
$(DBIN)/colspec.py |\
|
||||
sed -e '/<!DOCTYPE /d' -e "1r $(DRAW)/header.rawxml" |\
|
||||
sed -e 's/@-@amp@-@/\&/g' -e 's/@-@\([^@]\+\)@-@/\&\1;/g' > $@
|
||||
sed -e 's/@-@amp@-@/\&/g' \
|
||||
-e 's/@-@XML_COMMENT_START@-@/$(XML_COMMENT_START)/g' \
|
||||
-e 's/@-@XML_COMMENT_END@-@/$(XML_COMMENT_END)/g' \
|
||||
-e 's/@-@\([^@]\+\)@-@/\&\1;/g' \
|
||||
> $@
|
||||
|
||||
#######################################################################
|
||||
# Phase 3 build : English XML -> POT/PO/XML non-ENGLISH
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue