]> granicus.if.org Git - pdns/commitdiff
Build RPMs with protobuf
authorPieter Lexis <pieter.lexis@powerdns.com>
Fri, 8 Jul 2016 07:53:47 +0000 (09:53 +0200)
committerPieter Lexis <pieter.lexis@powerdns.com>
Fri, 8 Jul 2016 08:55:01 +0000 (10:55 +0200)
Fixes #4130

build-scripts/build-dnsdist-rpm

index 5b1d54c7ec0ed251c65f6e101707cda8baffba4d..cf73f9bea7e026c485e996f51a709dbed56aa3d8 100755 (executable)
@@ -44,6 +44,9 @@ INIT_INSTALL='sed -i "s,/^\(ExecStart.*\)dnsdist\(.*\)\$,\1dnsdist -u dnsdist -g
 INIT_FILES='/lib/systemd/system/dnsdist.service'
 INIT_CONFIGURE='--enable-systemd --with-systemd=/lib/systemd/system \'
 
+# CentOS 6 has protobuf, but not a modern enough boost. We defaul to with protobuf
+PROTOBUF_CONFIGURE='--with-protobuf \'
+
 # These two are the same for sysv and systemd (we don't install defaults files at the moment)
 DEFAULTS_INSTALL=''
 DEFAULTS_FILES=''
@@ -66,6 +69,7 @@ if [ -f /etc/redhat-release ]; then
       INIT_INSTALL='install -d -m 755 %{buildroot}/%{_initrddir} && install -m 755 contrib/dnsdist.init.centos6 %{buildroot}/%{_initrddir}/dnsdist'
       INIT_FILES='%{_initrddir}/dnsdist'
       INIT_CONFIGURE='\'
+      PROTOBUF_CONFIGURE='--without-protobuf \'
       SETUP="%setup -n %{name}-${TARBALLVERSION}"
       RPMBUILD_COMMAND="scl enable devtoolset-3 -- ${RPMBUILD_COMMAND}"
       ;;
@@ -106,8 +110,8 @@ ${SETUP}
 %build
 %configure \
   --sysconfdir=/etc/dnsdist \
-  --without-protobuf \
   ${INIT_CONFIGURE}
+  ${PROTOBUF_CONFIGURE}
   ${SODIUM_CONFIGURE}
 
 make