launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #00146
make clean, make distclean
Hi everyone,
So I've noticed some people have had problems with the initial build, and the
first thing they try is 'make clean'. However, this doesn't do what they
expect: instead of resetting the build, it just resets the application state.
Subsequent attempts to use 'make' still fail, because the build artifacts are
still broken.
So, to make things easier for our developers, should we follow a more standard
set of behaviours for our Makefile targets?
From the GNU Coding Standards: Standard Targets:
http://www.gnu.org/prep/standards/html_node/Standard-Targets.html#Standard-Targets
'clean'
Delete all files in the current directory that are normally created by building
the program. Also delete files in other directories if they are created by this
makefile. However, don't delete the files that record the configuration. Also
preserve files that could be made by building, but normally aren't because the
distribution comes with them.
'distclean'
Delete all files in the current directory (or created by this makefile) that are
created by configuring or building the program. If you have unpacked the source
and built the program without creating any other files, ‘make distclean’ should
leave only the files that were in the distribution.
The standard defines 'mostlyclean' and 'maintainer-clean' targets as well.
As an example of how this would help, when someone tells us "It says I have an
error with foo.egg", we can simply tell them to run 'make distclean; make', and
everything will be reset as expected.
Should we make this change?
Maris
Attachment:
signature.asc
Description: OpenPGP digital signature
Follow ups