> I recently started seeing the following problem doing a make distclean: > > rm -rf ../libsrc/.deps ./.deps
Hi, (Autotools amateur here, so please correct me nicely if I'm wrong! :) ) I'd say the above line is the problem is the above line, where your Makefile is touching something that's not an immediate subdirectory, i.e. cross-removing .deps files in ../libsrc while it's operating in libsrc4. Generally one should avoid that because the .deps files are always generated and read by the Makefiles. distclean is particularly sensitive to this. Does your Makefile .am have ../libsrc in the SUBDIRS? I'm guessing that might have caused it. When distclean cleaned the directories in reverse order, it pulled the wheels out from under the cart. (complete stab in the dark) If libsrc really depends on something being built in a sister directory, you might resort to other tricks to make a correct build, like depending on SUBDIR ordering, making cross- directory links, or explicit jumps to that directory ($(MAKE) -C foo). > rm -f Makefile > make[1]: Leaving directory `/home/ed/netcdf-3/libsrc4' > Making distclean in libsrc > make[1]: Entering directory `/home/ed/netcdf-3/libsrc' > Makefile:364: .deps/attr.Plo: No such file or directory > Makefile:365: .deps/dim.Plo: No such file or directory > Makefile:366: .deps/error.Plo: No such file or directory > Makefile:367: .deps/libvers.Plo: No such file or directory > Makefile:368: .deps/nc.Plo: No such file or directory > Makefile:369: .deps/ncx.Plo: No such file or directory > Makefile:370: .deps/posixio.Plo: No such file or directory > Makefile:371: .deps/putget.Plo: No such file or directory > Makefile:372: .deps/string.Plo: No such file or directory > Makefile:373: .deps/v1hpg.Plo: No such file or directory > Makefile:374: .deps/v2i.Plo: No such file or directory > Makefile:375: .deps/var.Plo: No such file or directory > make[1]: *** No rule to make target `.deps/var.Plo'. Stop. > make[1]: Leaving directory `/home/ed/netcdf-3/libsrc' > make: *** [ > distclean-recursive] Error 1 > > I've got no clue what's going on here. Hope this helps. David Fang