From a316b50f88c9269c5fe54ab6854a7f591c0378dd Mon Sep 17 00:00:00 2001 From: Levente Polyak Date: Tue, 19 Sep 2023 01:30:46 +0200 Subject: fix(makepkg.conf): use breezy for the bzr protocol in makepkg.conf Pacman does not resolve provides for the protocol packages, hence we need to switch to the new package name for bzr. Related-to: https://gitlab.archlinux.org/pacman/pacman/-/merge_requests/78 Signed-off-by: Levente Polyak --- config/makepkg/x86_64.conf | 2 +- config/makepkg/x86_64_v3.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'config/makepkg') diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index 41fd6b0..ec19527 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -25,7 +25,7 @@ DLAGENTS=('file::/usr/bin/curl -qgC - -o %o %u' #-- The package required by makepkg to download VCS sources # Format: 'protocol::package' -VCSCLIENTS=('bzr::bzr' +VCSCLIENTS=('bzr::breezy' 'fossil::fossil' 'git::git' 'hg::mercurial' diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index 3c9d20d..94e3b78 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -25,7 +25,7 @@ DLAGENTS=('file::/usr/bin/curl -qgC - -o %o %u' #-- The package required by makepkg to download VCS sources # Format: 'protocol::package' -VCSCLIENTS=('bzr::bzr' +VCSCLIENTS=('bzr::breezy' 'fossil::fossil' 'git::git' 'hg::mercurial' -- cgit v1.2.3-70-g09d2 From 1535a69af60d2ce82d66866962ecb6b131838869 Mon Sep 17 00:00:00 2001 From: "Jan Alexander Steffens (heftig)" Date: Fri, 1 Sep 2023 23:53:03 +0200 Subject: chore(config): Use one -Wl in LDFLAGS per logical flag This will separate logical flags with whitespace and make it easier to split the flags across multiple lines. Signed-off-by: Jan Alexander Steffens (heftig) --- config/makepkg/x86_64.conf | 2 +- config/makepkg/x86_64_v3.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'config/makepkg') diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index ec19527..9307661 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -44,7 +44,7 @@ CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" -LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" +LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now" LTOFLAGS="-flto=auto" RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index 94e3b78..01e206d 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -44,7 +44,7 @@ CFLAGS="-march=x86-64-v3 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" -LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" +LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now" LTOFLAGS="-flto=auto" RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems -- cgit v1.2.3-70-g09d2 From c356995dc19b3dfe944920a5864f9d3ffd5f9b6f Mon Sep 17 00:00:00 2001 From: "Jan Alexander Steffens (heftig)" Date: Fri, 1 Sep 2023 23:53:03 +0200 Subject: feat(config): Add -z pack-relative-relocs to LDFLAGS This moves relative relocations from the `.rela.dyn` section into a new `.relr.dyn` section with a significantly more compact encoding, supported since glibc 2.36, GNU Binutils 2.38 and LLVM 15. This can reduce the size of libraries a lot, e.g. the installed size of `libphonenumber` dropped from about 17 MB to 7 MB. For more info, see https://gitlab.archlinux.org/archlinux/rfcs/-/merge_requests/23. Signed-off-by: Jan Alexander Steffens (heftig) --- config/makepkg/x86_64.conf | 3 ++- config/makepkg/x86_64_v3.conf | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'config/makepkg') diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index 9307661..e258e07 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -44,7 +44,8 @@ CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" -LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now" +LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ + -Wl,-z,pack-relative-relocs" LTOFLAGS="-flto=auto" RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index 01e206d..3832b19 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -44,7 +44,8 @@ CFLAGS="-march=x86-64-v3 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" -LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now" +LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ + -Wl,-z,pack-relative-relocs" LTOFLAGS="-flto=auto" RUSTFLAGS="" #-- Make Flags: change this for DistCC/SMP systems -- cgit v1.2.3-70-g09d2 From c79a99314822fe4238b66f92c81b288208073a24 Mon Sep 17 00:00:00 2001 From: kpcyrd Date: Tue, 5 Sep 2023 16:37:28 +0200 Subject: feat(makepkg.conf): Increase _FORTIFY_SOURCE level to 3 RFC: https://rfc.archlinux.page/0017-increase-fortification-level/ --- config/makepkg/x86_64.conf | 2 +- config/makepkg/x86_64_v3.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'config/makepkg') diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index e258e07..0591c48 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -41,7 +41,7 @@ CHOST="x86_64-pc-linux-gnu" #-- Compiler and Linker Flags #CPPFLAGS="" CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ - -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ + -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index 3832b19..32e5067 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -41,7 +41,7 @@ CHOST="x86_64-pc-linux-gnu" #-- Compiler and Linker Flags #CPPFLAGS="" CFLAGS="-march=x86-64-v3 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ - -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \ + -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security \ -fstack-clash-protection -fcf-protection" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ -- cgit v1.2.3-70-g09d2 From 7a9ef3bc57e90ec97c67e3710ba8c7f4d48bbe1c Mon Sep 17 00:00:00 2001 From: "Frederik “Freso” S. Olesen" Date: Wed, 14 Feb 2024 08:38:48 +0100 Subject: feat(makepkg.conf): Add no-omit-frame-pointer flags by default RFC-26 proposes to add -fno-omit-frame-pointer and -mno-omit-leaf-frame-pointer to the default compilation flags to improve the effectiveness of profiling and debugging tools. See https://rfc.archlinux.page/0026-fno-omit-frame-pointer/ --- config/makepkg/x86_64.conf | 5 +++-- config/makepkg/x86_64_v3.conf | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'config/makepkg') diff --git a/config/makepkg/x86_64.conf b/config/makepkg/x86_64.conf index 0591c48..7f3ba07 100644 --- a/config/makepkg/x86_64.conf +++ b/config/makepkg/x86_64.conf @@ -42,12 +42,13 @@ CHOST="x86_64-pc-linux-gnu" #CPPFLAGS="" CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security \ - -fstack-clash-protection -fcf-protection" + -fstack-clash-protection -fcf-protection \ + -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ -Wl,-z,pack-relative-relocs" LTOFLAGS="-flto=auto" -RUSTFLAGS="" +RUSTFLAGS="-Cforce-frame-pointers=yes" #-- Make Flags: change this for DistCC/SMP systems #MAKEFLAGS="-j2" #-- Debugging flags diff --git a/config/makepkg/x86_64_v3.conf b/config/makepkg/x86_64_v3.conf index 32e5067..8f0b4f9 100644 --- a/config/makepkg/x86_64_v3.conf +++ b/config/makepkg/x86_64_v3.conf @@ -42,12 +42,13 @@ CHOST="x86_64-pc-linux-gnu" #CPPFLAGS="" CFLAGS="-march=x86-64-v3 -mtune=generic -O2 -pipe -fno-plt -fexceptions \ -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security \ - -fstack-clash-protection -fcf-protection" + -fstack-clash-protection -fcf-protection \ + -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer" CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS" LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \ -Wl,-z,pack-relative-relocs" LTOFLAGS="-flto=auto" -RUSTFLAGS="" +RUSTFLAGS="-Cforce-frame-pointers=yes" #-- Make Flags: change this for DistCC/SMP systems #MAKEFLAGS="-j2" #-- Debugging flags -- cgit v1.2.3-70-g09d2