]> repo.cephalix.eu Git - template-old.git/commitdiff
Make Makefile robust if there is no previus version. master
authorbuildmaster <buildmaster@git.cephalix.eu>
Mon, 25 Nov 2019 13:15:14 +0000 (14:15 +0100)
committerbuildmaster <buildmaster@git.cephalix.eu>
Mon, 25 Nov 2019 13:15:14 +0000 (14:15 +0100)
Makefile

index b439bf34e605df728802ee59b7be03b1771dc116..6035812e0b923a558228f999191f132ee3e51a08 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -21,8 +21,7 @@ package:
        rm -rf oss-pkg-$(PACKAGE)
        mv  oss-pkg-$(PACKAGE).tar.bz2  /usr/src/packages/SOURCES/
        rpmbuild -bb oss-pkg-$(PACKAGE).spec
-       cp /usr/src/packages/RPMS/noarch/oss-pkg-$(PACKAGE)-$(VERSION)-$(NRELEASE).noarch.rpm $(REPO)/noarch
-       for i in $(REPO)/noarch/oss-pkg-$(PACKAGE)-$(VERSION)-*.rpm; do test -e $$i && rm $$i; done 
+       find $(REPO)/noarch -name oss-pkg-$(PACKAGE)-$(VERSION)-*.rpm*  -exec rm {} \;
        mv /usr/src/packages/RPMS/noarch/oss-pkg-$(PACKAGE)-$(VERSION)-$(NRELEASE).noarch.rpm $(REPO)/noarch
        echo $(NRELEASE) > RELEASE
        git commit -a -m "New release"