diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/Makefile | 115 | ||||
-rw-r--r-- | doc/nvidia-settings.png | bin | 3485 -> 17255 bytes | |||
-rw-r--r-- | doc/src.mk | 2 | ||||
-rw-r--r-- | doc/version.mk | 1 |
4 files changed, 118 insertions, 0 deletions
diff --git a/doc/Makefile b/doc/Makefile new file mode 100644 index 0000000..40f1472 --- /dev/null +++ b/doc/Makefile @@ -0,0 +1,115 @@ +# +# nvidia-settings: A tool for configuring the NVIDIA X driver on Unix +# and Linux systems. +# +# Copyright (C) 2008-2012 NVIDIA Corporation. +# +# This program is free software; you can redistribute it and/or modify it +# under the terms and conditions of the GNU General Public License, +# version 2, as published by the Free Software Foundation. +# +# This program is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +# more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses>. +# + + +############################################################################## +# include common variables and functions +############################################################################## + +UTILS_MK_DIR ?= .. + +include $(UTILS_MK_DIR)/utils.mk + + +############################################################################## +# The common-utils directory may be in one of two places: either +# elsewhere in the driver source tree when building nvidia-settings as +# part of the NVIDIA driver build (in which case, COMMON_UTILS_DIR +# should be defined by the calling makefile), or directly in the +# source directory when building from the nvidia-settings source +# tarball (in which case, the below conditional assignments should be +# used) +############################################################################## + +COMMON_UTILS_DIR ?= ../src/common-utils + + +############################################################################## +# assign variables +############################################################################## + +MANPAGE_GZIP ?= 1 + +MANPAGE_gzipped = $(OUTPUTDIR)/nvidia-settings.1.gz +MANPAGE_not_gzipped = $(OUTPUTDIR)/nvidia-settings.1 +ifeq ($(MANPAGE_GZIP),1) + MANPAGE = $(MANPAGE_gzipped) +else + MANPAGE = $(MANPAGE_not_gzipped) +endif +GEN_MANPAGE_OPTS = $(OUTPUTDIR)/gen-manpage-opts +OPTIONS_1_INC = $(OUTPUTDIR)/options.1.inc + +CFLAGS += -I $(COMMON_UTILS_DIR) +CFLAGS += -I ../src/libXNVCtrlAttributes + + +############################################################################## +# build rules +############################################################################## + +.PNONY: all install MANPAGE_install clean clobber + +all: $(MANPAGE) + +install: MANPAGE_install + +MANPAGE_install: $(MANPAGE) + $(MKDIR) $(MANDIR) + $(INSTALL) $(INSTALL_BIN_ARGS) $< $(MANDIR)/$(notdir $<) + +clean clobber: + rm -rf $(MANPAGE) *~ $(OUTPUTDIR)/*.o $(OUTPUTDIR)/*.d \ + $(GEN_MANPAGE_OPTS) $(OPTIONS_1_INC) + + +############################################################################## +# Documentation +############################################################################## + +AUTO_TEXT = ".\\\" WARNING: THIS FILE IS AUTO-GENERATED! Edit $< instead." + +doc: $(MANPAGE) + +GEN_MANPAGE_OPTS_SRC = ../src/gen-manpage-opts.c +GEN_MANPAGE_OPTS_SRC += $(COMMON_UTILS_DIR)/gen-manpage-opts-helper.c + +GEN_MANPAGE_OPTS_OBJS = $(call BUILD_OBJECT_LIST,$(GEN_MANPAGE_OPTS_SRC)) + +$(foreach src, $(GEN_MANPAGE_OPTS_SRC), \ + $(eval $(call DEFINE_OBJECT_RULE,HOST_CC,$(src)))) + +$(GEN_MANPAGE_OPTS): $(GEN_MANPAGE_OPTS_OBJS) + $(call quiet_cmd,HOST_LINK) \ + $(HOST_CFLAGS) $(HOST_LDFLAGS) $(HOST_BIN_LDFLAGS) $^ -o $@ + +$(OPTIONS_1_INC): $(GEN_MANPAGE_OPTS) + @./$< > $@ + +$(MANPAGE_not_gzipped): nvidia-settings.1.m4 $(OPTIONS_1_INC) $(VERSION_MK) + $(call quiet_cmd,M4) \ + -D__HEADER__=$(AUTO_TEXT) \ + -D__BUILD_OS__=$(TARGET_OS) \ + -D__VERSION__=$(NVIDIA_VERSION) \ + -D__DATE__="`$(DATE) +%F`" \ + -I $(OUTPUTDIR) \ + $< > $@ + +$(MANPAGE_gzipped): $(MANPAGE_not_gzipped) + $(GZIP_CMD) -9f < $< > $@ diff --git a/doc/nvidia-settings.png b/doc/nvidia-settings.png Binary files differindex b506d99..82acce4 100644 --- a/doc/nvidia-settings.png +++ b/doc/nvidia-settings.png @@ -10,3 +10,5 @@ DOC_EXTRA_DIST += nvidia-settings.1.m4 DOC_EXTRA_DIST += nvidia-settings.desktop DOC_EXTRA_DIST += nvidia-settings.png DOC_EXTRA_DIST += src.mk + +DOC_DIST_FILES := $(DOC_SRC) $(DOC_EXTRA_DIST)
\ No newline at end of file diff --git a/doc/version.mk b/doc/version.mk new file mode 100644 index 0000000..c29a7ba --- /dev/null +++ b/doc/version.mk @@ -0,0 +1 @@ +NVIDIA_VERSION = 302.07 |