]> Lady鈥檚 Gitweb - Shushe/blobdiff - GNUmakefile
Redirect some errors to /dev/null
[Shushe] / GNUmakefile
index 53db7f25eeb1ca9555dcd9852f5c9553c57b8c4d..a272f9a218c68b568cc294f62e002f35009dd092 100644 (file)
@@ -237,13 +237,13 @@ ifdef GIT
 ifneq ($(wildcard $(THISDIR)/.git),)
 # (overridable) The name of the current revision of 鉀╋笍馃摪 涔︾ぞ, or its
 # hash if the current revision is not a tag.
-thisrev = $(shell cd $(THISDIR); $(GIT) describe 2> /dev/null || $(GIT) rev-parse HEAD)
+thisrev = $(shell cd $(THISDIR); $(GIT) describe 2> /dev/null || $(GIT) rev-parse HEAD 2> /dev/null || true)
 endif
 
 ifneq ($(wildcard .git),)
 # (overridable) The name of the current revision of the working
 # directory, or its hash if the current revision is not a tag.
-srcrev = $(shell $(GIT) describe 2> /dev/null || $(GIT) rev-parse HEAD)
+srcrev = $(shell $(GIT) describe 2> /dev/null || $(GIT) rev-parse HEAD 2> /dev/null || true)
 endif
 endif
 
@@ -270,7 +270,7 @@ override assetfiles := $(filter-out $(xmlfiles) $(plaintextfiles),$(sourcefiles)
 override typeoffile = $(patsubst $(foreach file,$1,$(file)|%),%,$(filter $(foreach file,$1,$(file)|%),$(types)))
 
 # (callable) Get the identifier for the given parser or transform.
-override id = $(or $(shell $(XMLLINT) --xpath '/*/*[local-name()="id" and namespace-uri()="urn:fdc:ladys.computer:20231231:Shu1She4"]/text()[1]' $1),about:shushe?$(or $2,unknown)=$(call pathenc,$(basename $(notdir $1))))
+override id = $(or $(shell $(XMLLINT) --xpath '/*/*[local-name()="id" and namespace-uri()="urn:fdc:ladys.computer:20231231:Shu1She4"]/text()[1]' $1 2> /dev/null),about:shushe?$(or $2,unknown)=$(call pathenc,$(basename $(notdir $1))))
 
 # (callable) Get the local path for the given source file.
 override sourcepath = $(firstword $(foreach directory,$(SRCDIR),$(if $(filter $(directory)/%,$1),$(patsubst $(directory)/%,%,$1),)))
@@ -345,8 +345,8 @@ override sourcedestinationpair := $(foreach destination,$(destinations),$(call s
 # (callable) Get the destination for the given source files.
 override destination = $(foreach file,$1,$(patsubst $(file)|%,%,$(filter $(file)|%,$(sourcedestinationpair))))
 
-# Pair each source file and include with its compiled location.
-override sourcecompiledpair := $(foreach file,$(sourcefiles) $(sourceincludes),$(file)|$(BUILDDIR)/public/$(call destination,$(file)))
+# Pair each source file with its compiled location.
+override sourcecompiledpair := $(foreach file,$(sourcefiles),$(file)|$(BUILDDIR)/public/$(call destination,$(file)))
 
 # (callable) Get the location of the transformed X路M路L files for the
 # given source files.
@@ -373,10 +373,10 @@ override wrapplaintext = $(PRINTF) '%s\n' "$$($(PRINTF) '%b' '<?xml version=\042
 
 # Provide help.
 help:
-       $(silent)$(PRINTF) '%b' '$(subst $(newline),\n,$(makefileinfo))'
+       @$(PRINTF) '%b' '$(subst $(newline),\n,$(makefileinfo))'
 
 # Compile all files, or error if any are recursive.
-all: $(call compiled,$(recursivefiles) $(compilablefiles) $(filter $(sourcefiles),$(assetfiles))) ;
+all: $(call compiled,$(recursivefiles) $(compilablefiles) $(filter $(sourcefiles),$(assetfiles)));
 
 # Destroy buildfiles.
 clean:
@@ -387,11 +387,11 @@ gone:
        $(silent)$(RM) -rf $(BUILDDIR)/ $(call compiled,$(recursivefiles) $(compilablefiles))
 
 # Install the compiled files into `DESTDIR麓.
-install: $(call installed,$(recursivefiles) $(compilablefiles) $(filter $(sourcefiles),$(assetfiles))) ;
+install: $(call installed,$(recursivefiles) $(compilablefiles) $(filter $(sourcefiles),$(assetfiles)));
 
 # List all source files and includes and their computed types.
 list:
-       $(silent)$(PRINTF) '%b' $(call quote,$(foreach file,$(sort $(sourcefiles)) $(sort $(sourceincludes)),\0033[1m$(file)\0033[22m|$(call typeoffile,$(file))|[\0033[3m$(if $(filter $(file),$(xmlfiles)),xml,$(if $(filter $(file),$(plaintextfiles)),text,asset))$(if $(filter $(file),$(sourceincludes)),|include,)\0033[23m]$(if $(call dependencies,$(file))$(call recursives,$(file)), $(strip $(foreach recursive,$(call recursives,$(file)),\0033[93;41m鈥Recursive|Dependency|\0033[39;49m|$(recursive)) $(foreach dependency,$(call dependencies,$(file)),\0033[2m鈥Dependency|\0033[22m|$(dependency))))$(if $(filter $(file),$(sourcefiles)), 鈫抾<\0033[4m/$(call destination,$(file))\0033[24m>,) )) | $(TR) ' |' '\n '
+       @$(PRINTF) '%b' $(call quote,$(foreach file,$(sort $(sourcefiles)) $(sort $(sourceincludes)),\0033[1m$(file)\0033[22m|$(call typeoffile,$(file))|[\0033[3m$(if $(filter $(file),$(xmlfiles)),xml,$(if $(filter $(file),$(plaintextfiles)),text,asset))$(if $(filter $(file),$(sourceincludes)),|include,)\0033[23m]$(if $(call dependencies,$(file))$(call recursives,$(file)), $(strip $(foreach recursive,$(call recursives,$(file)),\0033[93;41m鈥Recursive|Dependency|\0033[39;49m|$(recursive)) $(foreach dependency,$(call dependencies,$(file)),\0033[2m鈥Dependency|\0033[22m|$(dependency))))$(if $(filter $(file),$(sourcefiles)), 鈫抾<\0033[4m/$(call destination,$(file))\0033[24m>,) )) | $(TR) ' |' '\n '
 
 # Raise an error when attempting to build any files with recursive
 # dependencies.
This page took 0.023904 seconds and 4 git commands to generate.