Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add an admittedly poor RPM spec to build an admittedly poor RPM.

Fixes welcome...
  • Loading branch information...
commit 300486fd2e9b67cb42410b17a4bfd16ce12da253 1 parent 5aeb55e
Jan Schaumann authored
Showing with 96 additions and 0 deletions.
  1. +18 −0 rpm/build
  2. +78 −0 rpm/scanmaster.spec
18 rpm/build
@@ -0,0 +1,18 @@
+# A silly little helper script to build the RPM.
+set -e
+name=${1:?"Usage: build <toolname>"}
+sourcedir=$(rpm --showrc | awk '/sourcedir/ { print $NF }')
+rpmdir="$(rpm --showrc | awk '/^rpmdir/ { print $NF }')/noarch"
+version=$(awk '/define version/ { print $NF }' ${name}.spec)
+mkdir -p ${tdir}
+echo "=> Copying sources..."
+( cd .. && pax -rw . ${tdir}/ )
+echo "=> Creating source tarball under ${sourcedir}..."
+( cd ${tdir}/.. && tar zcf ${sourcedir}/${name}-${version}.tar.gz ${name}-${version} )
+echo "=> Building RPM..."
+rpm --quiet --buildarch noarch --clean -bb ${name}.spec
+echo "=> RPM built: ${rpmdir}/$(ls -rt ${rpmdir} | tail -1)"
78 rpm/scanmaster.spec
@@ -0,0 +1,78 @@
+%define name scanmaster
+%define release 1
+%define version 3.3.0
+%define mybuilddir %{builddir}/%{name}-%{version}-root
+BuildRoot: %{mybuilddir}
+Summary: the scanmaster suite of scripts
+License: BSD
+Name: %{name}
+Version: %{version}
+Release: %{release}
+Source: %{name}-%{version}.tar.gz
+Prefix: /usr
+Group: Development/Tools
+Requires: expect python
+scanmaster is a set of scripts that allow you to ssh to a very large
+number of hosts in parallel to run an arbitrary script on the remote side.
+It works best if the scans can take advantage of a set of scanslave nodes
+with access to shared NFS space, though that is not a hard requirement.
+This is an admittedly poor RPM. Fixes and corrections would be most
+welcome. Please contact
+%setup -q
+mkdir -p %{mybuilddir}/usr/local/bin
+mkdir -p %{mybuilddir}/usr/local/share/man/man1
+mkdir -p %{mybuilddir}/usr/local/share/scanmaster/helpers
+install -c -m 555 src/autopw %{mybuilddir}/usr/local/bin/autopw
+install -c -m 555 src/checkhosts %{mybuilddir}/usr/local/bin/checkhosts
+install -c -m 555 src/scanhosts %{mybuilddir}/usr/local/bin/scanhosts
+install -c -m 555 src/scanmaster %{mybuilddir}/usr/local/bin/scanmaster
+install -c -m 555 src/scanslave %{mybuilddir}/usr/local/bin/scanslave
+install -c -m 555 src/ %{mybuilddir}/usr/local/bin/tkill
+install -c -m 555 helpers/generic-aggregator %{mybuilddir}/usr/local/share/scanmaster/helpers/generic-aggregator
+install -c -m 555 helpers/generic-post %{mybuilddir}/usr/local/share/scanmaster/helpers/generic-post
+install -c -m 444 doc/autopw.1 %{mybuilddir}/usr/local/share/man/man1/autopw.1
+install -c -m 444 doc/checkhosts.1 %{mybuilddir}/usr/local/share/man/man1/checkhosts.1
+install -c -m 444 doc/scanhosts.1 %{mybuilddir}/usr/local/share/man/man1/scanhosts.1
+install -c -m 444 doc/scanmaster.1 %{mybuilddir}/usr/local/share/man/man1/scanmaster.1
+install -c -m 444 doc/scanslave.1 %{mybuilddir}/usr/local/share/man/man1/scanslave.1
+install -c -m 444 doc/tkill.1 %{mybuilddir}/usr/local/share/man/man1/tkill.1
+install -c -m 444 CHANGES %{mybuilddir}/usr/local/share/scanmaster/CHANGES
+install -c -m 444 LICENSE %{mybuilddir}/usr/local/share/scanmaster/LICENSE
+install -c -m 444 README %{mybuilddir}/usr/local/share/scanmaster/README
+%attr(0555,root,root) /usr/local/bin/autopw
+%attr(0555,root,root) /usr/local/bin/checkhosts
+%attr(0555,root,root) /usr/local/bin/scanhosts
+%attr(0555,root,root) /usr/local/bin/scanmaster
+%attr(0555,root,root) /usr/local/bin/scanslave
+%attr(0555,root,root) /usr/local/bin/tkill
+%attr(0555,root,root) /usr/local/share/scanmaster/helpers/generic-aggregator
+%attr(0555,root,root) /usr/local/share/scanmaster/helpers/generic-post
+%doc /usr/local/share/man/man1/autopw.1
+%doc /usr/local/share/man/man1/checkhosts.1
+%doc /usr/local/share/man/man1/scanhosts.1
+%doc /usr/local/share/man/man1/scanmaster.1
+%doc /usr/local/share/man/man1/scanslave.1
+%doc /usr/local/share/man/man1/tkill.1
+%doc /usr/local/share/scanmaster/CHANGES
+%doc /usr/local/share/scanmaster/LICENSE
+%doc /usr/local/share/scanmaster/README
Please sign in to comment.
Something went wrong with that request. Please try again.