GitHub CI: change build system to meson
[tinc] / .ci / package / rpm / build.sh
index b07df47..48f57ad 100755 (executable)
@@ -1,23 +1,16 @@
 #!/bin/bash
 
-set -euo pipefail
+set -euxo pipefail
+
+if ! rpm -qi openssl-devel; then
+  exit 0
+fi
 
 find_tag() {
   git describe --always --tags --match='release-*' "$@"
 }
 
-# CentOS 7 has OpenSSL 1.1 installed in a non-default location.
-if [ -d /usr/include/openssl11 ]; then
-  set -- "$@" --with-openssl-include=/usr/include/openssl11
-fi
-
-if [ -d /usr/lib64/openssl11 ]; then
-  set -- "$@" --with-openssl-lib=/usr/lib64/openssl11
-fi
-
 spec=$HOME/rpmbuild/SPECS/tinc.spec
-configure=$(sh .ci/conf.sh)
-
 version=$(find_tag HEAD | sed 's/-/_/g')
 version=${version//release_/}
 
@@ -28,10 +21,8 @@ rpmdev-setuptree
 
 cp "$(dirname "$0")/tinc.spec" "$spec"
 sed -i "s/__VERSION__/$version/" "$spec"
-sed -i "s#__CONFIGURE_ARGS__#$configure#" "$spec"
 
 git clean -dfx
-autoreconf -fsi
 cp -a . ~/rpmbuild/BUILD
 
 rpmbuild -bb "$spec"