diff options
author | Austin S. Hemmelgarn <austin@netdata.cloud> | 2020-06-12 07:04:44 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-12 07:04:44 -0400 |
commit | f81b19fc242a0e199e10f1d23e2a8adff967e48a (patch) | |
tree | 7a5e3a0500d13b4197b48a71508cfa33f3e47d65 /packaging/makeself/jobs | |
parent | 1bd8a255441de6056a0d51a7bb787f76b590ffb6 (diff) |
Override linker and include paths for static builds. (#9311)
Diffstat (limited to 'packaging/makeself/jobs')
4 files changed, 14 insertions, 9 deletions
diff --git a/packaging/makeself/jobs/50-bash-4.4.18.install.sh b/packaging/makeself/jobs/50-bash-4.4.18.install.sh index f40ad333bb..78ef01006d 100755 --- a/packaging/makeself/jobs/50-bash-4.4.18.install.sh +++ b/packaging/makeself/jobs/50-bash-4.4.18.install.sh @@ -6,7 +6,7 @@ fetch "bash-4.4.18" "http://ftp.gnu.org/gnu/bash/bash-4.4.18.tar.gz" -export PKG_CONFIG_PATH="/opnessl/lib/pkgconfig" +export PKG_CONFIG_PATH="/opnessl-static/lib/pkgconfig" run ./configure \ --prefix="${NETDATA_INSTALL_PATH}" \ diff --git a/packaging/makeself/jobs/50-curl-7.60.0.install.sh b/packaging/makeself/jobs/50-curl-7.60.0.install.sh index f55829b5b8..5c8e7e65ef 100755 --- a/packaging/makeself/jobs/50-curl-7.60.0.install.sh +++ b/packaging/makeself/jobs/50-curl-7.60.0.install.sh @@ -6,9 +6,10 @@ fetch "curl-curl-7_60_0" "https://github.com/curl/curl/archive/curl-7_60_0.tar.gz" -export LDFLAGS="-static" +export CFLAGS="-I/openssl-static/include" +export LDFLAGS="-static -L/openssl-static/lib" export PKG_CONFIG="pkg-config --static" -export PKG_CONFIG_PATH="/opnessl/lib/pkgconfig" +export PKG_CONFIG_PATH="/opnessl-static/lib/pkgconfig" run ./buildconf diff --git a/packaging/makeself/jobs/50-fping-4.2.install.sh b/packaging/makeself/jobs/50-fping-4.2.install.sh index e9212c8db7..72ace60100 100755 --- a/packaging/makeself/jobs/50-fping-4.2.install.sh +++ b/packaging/makeself/jobs/50-fping-4.2.install.sh @@ -6,8 +6,9 @@ fetch "fping-4.2" "https://github.com/schweikert/fping/releases/download/v4.2/fping-4.2.tar.gz" -export CFLAGS="-static" -export PKG_CONFIG_PATH="/opnessl/lib/pkgconfig" +export CFLAGS="-static -I/openssl-static/include" +export LDFLAGS="-static -L/openssl-static/lib" +export PKG_CONFIG_PATH="/opnessl-static/lib/pkgconfig" run ./configure \ --prefix="${NETDATA_INSTALL_PATH}" \ diff --git a/packaging/makeself/jobs/70-netdata-git.install.sh b/packaging/makeself/jobs/70-netdata-git.install.sh index 6a1bedcc33..e822928dc6 100755 --- a/packaging/makeself/jobs/70-netdata-git.install.sh +++ b/packaging/makeself/jobs/70-netdata-git.install.sh @@ -7,23 +7,26 @@ cd "${NETDATA_SOURCE_PATH}" || exit 1 if [ ${NETDATA_BUILD_WITH_DEBUG} -eq 0 ]; then - export CFLAGS="-static -O3" + export CFLAGS="-static -O3 -I/openssl-static/include" else - export CFLAGS="-static -O1 -ggdb -Wall -Wextra -Wformat-signedness -fstack-protector-all -D_FORTIFY_SOURCE=2 -DNETDATA_INTERNAL_CHECKS=1" + export CFLAGS="-static -O1 -ggdb -Wall -Wextra -Wformat-signedness -fstack-protector-all -D_FORTIFY_SOURCE=2 -DNETDATA_INTERNAL_CHECKS=1 -I/openssl-static/include" fi +export LDFLAGS="-static -L/openssl-static/lib" + # We export this to 'yes', installer sets this to .environment. # The updater consumes this one, so that it can tell whether it should update a static install or a non-static one export IS_NETDATA_STATIC_BINARY="yes" # Set eBPF LIBC to "static" to bundle the `-static` variant of the kernel-collector export EBPF_LIBC="static" -export PKG_CONFIG_PATH="/opnessl/lib/pkgconfig" +export PKG_CONFIG_PATH="/opnessl-static/lib/pkgconfig" run ./netdata-installer.sh \ --install "${NETDATA_INSTALL_PARENT}" \ --dont-wait \ - --dont-start-it + --dont-start-it \ + --dont-scrub-cflags-even-though-it-may-break-things # Remove the netdata.conf file from the tree. It has hard-coded sensible defaults builtin. run rm -f "${NETDATA_INSTALL_PATH}/etc/netdata/netdata.conf" |