Fix distclean to correctly handle Centos 92/592/3
authorEd Warnicke <eaw@cisco.com>
Tue, 22 Mar 2016 17:52:22 +0000 (12:52 -0500)
committerGerrit Code Review <gerrit@fd.io>
Fri, 25 Mar 2016 20:37:40 +0000 (20:37 +0000)
Change-Id: I3f930306e9f384011687d2ce88052639df0d966b
Signed-off-by: Ed Warnicke <eaw@cisco.com>
build-root/Makefile

index 34d6c9d..a7d8943 100644 (file)
@@ -1175,8 +1175,9 @@ distclean:
        rm -rf $(MU_BUILD_ROOT_DIR)/$(IMAGES_PREFIX)*
        rm -rf $(TOOL_INSTALL_DIR)
        rm -rf $(MU_BUILD_ROOT_DIR)/*.deb
+       rm -rf $(MU_BUILD_ROOT_DIR)/*.rpm
        rm -rf $(MU_BUILD_ROOT_DIR)/*.changes
-       (cd $(MU_BUILD_ROOT_DIR)/deb/;debian/rules clean)
+       if [ -e /usr/bin/dh ];then (cd $(MU_BUILD_ROOT_DIR)/deb/;debian/rules clean); fi
        rm -f $(MU_BUILD_ROOT_DIR)/deb/debian/*.install
        rm -f $(MU_BUILD_ROOT_DIR)/deb/debian/*.dkms
        rm -f $(MU_BUILD_ROOT_DIR)/deb/debian/changelog