]> granicus.if.org Git - procps-ng/commitdiff
Makefile.am fixes
authorCraig Small <csmall@enc.com.au>
Sun, 20 May 2012 07:27:14 +0000 (17:27 +1000)
committerCraig Small <csmall@enc.com.au>
Sun, 20 May 2012 07:27:14 +0000 (17:27 +1000)
Two problems.
1) skill/snice : distribution doesnt mean install
If you don't set your configure flags right, you dont install the
skill/snice man pages which means you will break any subsequent compiles
with the flags enabled. Man pages not to be installed should still be
distributed.

2) The git version into Makefile.am breaks under certain conditions.
The easy break for this is:
  touch aclocal.m4
  make

We need this script added plus some dist hook magic that got left out.

Makefile.am

index ec2f12af1258a067beb6c2bb0879534179cadbbb..45aad49b3d5414d64c99d2eeb4d78dcc039d1268 100644 (file)
@@ -43,10 +43,21 @@ dist_man_MANS = \
        vmstat.8 \
        w.1
 
+EXTRA_DIST = \
+       autogen.sh \
+       contrib \
+       COPYING.LIB \
+       misc/git-version-gen \
+       Documentation/CodingStyle \
+       Documentation/TODO \
+       $(sysconf_DATA)
+
 if BUILD_KILL
 bin_PROGRAMS = kill
 dist_man_MANS += kill.1
 kill_SOURCES = skill.c $(top_srcdir)/lib/strutils.c $(top_srcdir)/lib/fileutils.c
+else
+  EXTRA_DIST += kill.1
 endif
 
 if WITH_NCURSES
@@ -71,6 +82,10 @@ snice_SOURCES = skill.c $(top_srcdir)/lib/strutils.c $(top_srcdir)/lib/fileutils
 dist_man_MANS += \
        skill.1 \
        snice.1
+else
+  EXTRA_DIST += \
+       skill.1 \
+       snice.1
 endif
 
 free_SOURCES = free.c $(top_srcdir)/lib/strutils.c $(top_srcdir)/lib/fileutils.c
@@ -88,15 +103,14 @@ if EXAMPLE_FILES
 sysconf_DATA = sysctl.conf
 endif
 
-EXTRA_DIST = \
-       autogen.sh \
-       contrib \
-       COPYING.LIB \
-       Documentation/CodingStyle \
-       Documentation/TODO \
-       $(sysconf_DATA)
-
 procpsngdir = $(docdir)
 dist_procpsng_DATA = \
        Documentation/BUGS \
        Documentation/FAQ
+
+BUILT_SOURCES = $(top_srcdir)/.version
+$(top_srcdir)/.version:
+       echo $(VERSION) > $@-t && mv $@-t $@
+dist-hook:
+       echo $(VERSION) > $(distdir)/.tarball-version
+