From ecced2ea1ef750870e479c2a464420cd7325aa37 Mon Sep 17 00:00:00 2001 From: hsmatulisgoogle <69014250+hsmatulisgoogle@users.noreply.github.com> Date: Wed, 17 Feb 2021 14:43:12 -0500 Subject: [PATCH 1/4] Update Makefile --- rpm/Makefile | 6 ------ 1 file changed, 6 deletions(-) diff --git a/rpm/Makefile b/rpm/Makefile index 983f5fe..b2c6b39 100644 --- a/rpm/Makefile +++ b/rpm/Makefile @@ -17,13 +17,7 @@ CURL_VERSION=7.52.1 endif endif -ifeq ($(filter sles%,$(DISTRO)),) # If DISTRO is not sles*. -vendor: - [ -f curl-$(CURL_VERSION).tar.bz2 ] || curl -O https://curl.haxx.se/download/curl-$(CURL_VERSION).tar.bz2 - sha1sum -c curl-$(CURL_VERSION).sha1 -else vendor:;true -endif TOPDIR=/root/rpmbuild From d407c249d993ea12e636af4f3c34294c997991a2 Mon Sep 17 00:00:00 2001 From: hsmatulisgoogle <69014250+hsmatulisgoogle@users.noreply.github.com> Date: Wed, 17 Feb 2021 14:44:25 -0500 Subject: [PATCH 2/4] Delete curl-7.52.1.sha1 --- rpm/curl-7.52.1.sha1 | 1 - 1 file changed, 1 deletion(-) delete mode 100644 rpm/curl-7.52.1.sha1 diff --git a/rpm/curl-7.52.1.sha1 b/rpm/curl-7.52.1.sha1 deleted file mode 100644 index c1c003c..0000000 --- a/rpm/curl-7.52.1.sha1 +++ /dev/null @@ -1 +0,0 @@ -aa9f2300096d806c68c7ba8c50771853d1b43eb4 curl-7.52.1.tar.bz2 From 67eeef766dd963bcd84bd896f82146c48a1c5d62 Mon Sep 17 00:00:00 2001 From: hsmatulisgoogle <69014250+hsmatulisgoogle@users.noreply.github.com> Date: Wed, 17 Feb 2021 14:44:32 -0500 Subject: [PATCH 3/4] Delete curl-7.34.0.sha1 --- rpm/curl-7.34.0.sha1 | 1 - 1 file changed, 1 deletion(-) delete mode 100644 rpm/curl-7.34.0.sha1 diff --git a/rpm/curl-7.34.0.sha1 b/rpm/curl-7.34.0.sha1 deleted file mode 100644 index 8a783d0..0000000 --- a/rpm/curl-7.34.0.sha1 +++ /dev/null @@ -1 +0,0 @@ -548fe1686d01d689f79ed8cedc879309f8f5035b curl-7.34.0.tar.bz2 From 543159de84daf00b1123b8402903de466f6fa965 Mon Sep 17 00:00:00 2001 From: hsmatulisgoogle <69014250+hsmatulisgoogle@users.noreply.github.com> Date: Thu, 18 Mar 2021 11:21:35 -0400 Subject: [PATCH 4/4] Remove curl bundling from stackdriver-agent.spec --- rpm/stackdriver-agent.spec | 36 ------------------------------------ 1 file changed, 36 deletions(-) diff --git a/rpm/stackdriver-agent.spec b/rpm/stackdriver-agent.spec index aee2036..0f2a911 100644 --- a/rpm/stackdriver-agent.spec +++ b/rpm/stackdriver-agent.spec @@ -37,7 +37,6 @@ %define bundle_mongo 1 %define varnish 1 %define java_plugin 1 -%define bundle_curl 1 %define curl_version 7.34.0 %define java_version 1.6.0 %define java_lib_location /usr/lib/jvm/java @@ -64,7 +63,6 @@ %endif %if 0%{?suse_version} > 0 -%define bundle_curl 0 %define java_lib_location /usr/lib64/jvm/java %if 0%{?suse_version} < 1500 %define java_version 1.7.0 @@ -80,11 +78,6 @@ %define redis_flag --enable-redis --with-libhiredis %endif -%if %{bundle_curl} -%define curl_include -Icurl-%{curl_version}/include -%define libcurl_flag --with-libcurl=%{buildroot}/%{_prefix} -%endif - %if %{has_yajl} %define curl_json_flag --enable-curl_json %define gcm_flag --enable-write_gcm @@ -116,11 +109,6 @@ Group: System Environment/Daemons URL: http://www.stackdriver.com/ Source: stackdriver-agent-%{version}.orig.tar.gz -%if %{bundle_curl} -# embed libcurl so we know it's linked against openssl instead of -# nss. this avoids problems of nss leaking with libcurl. sigh. -Source1: curl-%{curl_version}.tar.bz2 -%endif Source200: stackdriver-agent Source201: collectd.conf Source202: stackdriver.sysconfig @@ -141,9 +129,7 @@ BuildRequires: flex BuildRequires: libtool BuildRequires: rpm-build %endif -%if ! %{bundle_curl} BuildRequires: libcurl-devel -%endif %if 0%{?suse_version} > 0 BuildRequires: libmysqlclient-devel %else @@ -249,21 +235,8 @@ Currently includes collectd. %prep %setup -q -n collectd-pristine # update for aarch64 -%if %{bundle_curl} -%setup -q -n collectd-pristine -a 1 -%endif %build -%if %{bundle_curl} -# build libcurl first -pushd curl-%{curl_version} -./configure --prefix=%{buildroot}%{_prefix} --with-ssl --disable-threaded-resolver --enable-ipv6 \ - --with-libidn --disable-shared --enable-static --disable-manual \ - --with-ca-bundle=/etc/pki/tls/certs/ca-bundle.crt -%{__make} %{?_smp_mflags} -%{__make} install -popd -%endif export PATH=%{buildroot}/%{_prefix}/bin:$PATH # re-generate build files @@ -329,15 +302,6 @@ export PATH=%{buildroot}/%{_prefix}/bin:$PATH %install -# we have to reinstall as %%install cleans the buildroot -%if %{bundle_curl} -pushd curl-%{curl_version} -%{__make} install -# now remove things to avoid unpackaged files -rm -rf %{buildroot}/%{_prefix}/bin %{buildroot}/%{_prefix}/man -rm -rf %{buildroot}/%{_prefix}/share %{buildroot}/%{_prefix}/lib*/pkgconfig -popd -%endif %{__rm} -rf contrib/SpamAssassin %{__make} install DESTDIR="%{buildroot}"