summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rw-r--r--modules.mk22
2 files changed, 14 insertions, 11 deletions
diff --git a/Makefile b/Makefile
index 716832d..925bef7 100644
--- a/Makefile
+++ b/Makefile
@@ -28,6 +28,9 @@ MASTER_PRES := tmp_master_pres
MASTER_HANDOUT := tmp_master_handout
MASTER_END := .tex
+HANDOUT_PREFIX := handout_
+PRES_PREFIX := pres_
+
# Folder that should not include to build paths
EXCLUDE_PATH := grep -v ./kconfig-frontends | grep -v ./.git | grep -v ./kernel-devel/module-basics/vain | grep -v ./kernel-devel/module-basics/vain_pci | grep -v ./kernel-devel/module-basics/vain_plat
diff --git a/modules.mk b/modules.mk
index 27eb8b4..29cc270 100644
--- a/modules.mk
+++ b/modules.mk
@@ -38,16 +38,16 @@ clean:
rm -f *.vrb
build_master_pres:
-ifneq ($(filter pres_%,$(obj-y)), )
+ifneq ($(filter $(PRES_PREFIX)%,$(obj-y)), )
`echo "\input{$(dir $(CURDIR))section.tex}" >> ../$(MASTER_PRES)$(MASTER_END)`
- for files in $(subst .pdf,.tex,$(filter pres_%,$(obj-y))) ; do \
+ for files in $(subst .pdf,.tex,$(filter $(PRES_PREFIX)%,$(obj-y))) ; do \
`echo "\input{$(CURDIR)/$$files}" >> ../$(MASTER_PRES)$(MASTER_END)` ; \
done
endif
# Dirty for now the master_handout is build every time not only one time
-build_master_pres_end:
-ifneq ($(filter pres_%,$(obj-y)), )
+build_master_$(PRES_PREFIX)end:
+ifneq ($(filter $(PRES_PREFIX)%,$(obj-y)), )
echo "\input{configmasterpres}" > ../$(MASTER_PRES)_$(BASE_NAME)$(MASTER_END)
cat ../$(MASTER_PRES)$(MASTER_END) >> ../$(MASTER_PRES)_$(BASE_NAME)$(MASTER_END)
echo "\input{tailmasterpres}" >> ../$(MASTER_PRES)_$(BASE_NAME)$(MASTER_END)
@@ -71,16 +71,16 @@ endif
endif
build_master_handout:
-ifneq ($(filter handout_%,$(obj-handout-y)), )
+ifneq ($(filter $(HANDOUT_PREFIX)%,$(obj-handout-y)), )
`echo "\input{$(dir $(CURDIR))section.tex}" >> ../$(MASTER_HANDOUT)$(MASTER_END)`
- for files in $(subst .pdf,.tex,$(filter handout_%,$(obj-handout-y))) ; do \
+ for files in $(subst .pdf,.tex,$(filter $(HANDOUT_PREFIX)%,$(obj-handout-y))) ; do \
`echo "\input{$(CURDIR)/$$files}" >> ../$(MASTER_HANDOUT)$(MASTER_END)` ; \
done
endif
# Dirty for now the master_handout is build every time not only one time
-build_master_handout_end:
-ifneq ($(filter handout_%,$(obj-handout-y)), )
+build_master_$(HANDOUT_PREFIX)end:
+ifneq ($(filter $(HANDOUT_PREFIX)%,$(obj-handout-y)), )
echo "\input{configmasterhandout}" > ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
cat ../$(MASTER_HANDOUT)$(MASTER_END) >> ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
echo "\input{tailmasterhandout}" >> ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
@@ -93,8 +93,8 @@ ifneq ($(filter handout_%,$(obj-handout-y)), )
TEXINPUTS=`pwd`/../..:.:..:$(TEXINPUTS) $(BUILD) ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
ifndef CONFIG_BUILD_FAST_BUILD
- TEXINPUTS=`pwd`/../..:.:..:$(TEXINPUTS) $(BUILD) ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
- TEXINPUTS=`pwd`/../..:.:..:$(TEXINPUTS) $(BUILD) ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
+ TEXINPUTS=`pwd`/../..:.:..:$(TEXINPUTS) $(BUILD) ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
+ TEXINPUTS=`pwd`/../..:.:..:$(TEXINPUTS) $(BUILD) ../$(MASTER_HANDOUT)_$(BASE_NAME)$(MASTER_END)
endif
# Only for TESTING dirty hack ***********************************
mv $(TOP_DIR)/_confighandout.tex $(TOP_DIR)/confighandout.tex
@@ -103,5 +103,5 @@ endif
cp $(MASTER_HANDOUT)_$(BASE_NAME).pdf $(HANDOUT)/$(subst tmp_,,$(MASTER_HANDOUT)_$(BASE_NAME).pdf)
endif
-.PHONY: clean build_master_pres_end build_master_pres build_master_handout_end build_master_handout
+.PHONY: clean build_master_$(PRES_PREFIX)end build_master_pres build_master_$(HANDOUT_PREFIX)end build_master_handout