Suppress Automake warning about overriding distdir.
[openvswitch] / Makefile.am
index c678d90268edfcfda93375b73e6b2aabaebb8bee..53c65fefd7f3e96274adf8ba7306d50c683bdb15 100644 (file)
@@ -1,4 +1,6 @@
-AUTOMAKE_OPTIONS=foreign
+# The goal of -Wno-syntax here is just to suppress the Automake warning
+# about overriding distdir, below.
+AUTOMAKE_OPTIONS=foreign -Wno-syntax
 ACLOCAL_AMFLAGS = -I m4
 SUBDIRS = \
        lib \
@@ -9,11 +11,21 @@ SUBDIRS = \
        switch \
        tests \
        include \
-       third-party
+       third-party \
+       debian
 if HAVE_EXT
 SUBDIRS += ext
+distdir = $(PACKAGE)+ext-$(VERSION)
 endif
 
 DIST_SUBDIRS = $(SUBDIRS)
 
 EXTRA_DIST = README.hwtables
+
+if HAVE_DPKG_BUILDPACKAGE
+distcheck-hook: 
+       cd $(srcdir) && dpkg-buildpackage -rfakeroot -us -uc
+       cd $(srcdir) && fakeroot ./debian/rules clean
+else
+distcheck-hook: 
+endif