From ea782a8ab7f2e227415d48b933bae87ad9a471ea Mon Sep 17 00:00:00 2001 From: Levente Polyak Date: Tue, 3 Jan 2023 23:16:28 +0100 Subject: [PATCH] makepkg.conf: enable rust debuginfo This enables DEBUG_RUSTFLAGS with the appropriate debuginfo settings. The empty RUSTFLAGS variable is required workaround to avoid double compilation during package function call. The issue is that the behavior of the current implementation of buildenv_debugflags is not idempotent, so consecutive calls will append the same flags again leading to cargo consider the build inputs to have changed. Signed-off-by: Levente Polyak --- config/makepkg/x86_64.conf | 4 ++-- config/makepkg/x86_64_v3.conf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index 43215af..41fd6b0 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -46,13 +46,13 @@ CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" LTOFLAGS="-flto=auto" -#RUSTFLAGS="-C opt-level=2" +RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems #MAKEFLAGS="-j2" #-- Debugging flags DEBUG_CFLAGS="-g" DEBUG_CXXFLAGS="$DEBUG_CFLAGS" -#DEBUG_RUSTFLAGS="-C debuginfo=2" +DEBUG_RUSTFLAGS="-C debuginfo=2" ######################################################################### # BUILD ENVIRONMENT diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index d9405d8..3c9d20d 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -46,13 +46,13 @@ CFLAGS="-march=x86-64-v3 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" LTOFLAGS="-flto=auto" -#RUSTFLAGS="-C opt-level=2" +RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems #MAKEFLAGS="-j2" #-- Debugging flags DEBUG_CFLAGS="-g" DEBUG_CXXFLAGS="$DEBUG_CFLAGS" -#DEBUG_RUSTFLAGS="-C debuginfo=2" +DEBUG_RUSTFLAGS="-C debuginfo=2" ######################################################################### # BUILD ENVIRONMENT