]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Do not include a stray pdns dir in the recursor artifacts
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Mon, 23 Sep 2024 09:21:13 +0000 (11:21 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Mon, 23 Sep 2024 11:15:04 +0000 (13:15 +0200)
This is caused by pdns-recursor matching pdns*, which is intended to select
auth files only.
Not terribly happy with the code duplication, but we would end up in quoting hell otherwise.

builder-support/post-build

index 9e7a9c64b250744a8e502f6219d45ae8384fb71b..b2bc0883156616b9de3abd30511d09a684d63d68 100755 (executable)
@@ -17,15 +17,20 @@ if ! $tar --version | grep -q GNU; then
     exit 1
 fi
 
-for prog in pdns-recursor dnsdist pdns; do
+for prog in pdns-recursor dnsdist; do
   if [ $(find ${SRCDIR}/dist -name "${prog}*" 2>/dev/null | wc -l) -ne 0 ]; then
     dst=${DESTDIR}/${prog}/${BUILDER_VERSION}
     mkdir -p ${dst}
     cp ${BUILDER_TMP}/${BUILDER_VERSION}/sdist/${prog}*.tar.bz2 ${dst}
-    if [ "${prog}" = "pdns" ]; then
-      rm -f ${dst}/pdns-recursor*
-    fi
     tardirname=${prog}-${BUILDER_VERSION}-${BUILDER_TARGET}
     "$tar" -cjf ${dst}/${tardirname}.tar.bz2 --transform="s,.*/,${tardirname}/,g"  $(find ${SRCDIR} -type f)
   fi
 done
+prog=pdns
+if [ $(find ${SRCDIR}/dist -name 'pdns*' -a ! -name 'pdns-recursor*' 2>/dev/null | wc -l) -ne 0 ]; then
+  dst=${DESTDIR}/${prog}/${BUILDER_VERSION}
+  mkdir -p ${dst}
+  cp ${BUILDER_TMP}/${BUILDER_VERSION}/sdist/${prog}*.tar.bz2 ${dst}
+  tardirname=${prog}-${BUILDER_VERSION}-${BUILDER_TARGET}
+  "$tar" -cjf ${dst}/${tardirname}.tar.bz2 --transform="s,.*/,${tardirname}/,g"  $(find ${SRCDIR} -type f)
+fi