Commit a6464b3c authored by Dan Nicholson's avatar Dan Nicholson

Never fail `make clean'

Mostly some pedantic changes such that `make clean' always ignores
errors. Also changed the top clean target to do the `touch
configs/current' dance instead of realclean.
parent df8134c3
......@@ -17,16 +17,16 @@ doxygen:
cd doxygen && $(MAKE)
clean:
@for dir in $(SUBDIRS) ; do \
-@touch $(TOP)/configs/current
-@for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
done
-@test -s $(TOP)/configs/current || rm -f $(TOP)/configs/current
realclean:
touch $(TOP)/configs/current
$(MAKE) clean
realclean: clean
-rm -rf lib*
-rm -f $(TOP)/configs/current
-rm -f $(TOP)/configs/autoconf
......
......@@ -29,5 +29,5 @@ subset: $(SUBSET:.doxy=.tag)
$(foreach FILE,$(SUBSET),doxygen $(FILE);)
clean:
rm -rf $(FULL:.doxy=) $(SUBSET:.doxy=)
rm -rf *.tag
-rm -rf $(FULL:.doxy=) $(SUBSET:.doxy=)
-rm -rf *.tag
......@@ -25,7 +25,7 @@ subdirs:
install:
clean:
@for dir in $(SUBDIRS) tests ; do \
-@for dir in $(SUBDIRS) tests ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
......
......@@ -19,8 +19,8 @@ INCLUDES = -I. -I- -I../../include
default: demo sample GLInfo
clean:
rm -f demo sample GLInfo
rm -f *.o
-rm -f demo sample GLInfo
-rm -f *.o
demo: demo.o
$(LD) demo.o $(LDFLAGS) $(LIBS) -o $@
......
......@@ -60,6 +60,6 @@ eglgears.o: eglgears.c $(HEADERS)
clean:
rm -f *.o *~
rm -f *.so
rm -f $(PROGRAMS)
-rm -f *.o *~
-rm -f *.so
-rm -f $(PROGRAMS)
......@@ -37,8 +37,8 @@ LIBS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(APP_LIB_DEPS)
default: depend $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
-rm -f $(PROGS)
-rm -f *.o
depend: $(SOURCES)
......
......@@ -86,9 +86,9 @@ UTIL_FILES = readtex.h readtex.c
default: $(UTIL_FILES) $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
rm -f getproclist.h
-rm -f $(PROGS)
-rm -f *.o
-rm -f getproclist.h
# auto code generation
......
......@@ -43,8 +43,8 @@ LIBS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) $(APP_LIB_DEPS
default: depend $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
-rm -f $(PROGS)
-rm -f *.o
depend: $(SOURCES)
......
......@@ -24,7 +24,7 @@ tests: default
! ./cltest 2> /dev/null | (grep -e ^[*][*][*])
clean:
rm -f cltest.o sotest.o vstest.o framework.o cltest sotest vstest
-rm -f cltest.o sotest.o vstest.o framework.o cltest sotest vstest
#
# executables
......
......@@ -99,9 +99,9 @@ UTIL_FILES = readtex.h readtex.c
default: $(UTIL_FILES) $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
rm -f getproclist.h
-rm -f $(PROGS)
-rm -f *.o
-rm -f getproclist.h
##### RULES #####
......
......@@ -102,9 +102,9 @@ UTIL_FILES = readtex.h readtex.c
default: $(UTIL_FILES) $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
rm -f getproclist.h
-rm -f $(PROGS)
-rm -f *.o
-rm -f getproclist.h
# auto code generation
......
......@@ -40,9 +40,9 @@ INCLUDES = -I. -I$(TOP)/include -I../samples
default: $(PROGS)
clean:
rm -f $(PROGS)
rm -f *.o
rm -f getproclist.h
-rm -f $(PROGS)
-rm -f *.o
-rm -f getproclist.h
......
......@@ -33,7 +33,7 @@ $(TOP)/$(LIB_DIR):
clean:
@for dir in $(SUBDIRS) ; do \
-@for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
......
......@@ -17,7 +17,7 @@ subdirs:
clean:
@for dir in $(SUBDIRS) ; do \
-@for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
......
......@@ -27,5 +27,5 @@ $(TOP)/$(LIB_DIR)/demodriver.so: $(OBJECTS)
clean:
rm -f *.o
rm -f *.so
-rm -f *.o
-rm -f *.so
......@@ -47,8 +47,8 @@ $(TOP)/$(LIB_DIR)/libEGLdri.so: $(OBJECTS)
clean:
rm -f *.o
rm -f *.so
-rm -f *.o
-rm -f *.so
depend: $(SOURCES) $(HEADERS)
@ echo "running $(MKDEP)"
......
......@@ -52,8 +52,8 @@ $(TOP)/$(LIB_DIR)/libEGL.so: $(OBJECTS)
clean:
rm -f *.o *.so*
rm -f core.*
-rm -f *.o *.so*
-rm -f core.*
depend: $(SOURCES) $(HEADERS)
......
......@@ -28,6 +28,6 @@ install: glu.pc
$(INSTALL) -m 644 glu.pc $(DESTDIR)$(INSTALL_DIR)/$(LIB_DIR)/pkgconfig
clean:
@for dir in $(SUBDIRS) ; do \
-@for dir in $(SUBDIRS) ; do \
(cd $$dir && $(MAKE) clean) ; \
done
......@@ -8,5 +8,5 @@ default:
clean:
cd mini && $(MAKE) clean
-@cd mini && $(MAKE) clean
......@@ -207,10 +207,10 @@ clean:
-rm -f */*/*.o
-rm -f depend depend.bak libmesa.a
-rm -f drivers/*/*.o
(cd drivers/dri && $(MAKE) clean)
(cd drivers/xorg && $(MAKE) clean)
(cd x86 && $(MAKE) clean)
(cd x86-64 && $(MAKE) clean)
-@cd drivers/dri && $(MAKE) clean
-@cd drivers/xorg && $(MAKE) clean
-@cd x86 && $(MAKE) clean
-@cd x86-64 && $(MAKE) clean
-include depend
......@@ -50,5 +50,5 @@ install:
clean:
rm -f *.o *.so
-rm -f *.o *.so
......@@ -33,7 +33,7 @@ install:
clean:
@for dir in $(DRI_DIRS) ; do \
-@for dir in $(DRI_DIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
......
......@@ -57,8 +57,8 @@ all: options.h
# Only intermediate files are cleaned up. options.h is not deleted because
# it's in CVS.
clean:
rm -f $(POT) *~
rm -rf $(LANGS)
-rm -f $(POT) *~
-rm -rf $(LANGS)
# Default target options.h
options.h: t_options.h mo
......
......@@ -41,4 +41,4 @@ glslcompiler.o: glslcompiler.c
clean:
rm -f *.o *~ $(PROGRAM)
-rm -f *.o *~ $(PROGRAM)
......@@ -113,5 +113,5 @@ $(GLX_DIR)/indirect_table.c: glX_server_table.py gl_and_glX_API.xml $(COMMON_GLX
$(PYTHON2) $(PYTHON_FLAGS) $< -f gl_and_glX_API.xml > $@
clean:
rm -f *~ *.pyo
rm -f $(OUTPUTS)
-rm -f *~ *.pyo
-rm -f $(OUTPUTS)
......@@ -17,7 +17,7 @@ LIB_DEP = $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME)
default: syntax builtin
clean:
rm -f syn_to_c gc_to_bin *_syn.h *_gc.h
-rm -f syn_to_c gc_to_bin *_syn.h *_gc.h
syntax: slang_pp_directives_syn.h slang_pp_expression_syn.h slang_shader_syn.h slang_pp_version_syn.h
......
......@@ -19,7 +19,7 @@ INCLUDE_DIRS = \
default: matypes.h
clean:
rm -f matypes.h
-rm -f matypes.h
# need some special rules here, unfortunately
......
......@@ -17,7 +17,7 @@ INCLUDE_DIRS = \
default: gen_matypes matypes.h
clean:
rm -f matypes.h gen_matypes
-rm -f matypes.h gen_matypes
gen_matypes: gen_matypes.c
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment