From 459a4829ae3bc8ffb29b432ebb35d81872916bfa Mon Sep 17 00:00:00 2001 From: Jelte Fennema Date: Fri, 3 Apr 2020 16:28:06 +0200 Subject: [PATCH] Fix isolation tests on OSX (#3706) * Don't print out comments in make output * Remove empty lines with sed --- src/test/regress/Makefile | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/test/regress/Makefile b/src/test/regress/Makefile index 3ca89369b..34bc30a40 100644 --- a/src/test/regress/Makefile +++ b/src/test/regress/Makefile @@ -64,14 +64,15 @@ create-symbolic-link: # it runs the spec files from build/specs and checks the expected output from build/expected. # /specs is renamed as /spec because postgres first look at the specs file under current directory, # so this is renamed to avoid that since we are running the isolation tests from build/specs now. -$(generated_isolation_files): $(citus_abs_srcdir)/build/specs/%: $(citus_abs_srcdir)/spec/% +$(generated_isolation_files): $(citus_abs_srcdir)/build/specs/%: $(citus_abs_srcdir)/spec/% Makefile @mkdir -p $(citus_abs_srcdir)/$(ISOLATION_DEPDIR) $(citus_abs_srcdir)/$(ISOLATION_BUILDDIR) - # -MF is used to store dependency files(.Po) in another directory for separation - # -MT is used to change the target of the rule emitted by dependency generation. - # -P is used to inhibit generation of linemarkers in the output from the preprocessor. - # -undef is used to not predefine any system-specific or GCC-specific macros. - # `man cpp` for further information - cd $(citus_abs_srcdir) && cpp -undef -w -P -MMD -MP -MF$(ISOLATION_DEPDIR)/$(*F).Po -MT$@ $< > $@ + @# -MF is used to store dependency files(.Po) in another directory for separation + @# -MT is used to change the target of the rule emitted by dependency generation. + @# -P is used to inhibit generation of linemarkers in the output from the preprocessor. + @# -undef is used to not predefine any system-specific or GCC-specific macros. + @# `man cpp` for further information + @# sed is used to strip the final // comments, because OSX cpp is weird + cd $(citus_abs_srcdir) && cpp -undef -w -P -MMD -MP -MF$(ISOLATION_DEPDIR)/$(*F).Po -MT$@ $< | sed '/^\/\//d' | sed '/^$$/d' > $@ Isolation_Po_files := $(wildcard $(ISOLATION_DEPDIR)/*.Po)