]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - tools/testrpm
Bring back RPM test script, tweak makesrcdist to work.
[thirdparty/cups.git] / tools / testrpm
diff --git a/tools/testrpm b/tools/testrpm
new file mode 100755 (executable)
index 0000000..51c0778
--- /dev/null
@@ -0,0 +1,26 @@
+#!/bin/sh
+#
+# Test script for making RPMs...
+#
+
+# Make sure we are running in the right directory...
+if test ! -f tools/testrpm; then
+        echo "Run this script from the top-level CUPS source directory, e.g.:"
+        echo ""
+        echo "    tools/testrpm [rpmbuild options]"
+        echo ""
+        exit 1
+fi
+
+# Strip command-line arguments so we don't create a release tag...
+args="$*"
+shift $#
+
+# Get a snapshot of the current source...
+. tools/makesrcdist
+
+# Build the RPM...
+echo Building rpm...
+#rm -f /usr/src/redhat/RPMS/i386/cups*.rpm
+#rm -f /usr/src/redhat/SRPMS/cups*.rpm
+rpmbuild -ta $args cups-$fileversion-source.tar.bz2