diff --git a/linux-cachyos-bmq/PKGBUILD b/linux-cachyos-bmq/PKGBUILD index 762f05e7..1ffbd494 100644 --- a/linux-cachyos-bmq/PKGBUILD +++ b/linux-cachyos-bmq/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-bmq} +: "${_cpusched:=bmq}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,52 +95,52 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos-bore/PKGBUILD b/linux-cachyos-bore/PKGBUILD index 428aeaff..5cade5da 100644 --- a/linux-cachyos-bore/PKGBUILD +++ b/linux-cachyos-bore/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-bore} +: "${_cpusched:=bore}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,52 +95,52 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos-deckify/PKGBUILD b/linux-cachyos-deckify/PKGBUILD index 9806afe0..92c4d0da 100644 --- a/linux-cachyos-deckify/PKGBUILD +++ b/linux-cachyos-deckify/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-cachyos} +: "${_cpusched:=cachyos}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,51 +95,51 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos-eevdf/PKGBUILD b/linux-cachyos-eevdf/PKGBUILD index ab75a844..f37e44f9 100644 --- a/linux-cachyos-eevdf/PKGBUILD +++ b/linux-cachyos-eevdf/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-eevdf} +: "${_cpusched:=eevdf}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,52 +95,52 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos-hardened/PKGBUILD b/linux-cachyos-hardened/PKGBUILD index 39100109..531fadf0 100644 --- a/linux-cachyos-hardened/PKGBUILD +++ b/linux-cachyos-hardened/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -21,25 +21,25 @@ _cachy_config=${_cachy_config-y} # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches # 'sched-ext' - select 'sched-ext' Scheduler, based on EEVDF -_cpusched=${_cpusched-hardened} +: "${_cpusched:=hardened}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -49,36 +49,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -86,7 +86,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-madvise} +: "${_hugepage:=madvise}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -96,52 +96,52 @@ _hugepage=${_hugepage-madvise} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" if [[ "$_use_llvm_lto" = "thin" || "$_use_llvm_lto" = "full" ]] && [ "$_use_lto_suffix" = "y" ]; then _pkgsuffix="cachyos-${_cpusched}-lto" diff --git a/linux-cachyos-lts/PKGBUILD b/linux-cachyos-lts/PKGBUILD index d01388ec..ec0b956d 100644 --- a/linux-cachyos-lts/PKGBUILD +++ b/linux-cachyos-lts/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches # 'sched-ext' - select 'sched-ext' Scheduler, based on EEVDF -_cpusched=${_cpusched-cachyos} +: "${_cpusched:=cachyos}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,53 +48,53 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set this to your number of threads you have in your machine otherwise it will default to 320 -_nr_cpus=${_nr_cpus-} +: "${_nr_cpus:=}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Enable multigenerational LRU # ATTENTION - one of three predefined values should be selected! # 'standard' - enable multigenerational LRU # 'stats' - enable multigenerational LRU with stats # 'none' - disable multigenerational LRU -_lru_config=${_lru_config-standard} +: "${_lru_config:=standard}" ### Enable per-VMA locking # ATTENTION - one of three predefined values should be selected! # 'standard' - enable per-VMA locking # 'stats' - enable per-VMA locking with stats # 'none' - disable per-VMA locking -_vma_config=${_vma_config-standard} +: "${_vma_config:=standard}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -102,7 +102,7 @@ _vma_config=${_vma_config-standard} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" ## Enable DAMON _damon=${_damon-} @@ -116,30 +116,30 @@ _damon=${_damon-} # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # # Or use the _use_auto_optimization with _use_auto_optimization=y -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # disable debug to lower the size of the kernel -_disable_debug=${_disable_debug-} +: "${_disable_debug:=}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI @@ -147,27 +147,27 @@ _use_gcc_suffix=${_use_gcc_suffix-} # alter function references to point to a jump table, and won't break # function address equality. # ATTENTION!: kCFI is only available in llvm 16 -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Enable bcachefs -_bcachefs=${_bcachefs-} +: "${_bcachefs:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" if [[ "$_use_llvm_lto" = "thin" || "$_use_llvm_lto" = "full" ]] && [ "$_use_lto_suffix" = "y" ]; then _pkgsuffix="cachyos-lts-lto" diff --git a/linux-cachyos-rc/PKGBUILD b/linux-cachyos-rc/PKGBUILD index c2139998..09805643 100644 --- a/linux-cachyos-rc/PKGBUILD +++ b/linux-cachyos-rc/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-cachyos} +: "${_cpusched:=cachyos}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), lazy, voluntary or none -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,51 +95,51 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-thin} +: "${_use_llvm_lto:=thin}" # Use suffix -lto only when requested by the user # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-} +: "${_use_lto_suffix:=}" # Use suffix -gcc when requested by the user # Enabled by default to show the difference between LTO kernels and GCC kernels -_use_gcc_suffix=${_use_gcc_suffix-y} +: "${_use_gcc_suffix:=y}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # Enable AUTOFDO_CLANG for the first compilation to create a kernel, which can be used for profiling # Workflow: @@ -149,10 +149,10 @@ _build_debug=${_build_debug-} # 3. Profile the kernel and convert the profile, see Generating the Profile for AutoFDO # 4. Put the profile into the sourcedir # 5. Run kernel build again with the _autofdo_profile_name path to profile specified -_autofdo=${_autofdo-} +: "${_autofdo:=}" # Name for the AutoFDO profile -_autofdo_profile_name=${_autofdo_profile_name-} +: "${_autofdo_profile_name:=}" # ATTENTION: Do not modify after this line diff --git a/linux-cachyos-rt-bore/PKGBUILD b/linux-cachyos-rt-bore/PKGBUILD index cf6368a7..17be624a 100644 --- a/linux-cachyos-rt-bore/PKGBUILD +++ b/linux-cachyos-rt-bore/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-rt-bore} +: "${_cpusched:=rt-bore}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,52 +95,52 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos-server/PKGBUILD b/linux-cachyos-server/PKGBUILD index ba692d3f..7ef8dd36 100644 --- a/linux-cachyos-server/PKGBUILD +++ b/linux-cachyos-server/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-} +: "${_cachy_config:=}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-eevdf} +: "${_cpusched:=eevdf}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-300} +: "${_HZ_ticks:=300}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-idle} +: "${_tickrate:=idle}" ## Choose between full(low-latency), voluntary, server -_preempt=${_preempt-server} +: "${_preempt:=server}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-server} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,52 +95,52 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-none} +: "${_use_llvm_lto:=none}" # Use suffix -lto only when requested by the user # Enabled by default. # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-y} +: "${_use_lto_suffix:=y}" # Use suffix -gcc when requested by the user # This was added to facilitate https://github.com/CachyOS/linux-cachyos/issues/286 -_use_gcc_suffix=${_use_gcc_suffix-} +: "${_use_gcc_suffix:=}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # ATTENTION: Do not modify after this line _is_lto_kernel() { diff --git a/linux-cachyos/PKGBUILD b/linux-cachyos/PKGBUILD index 2c44231e..d5b43fda 100644 --- a/linux-cachyos/PKGBUILD +++ b/linux-cachyos/PKGBUILD @@ -9,7 +9,7 @@ # Set these variables to ANYTHING that is not null or choose proper variable to enable them ### Selecting CachyOS config -_cachy_config=${_cachy_config-y} +: "${_cachy_config:=y}" ### Selecting the CPU scheduler # ATTENTION - only one of the following values can be selected: @@ -20,25 +20,25 @@ _cachy_config=${_cachy_config-y} # 'eevdf' - select 'EEVDF Scheduler' # 'rt' - select EEVDF, but includes a series of realtime patches # 'rt-bore' - select Burst-Oriented Response Enhancer, but includes a series of realtime patches -_cpusched=${_cpusched-cachyos} +: "${_cpusched:=cachyos}" ### Tweak kernel options prior to a build via nconfig -_makenconfig=${_makenconfig-} +: "${_makenconfig:=}" ### Tweak kernel options prior to a build via menuconfig -_makemenuconfig=${_makemenuconfig-} +: "${_makemenuconfig:=}" ### Tweak kernel options prior to a build via xconfig -_makexconfig=${_makexconfig-} +: "${_makexconfig:=}" ### Tweak kernel options prior to a build via gconfig -_makegconfig=${_makegconfig-} +: "${_makegconfig:=}" # NUMA is optimized for multi-socket motherboards. # A single multi-core CPU actually runs slower with NUMA enabled. # See, https://bugs.archlinux.org/task/31187 # It seems that in 2023 this is not really a huge regression anymore -_NUMAdisable=${_NUMAdisable-} +: "${_NUMAdisable:=}" # Compile ONLY used modules to VASTLYreduce the number of modules built # and the build time. @@ -48,36 +48,36 @@ _NUMAdisable=${_NUMAdisable-} # This PKGBUILD read the database kept if it exists # # More at this wiki page ---> https://wiki.archlinux.org/index.php/Modprobed-db -_localmodcfg=${_localmodcfg-} +: "${_localmodcfg:=}" # Path to the list of used modules -_localmodcfg_path=${_localmodcfg_path-"$HOME/.config/modprobed.db"} +: "${_localmodcfg_path:="$HOME/.config/modprobed.db"}" # Use the current kernel's .config file # Enabling this option will use the .config of the RUNNING kernel rather than # the ARCH defaults. Useful when the package gets updated and you already went # through the trouble of customizing your config options. NOT recommended when # a new kernel is released, but again, convenient for package bumps. -_use_current=${_use_current-} +: "${_use_current:=}" ### Enable KBUILD_CFLAGS -O3 -_cc_harder=${_cc_harder-y} +: "${_cc_harder:=y}" ### Set performance governor as default -_per_gov=${_per_gov-} +: "${_per_gov:=}" ### Enable TCP_CONG_BBR3 -_tcp_bbr3=${_tcp_bbr3-} +: "${_tcp_bbr3:=}" ### Running with a 1000HZ, 750Hz, 625Hz, 600 Hz, 500Hz, 300Hz, 250Hz and 100Hz tick rate -_HZ_ticks=${_HZ_ticks-1000} +: "${_HZ_ticks:=1000}" ## Choose between perodic, idle or full ### Full tickless can give higher performances in various cases but, depending on hardware, lower consistency. -_tickrate=${_tickrate-full} +: "${_tickrate:=full}" ## Choose between full(low-latency), voluntary or server -_preempt=${_preempt-full} +: "${_preempt:=full}" ### Transparent Hugepages # ATTENTION - one of two predefined values should be selected! @@ -85,7 +85,7 @@ _preempt=${_preempt-full} # 'madvise' - madvise, prevent applications from allocating more memory resources than necessary # More infos here: # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages -_hugepage=${_hugepage-always} +: "${_hugepage:=always}" # CPU compiler optimizations - Defaults to prompt at kernel config if left empty # AMD CPUs : "k8" "k8sse3" "k10" "barcelona" "bobcat" "jaguar" "bulldozer" "piledriver" "steamroller" "excavator" "zen" "zen2" "zen3" "zen4" @@ -95,51 +95,51 @@ _hugepage=${_hugepage-always} # - "native_intel" (use compiler autodetection and will prompt for P6_NOPS - Selecting your arch manually in the list above is recommended instead of this option) # - "generic" (kernel's default - to share the package between machines with different CPU µarch as long as they are x86-64) # -_processor_opt=${_processor_opt-} +: "${_processor_opt:=}" # This does automatically detect your supported CPU and optimizes for it -_use_auto_optimization=${_use_auto_optimization-y} +: "${_use_auto_optimization:=y}" # Clang LTO mode, only available with the "llvm" compiler - options are "none", "full" or "thin". # ATTENTION - one of three predefined values should be selected! # "full: uses 1 thread for Linking, slow and uses more memory, theoretically with the highest performance gains." # "thin: uses multiple threads, faster and uses less memory, may have a lower runtime performance than Full." # "none: disable LTO -_use_llvm_lto=${_use_llvm_lto-thin} +: "${_use_llvm_lto:=thin}" # Use suffix -lto only when requested by the user # y - enable -lto suffix # n - disable -lto suffix # https://github.com/CachyOS/linux-cachyos/issues/36 -_use_lto_suffix=${_use_lto_suffix-} +: "${_use_lto_suffix:=}" # Use suffix -gcc when requested by the user # Enabled by default to show the difference between LTO kernels and GCC kernels -_use_gcc_suffix=${_use_gcc_suffix-y} +: "${_use_gcc_suffix:=y}" # KCFI is a proposed forward-edge control-flow integrity scheme for # Clang, which is more suitable for kernel use than the existing CFI # scheme used by CONFIG_CFI_CLANG. kCFI doesn't require LTO, doesn't # alter function references to point to a jump table, and won't break # function address equality. -_use_kcfi=${_use_kcfi-} +: "${_use_kcfi:=}" # Build the zfs module in to the kernel # WARNING: The ZFS module doesn't build with selected RT sched due to licensing issues. # If you use ZFS, refrain from building the RT kernel -_build_zfs=${_build_zfs-} +: "${_build_zfs:=}" # Builds the nvidia module and package it into a own base # This does replace the requirement of nvidia-dkms -_build_nvidia=${_build_nvidia-} +: "${_build_nvidia:=}" # Builds the open nvidia module and package it into a own base # This does replace the requirement of nvidia-open-dkms # Use this only if you have Turing+ GPU -_build_nvidia_open=${_build_nvidia_open-} +: "${_build_nvidia_open:=}" # Build a debug package with non-stripped vmlinux -_build_debug=${_build_debug-} +: "${_build_debug:=}" # Enable AUTOFDO_CLANG for the first compilation to create a kernel, which can be used for profiling # Workflow: @@ -149,10 +149,10 @@ _build_debug=${_build_debug-} # 3. Profile the kernel and convert the profile, see Generating the Profile for AutoFDO # 4. Put the profile into the sourcedir # 5. Run kernel build again with the _autofdo_profile_name path to profile specified -_autofdo=${_autofdo-} +: "${_autofdo:=}" # Name for the AutoFDO profile -_autofdo_profile_name=${_autofdo_profile_name-} +: "${_autofdo_profile_name:=}" # ATTENTION: Do not modify after this line