aboutsummaryrefslogtreecommitdiff
path: root/x11/nvidia-driver
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2008-10-20 12:47:09 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2008-10-20 12:47:09 +0000
commitaa047073b2915182dd1f4366931488ab47b3f6e6 (patch)
treebdf7366ea4049078e77e364e28e6c51526be16b2 /x11/nvidia-driver
parentcd5ff2209eecc967ab20e33a9d1129efbc45e440 (diff)
downloadports-aa047073b2915182dd1f4366931488ab47b3f6e6.tar.gz
ports-aa047073b2915182dd1f4366931488ab47b3f6e6.zip
Notes
Diffstat (limited to 'x11/nvidia-driver')
-rw-r--r--x11/nvidia-driver/Makefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/x11/nvidia-driver/Makefile b/x11/nvidia-driver/Makefile
index ee5708617ea0..4b478cdf1472 100644
--- a/x11/nvidia-driver/Makefile
+++ b/x11/nvidia-driver/Makefile
@@ -85,6 +85,12 @@ post-patch: .SILENT
${REINPLACE_CMD} -e '15s,^,#include <sys/priv.h>,' \
${WRKSRC}/src/nvidia_os.c
.endif
+# Switch from suser() to priv_check() API on recent -CURRENT
+.if ${OSVERSION} >= 800049
+ ${REINPLACE_CMD} -e \
+ 's/suser(CURTHREAD)/priv_check(CURTHREAD, PRIV_DRIVER)/' \
+ ${WRKSRC}/src/nvidia_os.c
+.endif
.if defined(WITH_FREEBSD_AGP)
${REINPLACE_CMD} -E 's/undef (NV_SUPPORT_OS_AGP)/define \1/' \
${WRKSRC}/src/nv-freebsd.h