The dist target in the generated Makefile.in can be used to generate a gzip'd tar file for distribution. The tar file is named based on the PACKAGE and VERSION variables; more precisely it is named package-version.tar.gz. You can use the make variable GZIP_ENV to control how gzip is run. The default setting is -best.
For the most part, the files to distribute are automatically found by Automake: all source files are automatically included in a distribution, as are all Makefile.ams and Makefile.ins. Automake also has a built-in list of commonly used files which, if present in the current directory, are automatically included. This list is printed by automake -help. Also, files which are read by configure (i.e. the source files corresponding to the files specified in the AC_OUTPUT invocation) are automatically distributed.
Still, sometimes there are files which must be distributed, but which are not covered in the automatic rules. These files should be listed in the EXTRA_DIST variable. You can mention files from subdirectories in EXTRA_DIST.
You can also mention a directory in EXTRA_DIST; in this case the entire directory will be recursively copied into the distribution. Please note that this will also copy everything in the directory, including CVS/RCS version control files. We recommend against using this feature.