diff --git a/changelog/20519.txt b/changelog/20519.txt new file mode 100644 index 000000000..92f7c2918 --- /dev/null +++ b/changelog/20519.txt @@ -0,0 +1,3 @@ +```release-note:improvement +Add debug symbols back to builds to fix Dynatrace support +``` diff --git a/scripts/ci-helper.sh b/scripts/ci-helper.sh index 7130fd5e3..4e33a8e8a 100755 --- a/scripts/ci-helper.sh +++ b/scripts/ci-helper.sh @@ -154,17 +154,16 @@ function build() { prerelease=$(version_pre) build_date=$(build_date) : "${GO_TAGS:=""}" - : "${KEEP_SYMBOLS:=""}" + : "${REMOVE_SYMBOLS:=""}" # Build our ldflags msg="--> Building Vault v$version, revision $revision, built $build_date" # Keep the symbol and dwarf information by default - # TODO: maybe add REMOVE_SYMBOLS? - if [ -n "$KEEP_SYMBOLS" ]; then + if [ -n "$REMOVE_SYMBOLS" ]; then ldflags="-s -w " else - ldflags="-s -w " + ldflags="" fi ldflags="${ldflags}-X github.com/hashicorp/vault/version.Version=$version -X github.com/hashicorp/vault/version.GitCommit=$revision -X github.com/hashicorp/vault/version.BuildDate=$build_date"