Commit 0c19503a authored by Mark Wagie's avatar Mark Wagie
Browse files

[pkg-upd] 515.48.07-2

- Add patch for FS#74886
parent a4c4239f
......@@ -4,7 +4,7 @@
pkgname=nvidia-open-dkms
pkgver=515.48.07
pkgrel=1
pkgrel=2
pkgdesc="NVIDIA open kernel modules"
arch=('x86_64')
url="https://github.com/NVIDIA/open-gpu-kernel-modules"
......@@ -15,8 +15,10 @@ options=('!lto' '!buildflags')
provides=('nvidia-open' 'NVIDIA-MODULE')
conflicts=('nvidia-open' 'NVIDIA-MODULE')
source=("$pkgname-$pkgver.tar.gz::https://github.com/NVIDIA/open-gpu-kernel-modules/archive/refs/tags/${pkgver}.tar.gz"
'nvidia-open-gcc-ibt-sls.patch'
'andy.pgp') # Andy Ritger <aritger@nvidia.com>
sha512sums=('b5f8b608343c93e0755d0c847d472a68f773c9d9ffb268462489d3d4aad3ab0abe8fb11860ec637abea135bda4eef55c4ffd00d4f817fa48161b5908a09bdf34'
'a8821f36c7515bfe4f50d7e3d15a6a8464ec833ca19818d674e300199f3867971f6fba35e1a357fa8ced08cc91d36c2f7fb37cb247bcbf18fa706f97916639b5'
'a1e1ee8bec37158dcdcf4f6b16c1e1faf746f8fb676a276590712bb039c6f761797a8550b9545e68421b0388f80804565839e8cef518577580c7193cfa7dfc27')
prepare() {
......@@ -25,6 +27,9 @@ prepare() {
--tag ${pkgver} --prefix open-gpu-kernel-modules-${pkgver} \
https://github.com/NVIDIA/open-gpu-kernel-modules.git ../${pkgname}-${pkgver}.tar.gz
# Fix for https://bugs.archlinux.org/task/74886
patch -Np1 --no-backup-if-mismatch -i "$srcdir"/nvidia-open-gcc-ibt-sls.patch
# Attempt to make this reproducible
sed -i "s/^HOSTNAME.*/HOSTNAME = echo manjarolinux"/ utils.mk
sed -i "s/^WHOAMI.*/WHOAMI = echo manjarolinux-builder"/ utils.mk
......
diff --git a/src/nvidia-modeset/Makefile b/src/nvidia-modeset/Makefile
index c63b86b..a67d2fc 100644
--- a/src/nvidia-modeset/Makefile
+++ b/src/nvidia-modeset/Makefile
@@ -95,7 +95,8 @@ CFLAGS += -ffunction-sections
CFLAGS += -fdata-sections
CFLAGS += -ffreestanding
-CONDITIONAL_CFLAGS := $(call TEST_CC_ARG, -fcf-protection=none)
+CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -fcf-protection=branch)
+CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -mharden-sls=all)
CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -Wformat-overflow=2)
CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -Wformat-truncation=1)
ifeq ($(TARGET_ARCH),x86_64)
diff --git a/src/nvidia/Makefile b/src/nvidia/Makefile
index 9bdb826..3f1e330 100644
--- a/src/nvidia/Makefile
+++ b/src/nvidia/Makefile
@@ -119,7 +119,8 @@ CFLAGS += -fdata-sections
NV_KERNEL_O_LDFLAGS += --gc-sections
EXPORTS_LINK_COMMAND = exports_link_command.txt
-CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -fcf-protection=none)
+CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -fcf-protection=branch -mindirect-branch-register)
+CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -mharden-sls=all)
ifeq ($(TARGET_ARCH),x86_64)
CONDITIONAL_CFLAGS += $(call TEST_CC_ARG, -mindirect-branch-register)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment