Browse Source

make indent optional in Makefile so when it coredump in somecase won't harm building

git-svn-id: svn://svn.lighttpd.net/xcache/trunk@642 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
3.0
Xuefer 12 years ago
parent
commit
dd1d1592fc
  1. 12
      Makefile.frag
  2. 3
      config.w32

12
Makefile.frag

@ -11,19 +11,19 @@ $(XCACHE_INCLUDES_I): $(XCACHE_INCLUDES_SRC) $(srcdir)/xcache.h
$(XCACHE_STRUCTINFO_OUT): $(XCACHE_INCLUDES_I) $(srcdir)/mkstructinfo.awk
@echo $(XCACHE_STRUCTINFO_OUT) is optional if XCache test is not enabled, feel free if it awk failed to produce it
-$(XCACHE_AWK) -f $(srcdir)/mkstructinfo.awk < $(XCACHE_INCLUDES_I) > $(XCACHE_STRUCTINFO_OUT).tmp && mv -f $(XCACHE_STRUCTINFO_OUT).tmp $(XCACHE_STRUCTINFO_OUT)
-$(XCACHE_AWK) -f $(srcdir)/mkstructinfo.awk < $(XCACHE_INCLUDES_I) > $(XCACHE_STRUCTINFO_OUT).tmp && mv $(XCACHE_STRUCTINFO_OUT).tmp $(XCACHE_STRUCTINFO_OUT)
$(XCACHE_PROC_OUT): $(XCACHE_PROC_SRC) $(XCACHE_STRUCTINFO_OUT) $(XCACHE_PROC_SOURCES)
$(M4) -D srcdir='`'"$(srcdir)'" -D builddir='`'"$(builddir)'" $(XCACHE_ENABLE_TEST) $(XCACHE_PROC_SRC) > $(XCACHE_PROC_OUT).tmp
mv -f $(XCACHE_PROC_OUT).tmp $(XCACHE_PROC_OUT)
mv $(XCACHE_PROC_OUT).tmp $(XCACHE_PROC_OUT)
$(XCACHE_PROC_H): $(XCACHE_PROC_OUT)
$(GREP) 'export: ' $(XCACHE_PROC_OUT) | $(SED) 's/.*export:\(.*\):export.*/\1/g' | $(XCACHE_INDENT) > $(XCACHE_PROC_H).tmp
mv -f $(XCACHE_PROC_H).tmp $(XCACHE_PROC_H)
$(GREP) 'export: ' $(XCACHE_PROC_OUT) | $(SED) 's/.*export:\(.*\):export.*/\1/g' > $(XCACHE_PROC_H)
-$(XCACHE_INDENT) < $(XCACHE_PROC_H) > $(XCACHE_PROC_H).tmp && mv $(XCACHE_PROC_H).tmp $(XCACHE_PROC_H)
$(XCACHE_PROC_C): $(XCACHE_PROC_OUT) $(XCACHE_PROC_H)
$(XCACHE_INDENT) < $(XCACHE_PROC_OUT) > $(XCACHE_PROC_C).tmp
mv -f $(XCACHE_PROC_C).tmp $(XCACHE_PROC_C)
cp $(XCACHE_PROC_OUT) $(XCACHE_PROC_C)
-$(XCACHE_INDENT) < $(XCACHE_PROC_OUT) > $(XCACHE_PROC_C).tmp && mv $(XCACHE_PROC_C).tmp $(XCACHE_PROC_C)
$(builddir)/processor.lo: $(XCACHE_PROC_C) $(XCACHE_PROC_H) $(srcdir)/processor.c
processor.lo: $(XCACHE_PROC_C) $(XCACHE_PROC_H) $(srcdir)/processor.c

3
config.w32

@ -115,7 +115,8 @@ if (PHP_XCACHE != "no") {
frag = frag.replace(/\.lo:/g, ".obj:");
frag = frag.replace(/.*\$\(CC\).* -E (.*) -o (.*)/, ccrule + " /E $1 > $2");
frag = frag.replace(/ -o /g, " /Fo");
frag = frag.replace(/mv -f /g, "move ");
frag = frag.replace(/cp /g, "copy ");
frag = frag.replace(/mv /g, "move ");
frag = frag.replace(/ \|\| /g, "\r\n\tif errorlevel 1 ");
frag = frag.replace(/ && /g, "\r\n\tif not errorlevel 1 ");
if (indent == '') {

Loading…
Cancel
Save