summaryrefslogtreecommitdiff
path: root/contrib/build_rpm.sh
diff options
context:
space:
mode:
authorChandan Kumar (raukadah) <raukadah@gmail.com>2019-11-29 16:28:30 +0530
committerChandan Kumar (raukadah) <raukadah@gmail.com>2019-12-03 07:57:50 +0530
commit1414a063f5f198dd165fcfabc1afd4cb008ba402 (patch)
tree8ba41477f362e8a88848628fe007bfcc05e15bf7 /contrib/build_rpm.sh
parent7f53178a7dc7cfa947896f61a3198cc6e8759eda (diff)
downloadpodman-1414a063f5f198dd165fcfabc1afd4cb008ba402.tar.gz
podman-1414a063f5f198dd165fcfabc1afd4cb008ba402.tar.bz2
podman-1414a063f5f198dd165fcfabc1afd4cb008ba402.zip
Updates on making doc building and debug optional
It changes the podman spec from using with_doc to bcond_without for building docs so that anyone can pass --without doc as well as other rpmbuild args to the build_rpm.sh script to skip building docs. Since go-md2man is not available in CentOS8 repo. without the help fo extra_args, it makes it conditional. It also moves the manpages to a seperate package. Signed-off-by: Chandan Kumar (raukadah) <raukadah@gmail.com>
Diffstat (limited to 'contrib/build_rpm.sh')
-rw-r--r--contrib/build_rpm.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/build_rpm.sh b/contrib/build_rpm.sh
index b2560fb1a..507c03591 100644
--- a/contrib/build_rpm.sh
+++ b/contrib/build_rpm.sh
@@ -22,7 +22,6 @@ declare -a PKGS=(device-mapper-devel \
glib2-devel \
glibc-static \
golang \
- golang-github-cpuguy83-go-md2man \
gpgme-devel \
libassuan-devel \
libseccomp-devel \
@@ -41,14 +40,19 @@ if [ $pkg_manager == "/usr/bin/dnf" ]; then
PKGS+=(btrfs-progs-devel)
fi
+fi
+# golang-github-cpuguy83-go-md2man is needed for building man pages
+# It is not available by default in CentOS 8 making it optional
+if [ -z "$extra_arg" ]; then
+ PKGS+=(golang-github-cpuguy83-go-md2man)
fi
echo ${PKGS[*]}
$pkg_manager install -y ${PKGS[*]}
make -f .copr/Makefile
-rpmbuild --rebuild podman-*.src.rpm
+rpmbuild --rebuild ${extra_arg:-""} podman-*.src.rpm
# Test to make sure the install of the binary works
$pkg_manager -y install ~/rpmbuild/RPMS/x86_64/podman-*.x86_64.rpm