On 05/22/2012 06:10 PM, Adam Mercer wrote: > Hi > > For one of my projects I'm running into an error where distcheck fails > with the error: > > ERROR: files left in build directory after distclean: > ./lalapps/src/lalapps/git_version.py > ./lalapps/src/lalapps/git_version.sed > > Why are these files remaining and how should I ensure they are removed > correctly after distclean? > > The appropriate sections of > > bin_PROGRAMS = \ > lalapps_version > > lalapps_version_SOURCES = \ > version.c \ > lalapps.h \ > LALAppsVCSInfo.h > > pkgpython_PYTHON = \ > __init__.py \ > git_version.py > > EXTRA_DIST = \ > __init__.py \ > LALAppsVCSInfo.h.in \ > generate_vcs_info.py\ > git_version.py.in > > BUILT_SOURCES = \ > LALAppsVCSInfo.h \ > git_version.py \ > git_version.sed > It is proper and correct that "make distcheck" fails loudly: you have a botched setup, and 'distcheck' is doing its work in catching and reporting it.
Is 'git_version.sed' intended to be distributed? If yes, you must place it in EXTRA_DIST (and you have an usage error in that you've not done so). On the other hand, if 'git_version.sed' is *not* intended to be distributed, you have an even more serious usage error, both in that 'git_version.sed' is not cleaned by "make clean" (all the undistributed generated files should be), and in that the distributed files 'LALAppsVCSInfo.h' and 'git_version.py' depend on an undistributed file ('git_version.sed' in this case). > LALAppsVCSInfo.h: LALAppsVCSInfo.h.in git_version.sed > $(AM_V_GEN)sed -f git_version.sed $(srcdir)/LALAppsVCSInfo.h.in > >LALAppsVCSInfo.h > > git_version.py: git_version.py.in git_version.sed > $(AM_V_GEN)sed -f git_version.sed $(srcdir)/git_version.py.in > > git_version.py > > git_version.sed: $(srcdir)/generate_vcs_info.py > @$(PYTHON) $(srcdir)/generate_vcs_info.py LALApps $(srcdir) $$PWD > > Cheers > > Adam > HTH, Stefano