File prebuild-pandoc.sh of Package rdma-core
#!/bin/bash
TARBALL=$(rpmspec --parse rdma-core.spec | grep Source: | awk '{ print $NF}')
OUTDIR=$(tar tf $TARBALL | head -n 1)
rm -Rf $OUTDIR
tar xf $TARBALL
cd $OUTDIR
mkdir build
cd build
cmake ..
make docs
tar czf ../../prebuilt-pandoc.tgz pandoc-prebuilt