Commit 8134885b authored by Andreas Beckmann's avatar Andreas Beckmann

new upstream release 410.93

parent 90dc574f
nvidia-settings (410.93-1) UNRELEASED; urgency=medium
* New upstream release 410.93.
* Remove reproducibility patches, applied upstream.
-- Andreas Beckmann <anbe@debian.org> Mon, 11 Feb 2019 06:34:02 +0100
nvidia-settings (396.54-1) unstable; urgency=medium
* New upstream release 396.54.
......
From 5c1dffffaae81050e5fc668fcc88478712933458 Mon Sep 17 00:00:00 2001
From: Aaron Plattner <aplattner@nvidia.com>
Date: Fri, 23 Mar 2018 17:13:50 -0700
Subject: [PATCH 1/2] nvidia-settings: Remove $(STAMP_C)
This file is generated at build time and includes the version, builder, and date
of the build. For example,
$ strings /usr/bin/nvidia-settings | grep 'nvidia id'
nvidia id: nvidia-settings: version 396.14 (buildmeister@swio-display-x86-rhel47-09) Mon Mar 19 20:18:47 PDT 2018
This information isn't hugely useful, and makes it difficult for some
distributions to achieve their goal of reproducible builds. Rather than adding a
build-time flag to hard-code this information, just remove it.
See https://github.com/NVIDIA/nvidia-settings/pull/12
---
src/Makefile | 9 +--------
src/command-line.c | 4 +---
src/common-utils/common-utils.h | 2 ++
src/gtk+-2.x/ctkdisplayconfig-utils.c | 4 +---
src/libXNVCtrl/Makefile | 6 +-----
src/libXNVCtrl/utils.mk | 35 ++---------------------------------
utils.mk | 35 ++---------------------------------
7 files changed, 10 insertions(+), 85 deletions(-)
diff --git a/src/Makefile b/src/Makefile
index af7d209..5f42aff 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -124,8 +124,6 @@ VIRTUAL_RESOLUTIONS_DIR ?= $(COMMON_UNIX_DIR)/virtual-resolutions
NVIDIA_SETTINGS = $(OUTPUTDIR)/nvidia-settings
-NVIDIA_SETTINGS_PROGRAM_NAME = "nvidia-settings"
-
NVIDIA_SETTINGS_VERSION := $(NVIDIA_VERSION)
GTK2LIB_NAME = libnvidia-gtk2.so
@@ -212,8 +210,6 @@ SRC += $(addprefix $(COMMON_UTILS_DIR)/,$(COMMON_UTILS_SRC))
include $(VIRTUAL_RESOLUTIONS_DIR)/src.mk
SRC += $(addprefix $(VIRTUAL_RESOLUTIONS_DIR)/,$(VIRTUAL_RESOLUTIONS_SRC))
-SRC += $(STAMP_C)
-
OBJS = $(call BUILD_OBJECT_LIST,$(SRC))
XCP_OBJS = $(call BUILD_OBJECT_LIST,$(XCP_SRC))
@@ -312,9 +308,6 @@ endif
$(foreach src,$(SRC),$(eval $(call DEFINE_OBJECT_RULE,TARGET,$(src))))
$(foreach src,$(XCP_SRC),$(eval $(call DEFINE_OBJECT_RULE,TARGET,$(src))))
-# define the rule to generate $(STAMP_C)
-$(eval $(call DEFINE_STAMP_C_RULE, $(OBJS),$(NVIDIA_SETTINGS_PROGRAM_NAME)))
-
# define the rule to build $(XNVCTRL_ARCHIVE)
$(XNVCTRL_ARCHIVE): build-xnvctrl
@@ -322,7 +315,7 @@ build-xnvctrl:
@$(MAKE) -C $(XNVCTRL_DIR) -f $(XNVCTRL_MAKEFILE)
clean clobber:
- rm -rf $(NVIDIA_SETTINGS) *~ $(STAMP_C) \
+ rm -rf $(NVIDIA_SETTINGS) *~ \
$(OUTPUTDIR)/*.o $(OUTPUTDIR)/*.d \
$(GTK2LIB) $(GTK3LIB) $(GTK2LIB_DIR) $(GTK3LIB_DIR) \
$(IMAGE_HEADERS)
diff --git a/src/command-line.c b/src/command-line.c
index 21dccaf..8c671a5 100644
--- a/src/command-line.c
+++ b/src/command-line.c
@@ -45,12 +45,10 @@ static void print_help(void);
* print_version() - print version information
*/
-extern const char *pNV_ID;
-
static void print_version(void)
{
nv_msg(NULL, "");
- nv_msg(NULL, "%s", pNV_ID);
+ nv_msg(NULL, NV_ID_STRING);
nv_msg(TAB, "The NVIDIA X Server Settings tool.");
nv_msg(NULL, "");
nv_msg(TAB, "This program is used to configure the "
diff --git a/src/common-utils/common-utils.h b/src/common-utils/common-utils.h
index 6ef1d06..7d51910 100644
--- a/src/common-utils/common-utils.h
+++ b/src/common-utils/common-utils.h
@@ -132,4 +132,6 @@ typedef enum {
NV_OPTIONAL_BOOL_TRUE = TRUE
} NVOptionalBool;
+#define NV_ID_STRING PROGRAM_NAME ": version " NVIDIA_VERSION
+
#endif /* __COMMON_UTILS_H__ */
diff --git a/src/gtk+-2.x/ctkdisplayconfig-utils.c b/src/gtk+-2.x/ctkdisplayconfig-utils.c
index 40c9c7c..9f686b2 100644
--- a/src/gtk+-2.x/ctkdisplayconfig-utils.c
+++ b/src/gtk+-2.x/ctkdisplayconfig-utils.c
@@ -4136,8 +4136,6 @@ nvDisplayPtr layout_get_display(const nvLayoutPtr layout,
* Code adapted from nvidia-xconfig
*/
-extern const char *pNV_ID;
-
static void update_banner(XConfigPtr config)
{
static const char *banner =
@@ -4178,7 +4176,7 @@ static void update_banner(XConfigPtr config)
/* add our prefix lines at the start of the comment */
config->comment = g_strconcat(prefix, banner,
- "# ", pNV_ID, "\n",
+ "# " NV_ID_STRING "\n",
(s ? s : ""),
NULL);
if (s) g_free(s);
diff --git a/src/libXNVCtrl/Makefile b/src/libXNVCtrl/Makefile
index e4357fd..6942c3e 100644
--- a/src/libXNVCtrl/Makefile
+++ b/src/libXNVCtrl/Makefile
@@ -46,7 +46,6 @@ CFLAGS += -I $(OUTPUTDIR)
CFLAGS += -DPROGRAM_NAME=\"$(LIBXNVCTRL_PROGRAM_NAME)\"
SRC += NVCtrl.c
-SRC += $(STAMP_C)
OBJS = $(call BUILD_OBJECT_LIST,$(SRC))
@@ -65,9 +64,6 @@ $(LIBXNVCTRL) : $(OBJS)
# define the rule to build each object file
$(foreach src,$(SRC),$(eval $(call DEFINE_OBJECT_RULE,TARGET,$(src))))
-# define the rule to generate $(STAMP_C)
-$(eval $(call DEFINE_STAMP_C_RULE, $(OBJS),$(LIBXNVCTRL_PROGRAM_NAME)))
-
clean:
- rm -rf $(LIBXNVCTRL) *~ $(STAMP_C) \
+ rm -rf $(LIBXNVCTRL) *~ \
$(OUTPUTDIR)/*.o $(OUTPUTDIR)/*.d
diff --git a/src/libXNVCtrl/utils.mk b/src/libXNVCtrl/utils.mk
index 66dbb16..8218e0c 100644
--- a/src/libXNVCtrl/utils.mk
+++ b/src/libXNVCtrl/utils.mk
@@ -74,9 +74,7 @@ PRINTF ?= printf
MKDIR ?= mkdir -p
RM ?= rm -f
TOUCH ?= touch
-WHOAMI ?= whoami
HARDLINK ?= ln -f
-HOSTNAME_CMD ?= hostname
DATE ?= date
GZIP_CMD ?= gzip
CHMOD ?= chmod
@@ -214,6 +212,8 @@ ifndef NVIDIA_VERSION
$(error NVIDIA_VERSION undefined)
endif
+CFLAGS += -DNVIDIA_VERSION=\"$(NVIDIA_VERSION)\"
+
##############################################################################
# Several of the functions below take an argument that indicates if
@@ -425,37 +425,6 @@ define DEBUG_INFO_RULES
endef
##############################################################################
-# STAMP_C - this is a source file that is generated during the build
-# to capture information about the build environment for the utility.
-#
-# The DEFINE_STAMP_C_RULE function is used to define the rule for
-# generating STAMP_C. First argument is a list of dependencies for
-# STAMP_C (g_stamp.o is filtered out of the list); second argument is
-# the name of the program being built.
-#
-# The includer of utils.mk should add $(STAMP_C) to its list of source
-# files
-##############################################################################
-
-STAMP_C = $(OUTPUTDIR)/g_stamp.c
-
-define DEFINE_STAMP_C_RULE
-
- $$(STAMP_C): $$(filter-out \
- $$(call BUILD_OBJECT_LIST,$$(STAMP_C)),$(1)) \
- $$(VERSION_MK)
- @ $$(RM) $$@
- @ $$(PRINTF) "%s" "const char NV_ID[] = \"nvidia id: " >> $$@
- @ $$(PRINTF) "%s" "$(2): " >> $$@
- @ $$(PRINTF) "%s" "version $$(NVIDIA_VERSION) " >> $$@
- @ $$(PRINTF) "%s" "($$(shell $$(WHOAMI))" >> $$@
- @ $$(PRINTF) "%s" "@$$(shell $$(HOSTNAME_CMD))) " >> $$@
- @ $$(PRINTF) "%s\n" "$$(shell $(DATE))\";" >> $$@
- @ $$(PRINTF) "%s\n" "const char *pNV_ID = NV_ID + 11;" >> $$@
-
-endef
-
-##############################################################################
# Define rules that can be used for embedding a file into an ELF object that
# contains the raw contents of that file and symbols pointing to the embedded
# data.
diff --git a/utils.mk b/utils.mk
index 66dbb16..8218e0c 100644
--- a/utils.mk
+++ b/utils.mk
@@ -74,9 +74,7 @@ PRINTF ?= printf
MKDIR ?= mkdir -p
RM ?= rm -f
TOUCH ?= touch
-WHOAMI ?= whoami
HARDLINK ?= ln -f
-HOSTNAME_CMD ?= hostname
DATE ?= date
GZIP_CMD ?= gzip
CHMOD ?= chmod
@@ -214,6 +212,8 @@ ifndef NVIDIA_VERSION
$(error NVIDIA_VERSION undefined)
endif
+CFLAGS += -DNVIDIA_VERSION=\"$(NVIDIA_VERSION)\"
+
##############################################################################
# Several of the functions below take an argument that indicates if
@@ -425,37 +425,6 @@ define DEBUG_INFO_RULES
endef
##############################################################################
-# STAMP_C - this is a source file that is generated during the build
-# to capture information about the build environment for the utility.
-#
-# The DEFINE_STAMP_C_RULE function is used to define the rule for
-# generating STAMP_C. First argument is a list of dependencies for
-# STAMP_C (g_stamp.o is filtered out of the list); second argument is
-# the name of the program being built.
-#
-# The includer of utils.mk should add $(STAMP_C) to its list of source
-# files
-##############################################################################
-
-STAMP_C = $(OUTPUTDIR)/g_stamp.c
-
-define DEFINE_STAMP_C_RULE
-
- $$(STAMP_C): $$(filter-out \
- $$(call BUILD_OBJECT_LIST,$$(STAMP_C)),$(1)) \
- $$(VERSION_MK)
- @ $$(RM) $$@
- @ $$(PRINTF) "%s" "const char NV_ID[] = \"nvidia id: " >> $$@
- @ $$(PRINTF) "%s" "$(2): " >> $$@
- @ $$(PRINTF) "%s" "version $$(NVIDIA_VERSION) " >> $$@
- @ $$(PRINTF) "%s" "($$(shell $$(WHOAMI))" >> $$@
- @ $$(PRINTF) "%s" "@$$(shell $$(HOSTNAME_CMD))) " >> $$@
- @ $$(PRINTF) "%s\n" "$$(shell $(DATE))\";" >> $$@
- @ $$(PRINTF) "%s\n" "const char *pNV_ID = NV_ID + 11;" >> $$@
-
-endef
-
-##############################################################################
# Define rules that can be used for embedding a file into an ELF object that
# contains the raw contents of that file and symbols pointing to the embedded
# data.
--
2.11.0
From 9fe17e24fd93676edbc61f059b533d26eac97907 Mon Sep 17 00:00:00 2001
From: Aaron Plattner <aplattner@nvidia.com>
Date: Fri, 23 Mar 2018 17:16:10 -0700
Subject: [PATCH 2/2] nvidia-settings: Remove __DATE__ from the man page
The man page is supposed to have a date in it that describes when it was
updated. It's hard to remember to change it so we have the makefile insert the
build date instead. However, doing that makes it difficult for distributions to
achieve reproducible builds since it changes the resulting package when builds
happen on different days.
The date in this file doesn't really matter, so just hard-code today's date and
remove the code to generate it.
Closes https://github.com/NVIDIA/nvidia-settings/pull/12
---
doc/Makefile | 1 -
doc/nvidia-settings.1.m4 | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/doc/Makefile b/doc/Makefile
index a511322..618f6b8 100644
--- a/doc/Makefile
+++ b/doc/Makefile
@@ -109,7 +109,6 @@ $(MANPAGE_not_gzipped): nvidia-settings.1.m4 $(OPTIONS_1_INC) $(VERSION_MK)
-D__HEADER__=$(AUTO_TEXT) \
-D__BUILD_OS__=$(TARGET_OS) \
-D__VERSION__=$(NVIDIA_VERSION) \
- -D__DATE__="`$(DATE) +%F`" \
-I $(OUTPUTDIR) \
$< > $@
diff --git a/doc/nvidia-settings.1.m4 b/doc/nvidia-settings.1.m4
index 917a48b..b8c35c9 100644
--- a/doc/nvidia-settings.1.m4
+++ b/doc/nvidia-settings.1.m4
@@ -10,7 +10,7 @@ __HEADER__
\\$2 \(la \\$1 \(ra\\$3
..
.if \n[.g] .mso www.tmac
-.TH nvidia\-settings 1 "__DATE__" "nvidia\-settings __VERSION__"
+.TH nvidia\-settings 1 "2018-03-20" "nvidia\-settings __VERSION__"
.SH NAME
nvidia\-settings \- configure the NVIDIA graphics driver
.SH SYNOPSIS
--
2.11.0
0001-nvidia-settings-Remove-STAMP_C.patch
0002-nvidia-settings-Remove-__DATE__-from-the-man-page.patch
link-order.diff
04_link_as-needed.diff
10_libxnvctrl_so_0.diff
......
Markdown is supported
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