From 54e03641a3399f4bdad9f970d4c9b5dc51b6a8a6 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Tue, 13 Apr 2021 17:18:30 -0400 Subject: sync makepkg.conf with the pacman package Aside for comments, this implements the buildflags RFC from: https://lists.archlinux.org/pipermail/arch-dev-public/2021-March/030374.html https://gitlab.archlinux.org/archlinux/rfcs/-/merge_requests/3 Signed-off-by: Eli Schwartz --- makepkg-x86_64.conf | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/makepkg-x86_64.conf b/makepkg-x86_64.conf index 3a1384f..16a6247 100644 --- a/makepkg-x86_64.conf +++ b/makepkg-x86_64.conf @@ -38,15 +38,20 @@ CARCH="x86_64" CHOST="x86_64-pc-linux-gnu" #-- Compiler and Linker Flags -CPPFLAGS="-D_FORTIFY_SOURCE=2" -CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt" -CXXFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt" +#CPPFLAGS="" +CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ + -Wp,-D_FORTIFY_SOURCE=2,-D_GLIBCXX_ASSERTIONS \ + -Wformat -Werror=format-security \ + -fstack-clash-protection -fcf-protection" +CXXFLAGS="$CFLAGS" LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" +#RUSTFLAGS="-C opt-level=2" #-- Make Flags: change this for DistCC/SMP systems #MAKEFLAGS="-j2" #-- Debugging flags DEBUG_CFLAGS="-g -fvar-tracking-assignments" DEBUG_CXXFLAGS="-g -fvar-tracking-assignments" +#DEBUG_RUSTFLAGS="-C debuginfo=2" ######################################################################### # BUILD ENVIRONMENT @@ -89,7 +94,7 @@ BUILDENV=(!distcc color !ccache check !sign) # OPTIONS=(strip docs !libtool !staticlibs emptydirs zipman purge !debug) -#-- File integrity checks to use. Valid: md5, sha1, sha256, sha384, sha512 +#-- File integrity checks to use. Valid: md5, sha1, sha224, sha256, sha384, sha512, b2 INTEGRITY_CHECK=(md5) #-- Options to be used when stripping binaries. See `man strip' for details. STRIP_BINARIES="--strip-all" -- cgit v1.2.3-54-g00ecf