[Nut-upsdev] NUT and Automake

Peter Selinger selinger at mathstat.dal.ca
Sun Oct 15 23:51:14 UTC 2006


Dear NUT developers,

I have converted NUT's build system to Automake/Libtool. Right now,
the new build system is contained in the "automake" branch, at:

 ssh://svn.debian.org/svn/nut/branches/automake

I plan to merge this into the main branch after a period of testing,
if there are no objections. 

Here are some highlights:

* automatic dependency tracking: no more need to do this statically
  with "gendb" and similar

* flexible multi-platform library support: libupsclient is now built
  and installed as a static and/or dynamic library, depending on what
  the target platform supports.

* new maintainer targets: "make dist" to build a source distribution,
  "make distcheck" to check that it compiles and installs correctly.
  There are also several other useful standardized targets, such as
  "uninstall", "dist-bzip2", "install-strip", "distclean",
  "maintainer-clean", etc.

* support for separate build and read-only source directory: For example, try
	cd /tmp/build
	${NUT_SOURCE}/configure --srcdir=${NUT_SOURCE}
	make

* as before, installation is relocatable via "make DESTDIR=${DIR} install"

* I reworked and simplified the configuration of optional features.
  Instead of specialized "make" targets like "build-usb", "build-lib",
  "install-lib", etc, features are now specified via configuration
  options such as "--with-usb", "--with-lib", and are automatically
  built/installed if selected. Dummy targets are provided for backward
  "compatibility" (many of them just print an error message explaining
  the new way of doing things).

* Some filenames have been standardized; I renamed CHANGES and CREDITS
  to "ChangeLog" and "AUTHORS", respectively, as this used by most
  other packages (and all GNU packages). 

* Files that are generated by aclocal, autoheader, autoconf, automake,
  and ./configure have been removed from SVN. Upon checking out a
  fresh copy from SVN, populate it is follows:

	aclocal -I m4
	autoconf
	autoheader
	automake

  If you have "autoreconf", you can do all of this in a single step:

	autoreconf -v

  Of course, any distribution made by "make dist" already contains the
  necessary files. 

* There is no more include/version.h. The package version is now
  defined in a single place: at the top of configure.in.

* I fixed numerous bugs in configure.in and in the old Makefiles; for
  example, several man pages did not get installed.

* I updated the documentation (INSTALL, README, docs/configure.txt,
  etc) to reflect the new build system. 


I found two files with which I was not sure what to do. They are:

data/evolution500.dev   - what is this for?
drivers/Doxyfile        - this seems to belong to Charles. Perhaps
			  related to auto-generating documentation
			  for the tripplite_usb driver? It probably
			  should go in another directory, and with 
			  a better name. 

Enjoy, and let me know of any bugs/problems! -- Peter



More information about the Nut-upsdev mailing list