-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
package/nvidia-persistenced: new package
NVIDIA driver persistence daemon. Signed-off-by: Raphael Pavlidis <raphael.pavlidis@gmail.com> [Arnout: - disable on BR2_STATIC_LIBS; - only depend on tirpc if toolchain doesn't have RPC; - use unstripped binary - the strip support in the makefile is utterly broken (and we anyway strip in target-finalize); - define NVIDIA_PERSISTENCED_USERS directly rather than with another variable; - install all the systemd stuff in NVIDIA_PERSISTENCED_INSTALL_INIT_SYSTEMD. ] Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
- Loading branch information
Showing
6 changed files
with
67 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
config BR2_PACKAGE_NVIDIA_PERSISTENCED | ||
bool "nvidia-persistenced" | ||
depends on BR2_USE_MMU # fork() | ||
depends on !BR2_STATIC_LIBS # dlfcn.h | ||
depends on BR2_TOOLCHAIN_HAS_THREADS # libtirpc | ||
select BR2_PACKAGE_LIBTIRPC if !BR2_TOOLCHAIN_HAS_NATIVE_RPC | ||
help | ||
NVIDIA driver persistence daemon. | ||
|
||
https://github.com/NVIDIA/nvidia-persistenced | ||
|
||
comment "nvidia-persistenced needs a toolchain w/ threads, dynamic libs" | ||
depends on BR2_USE_MMU | ||
depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
u nvidia-persistenced - 'NVIDIA Persistence Daemon' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Locally computed: | ||
sha256 b84fb8eb86127a725d0134a2c64a64e7844e125dece137e7fe8adf8a33cbe817 nvidia-persistenced-515.48.07.tar.gz | ||
sha256 279d814320adc07ca5a4ee101a0b428ddf22a6f3513b8c051f9eb7be47b2e797 COPYING |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
################################################################################ | ||
# | ||
# nvidia-persistenced | ||
# | ||
################################################################################ | ||
|
||
NVIDIA_PERSISTENCED_VERSION = 515.48.07 | ||
NVIDIA_PERSISTENCED_SITE = $(call github,NVIDIA,nvidia-persistenced,$(NVIDIA_PERSISTENCED_VERSION)) | ||
NVIDIA_PERSISTENCED_LICENSE = MIT | ||
NVIDIA_PERSISTENCED_LICENSE_FILES = COPYING | ||
|
||
NVIDIA_PERSISTENCED_DEPENDENCIES = host-pkgconf | ||
|
||
ifeq ($(BR2_PACKAGE_LIBTIRPC),y) | ||
NVIDIA_PERSISTENCED_DEPENDENCIES += libtirpc | ||
endif | ||
|
||
define NVIDIA_PERSISTENCED_BUILD_CMDS | ||
$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \ | ||
OUTPUTDIR=. ./nvidia-persistenced.unstripped | ||
endef | ||
|
||
define NVIDIA_PERSISTENCED_INSTALL_TARGET_CMDS | ||
$(INSTALL) -D -m 0755 $(@D)/nvidia-persistenced.unstripped \ | ||
$(TARGET_DIR)/usr/bin/nvidia-persistenced | ||
endef | ||
|
||
ifeq ($(BR2_PACKAGE_SYSTEMD_SYSUSERS),y) | ||
define NVIDIA_PERSISTENCED_INSTALL_SYSTEMD_SYSUSERS | ||
$(INSTALL) -D -m 0644 $(NVIDIA_PERSISTENCED_PKGDIR)/nvidia-persistenced.conf \ | ||
$(TARGET_DIR)/usr/lib/sysusers.d/nvidia-persistenced.conf | ||
endef | ||
else | ||
define NVIDIA_PERSISTENCED_USERS | ||
nvidia-persistenced -1 nvidia-persistenced -1 * - - - NVIDIA Persistence Daemon | ||
endef | ||
endif | ||
|
||
define NVIDIA_PERSISTENCED_INSTALL_INIT_SYSTEMD | ||
$(INSTALL) -D -m 0644 $(@D)/init/systemd/nvidia-persistenced.service.template \ | ||
$(TARGET_DIR)/usr/lib/systemd/system/nvidia-persistenced.service | ||
$(SED) 's/__USER__/nvidia-persistenced/g' \ | ||
$(TARGET_DIR)/usr/lib/systemd/system/nvidia-persistenced.service | ||
$(NVIDIA_PERSISTENCED_INSTALL_SYSTEMD_SYSUSERS) | ||
endef | ||
|
||
$(eval $(generic-package)) |