]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
Merge branch 'refs/heads/t/ONESHELL'
authorAndre Noll <maan@tuebingen.mpg.de>
Sun, 8 Sep 2019 09:07:45 +0000 (11:07 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Sun, 8 Sep 2019 09:09:02 +0000 (11:09 +0200)
A single patch which instructs the build system to run multi-line
statements in Makefiles in a single shell instance.

Cooking in next for nine months.

* refs/heads/t/ONESHELL:
  build: Use .ONESHELL.

1  2 
Makefile.real
NEWS.md

diff --combined Makefile.real
index 5df27bad934a58f04b4b6407e868e8898ded4002,c8d30aae7f6d2171e8c45bc037da88512562f92b..7d4eff4fe2eaecc99fb83627a154b9c1672118ca
@@@ -6,6 -6,8 +6,8 @@@ MAKEFLAGS += -R
  ifeq ("$(origin CC)", "default")
          CC := cc
  endif
+ .ONESHELL:
+ .SHELLFLAGS := -ec
  
  LOGLEVELS := LL_DEBUG,LL_INFO,LL_NOTICE,LL_WARNING,LL_ERROR,LL_CRIT,LL_EMERG
  vardir := /var/paraslash
@@@ -18,7 -20,7 +20,7 @@@ uname_s := $(shell uname -s 2>/dev/nul
  uname_rs := $(shell uname -rs)
  cc_version := $(shell $(CC) --version | head -n 1)
  GIT_VERSION := $(shell ./GIT-VERSION-GEN git-version.h)
 -COPYRIGHT_YEAR := 2018
 +COPYRIGHT_YEAR := 2019
  
  ifeq ("$(origin O)", "command line")
        build_dir := $(O)
@@@ -102,7 -104,7 +104,7 @@@ endi
  
  $(object_dir) $(man_dir) $(dep_dir) $(m4depdir) $(lls_suite_dir) \
        $(yy_build_dir):
-       $(Q) $(MKDIR_P) $@
+       @$(MKDIR_P) $@
  
  CPPFLAGS += -DBINDIR='"$(bindir)"'
  CPPFLAGS += -DCOPYRIGHT_YEAR='"$(COPYRIGHT_YEAR)"'
@@@ -110,6 -112,7 +112,6 @@@ CPPFLAGS += -DBUILD_DATE='"$(build_date
  CPPFLAGS += -DLOGLEVELS='$(LOGLEVELS)'
  CPPFLAGS += -DUNAME_RS='"$(uname_rs)"'
  CPPFLAGS += -DCC_VERSION='"$(cc_version)"'
 -CPPFLAGS += -I/usr/local/include
  CPPFLAGS += -I$(lls_suite_dir)
  CPPFLAGS += -I$(yy_build_dir)
  CPPFLAGS += $(lopsub_cppflags)
@@@ -148,9 -151,9 +150,9 @@@ STRICT_CFLAGS += $(call cc-option, -Wdi
  # To put more focus on warnings, be less verbose as default
  # Use 'make V=1' to see the full commands
  ifeq ("$(origin V)", "command line")
-       Q :=
+       SAY =
  else
-       Q := @
+       SAY = @echo '$(strip $(1))'
  endif
  
  audiod_commands := $(addprefix $(lls_suite_dir)/, \
@@@ -177,9 -180,9 +179,9 @@@ $(man_dir)/para_write.1: all_commands :
  
  $(man_dir)/para_%.1: $(lls_suite_dir)/%.lsg.man \
                $(lls_m4_dir)/copyright.m4 | $(man_dir)
-       @[ -z "$(Q)" ] || echo 'LLSMAN $<'
-       $(Q) cat $< $(all_commands) > $@
-       $(Q) $(M4) -D COPYRIGHT_YEAR=$(COPYRIGHT_YEAR) $(lls_m4_dir)/copyright.m4 >> $@
+       $(call SAY, LLSMAN $<)
+       cat $< $(all_commands) > $@
+       $(M4) -D COPYRIGHT_YEAR=$(COPYRIGHT_YEAR) $(lls_m4_dir)/copyright.m4 >> $@
  
  $(object_dir)/%.o: %.c | $(object_dir)
  
@@@ -190,7 -193,7 +192,7 @@@ $(object_dir)/spx%.o: CPPFLAGS += $(spe
  $(object_dir)/flac%.o: CPPFLAGS += $(flac_cppflags)
  
  $(object_dir)/mp3_afh.o: CPPFLAGS += $(id3tag_cppflags)
 -$(object_dir)/crypt.o: CPPFLAGS += $(openssl_cppflags)
 +$(object_dir)/openssl.o: CPPFLAGS += $(openssl_cppflags)
  $(object_dir)/gcrypt.o: CPPFLAGS += $(gcrypt_cppflags)
  $(object_dir)/ao_write.o: CPPFLAGS += $(ao_cppflags)
  $(object_dir)/alsa%.o: CPPFLAGS += $(alsa_cppflags)
@@@ -247,8 -250,8 +249,8 @@@ $(object_dir)/mm.o 
  $(object_dir)/compress_filter.o: CFLAGS += -O3
  
  $(object_dir)/%.o: %.c | $(object_dir) $(dep_dir) $(lsg_h) $(yy_h)
-       @[ -z "$(Q)" ] || echo 'CC $<'
-       $(Q) $(CC) -c -o $@ -MMD -MF $(dep_dir)/$(*F).d -MT $@ $(CPPFLAGS) \
+       $(call SAY, CC $<)
+       $(CC) -c -o $@ -MMD -MF $(dep_dir)/$(*F).d -MT $@ $(CPPFLAGS) \
                $(STRICT_CFLAGS) $(CFLAGS) $<
  
  para_recv para_afh para_play para_server: LDFLAGS += $(id3tag_ldflags)
@@@ -313,24 -316,24 +315,24 @@@ para_afh para_recv para_server para_pla
  
  $(foreach exe,$(executables),$(eval para_$(exe): $$($(exe)_objs)))
  $(prefixed_executables):
-       @[ -z "$(Q)" ] || echo 'LD $@'
-       $(Q) $(CC) $^ -o $@ $(LDFLAGS)
+       $(call SAY, LD $@)
+       $(CC) $^ -o $@ $(LDFLAGS)
  
  mostlyclean:
-       @[ -z "$(Q)" ] || echo 'MOSTLYCLEAN'
-       $(Q) rm -f para_*
-       $(Q) rm -rf $(object_dir)
+       $(call SAY, MOSTLYCLEAN)
+       rm -f para_*
+       rm -rf $(object_dir)
  clean: mostlyclean
-       @[ -z "$(Q)" ] || echo 'CLEAN'
-       $(Q) rm -rf $(build_dir)
+       $(call SAY, CLEAN)
+       rm -rf $(build_dir)
  distclean: clean
-       @[ -z "$(Q)" ] || echo 'DISTCLEAN'
-       $(Q) rm -f Makefile autoscan.log config.status config.log
-       $(Q) rm -f config.h configure config.h.in
+       $(call SAY, DISTCLEAN)
+       rm -f Makefile autoscan.log config.status config.log
+       rm -f config.h configure config.h.in
  maintainer-clean: distclean
-       @[ -z "$(Q)" ] || echo 'MAINTAINER-CLEAN'
-       $(Q) rm -f *.tar.bz2 *.tar.xz
-       $(Q) rm -f GPATH GRTAGS GSYMS GTAGS
+       $(call SAY, MAINTAINER-CLEAN)
+       rm -f *.tar.bz2 *.tar.xz
+       rm -f GPATH GRTAGS GSYMS GTAGS
  
  INSTALL ?= install
  INSTALL_PROGRAM ?= $(INSTALL)
@@@ -346,14 -349,15 +348,15 @@@ install install-strip: all ma
        $(MKDIR_P) $(DESTDIR)$(vardir) >/dev/null 2>&1 || true # not fatal, so don't complain
  
  $(tarball) dist tarball:
-       $(Q) rm -rf $(tarball) $(tarball_pfx)
-       $(Q) git archive --format=tar --prefix=$(tarball_pfx)/ HEAD \
-               | tar --delete $(tarball_delete) > $(tarball_pfx).tar
-       $(Q) $(MKDIR_P) $(tarball_pfx)
-       $(Q) ./GIT-VERSION-GEN > $(tarball_pfx)/VERSION
-       $(Q) cp $(autocrap) $(tarball_pfx)
-       $(Q) tar rf $(tarball_pfx).tar $(tarball_pfx)/*
-       $(Q) xz -9 $(tarball_pfx).tar
-       $(Q) ls -l $(tarball)
-       $(Q) ln -sf $(tarball) paraslash-git.tar.xz
-       $(Q) rm -rf $(tarball_pfx)
+       $(call SAY, DIST)
+       rm -rf $(tarball) $(tarball_pfx)
+       git archive --format=tar --prefix=$(tarball_pfx)/ HEAD \
+          | tar --delete $(tarball_delete) > $(tarball_pfx).tar
+       $(MKDIR_P) $(tarball_pfx)
+       ./GIT-VERSION-GEN > $(tarball_pfx)/VERSION
+       cp $(autocrap) $(tarball_pfx)
+       tar rf $(tarball_pfx).tar $(tarball_pfx)/*
+       xz -9 $(tarball_pfx).tar
+       ls -l $(tarball)
+       ln -sf $(tarball) paraslash-git.tar.xz
+       rm -rf $(tarball_pfx)
diff --combined NEWS.md
index 7ed78027fc29cf5f681e0d4b00464397ff4e995b,55ef3be947ee76d6b0937b33988b0cd960c0e985..bbe200102627b929907a78ff5a14792cdc45f720
+++ b/NEWS.md
@@@ -1,22 -1,6 +1,24 @@@
  NEWS
  ====
  
 +----------------------------------------------
 +0.6.3 (to be announced) "generalized activity"
 +----------------------------------------------
 +
 +- The ff command now accepts a negative argument to instruct the
 +  virtual streaming system to jump backwards in the current audio
 +  stream. The old syntax (e.g., "ff 30-") is still supported but it
 +  is deprecated and no longer documented. The compatibility code is
 +  sheduled for removal after 0.7.0.
 +- para_afh: New option: --preserve to reset the modification time to
 +  the value of the original file after meta data modification.
 +- Overhaul of the compress filter code. The refined algorithm should
 +  reduce clipping. The meaning of --aggressiveness has changed, see the
 +  updated and extended documentation of the compress filter for details.
 +- Cleanup of the audio format handler code.
++- We now build the tree using the .ONESHELL feature of GNU make,
++  which results in a significant speedup.
 +
  --------------------------------------
  0.6.2 (2018-06-30) "elastic diversity"
  --------------------------------------