[pkg-nvidia-devel] r552 - in /packages/nvidia-graphics-drivers-legacy-173xx/trunk: Makefile debian.binary/changelog debian.binary/rules debian/rules
rdonald at users.alioth.debian.org
rdonald at users.alioth.debian.org
Tue Apr 21 04:13:38 UTC 2009
Author: rdonald
Date: Tue Apr 21 04:13:29 2009
New Revision: 552
URL: http://svn.debian.org/wsvn/pkg-nvidia/?sc=1&rev=552
Log:
patch for debian 2.6.29
Modified:
packages/nvidia-graphics-drivers-legacy-173xx/trunk/Makefile
packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/changelog
packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/rules
packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian/rules
Modified: packages/nvidia-graphics-drivers-legacy-173xx/trunk/Makefile
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers-legacy-173xx/trunk/Makefile?rev=552&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers-legacy-173xx/trunk/Makefile (original)
+++ packages/nvidia-graphics-drivers-legacy-173xx/trunk/Makefile Tue Apr 21 04:13:29 2009
@@ -1,33 +1,179 @@
-#!/usr/bin/make -f
-# Makefile for building prebuilt nvidia kernel modules
+# Makefile -- For the nvidia module
+#
+# By default, the build is done against the running linux kernel source.
+# To build against a different kernel source tree, set LINUXDIR:
+#
+# make LINUXDIR=/path/to/kernel/source
-KVERS = $(KERNELVERSION)
-KSRC = $(CURDIR)
-include $(M)/debian/conf.mk
+SHELL=/bin/sh
+.SUFFIXES:
+ifndef LINUXDIR
+RUNNING_REL := $(shell uname -r)
-all:
+LINUXDIR := $(shell if [ -e /lib/modules/$(RUNNING_REL)/source ]; then \
+ echo /lib/modules/$(RUNNING_REL)/source; \
+ else echo /lib/modules/$(RUNNING_REL)/build; fi)
+endif
+ifndef O
+O := $(shell if [ -e /lib/modules/$(RUNNING_REL)/build ]; then \
+ echo /lib/modules/$(RUNNING_REL)/build; \
+ else echo ""; fi)
+#O := $(LINUXDIR)
+endif
- touch $(M)/$(dirname)/gcc-check
- touch $(M)/$(dirname)/cc-sanity-check
+ifdef ARCH
+MACHINE := $(ARCH)
+else
+MACHINE := $(shell uname -m)
+endif
- ## Main Make ##
- IGNORE_CC_MISMATCH=1 CC="$(CC)" $(MAKE) -C $(M)/$(dirname) -f Makefile SYSSRC=$(KSRC) $(KPKG_EXTRAV_ARG) KBUILD_PARAMS=$(KBUILD_PARAMS) module;
+# Modules for all architectures
+MODULE_LIST := nvidia.o
- touch build-stamp
+CLEANFILES = *.o *.ko .depend .*.flags .*.d .*.cmd *.mod.c .tmp_versions
-modules_install: $(M)/$(dirname)/nvidia.ko
-
+# VERSION is not defined from the initial invocation. It is defined when
+# this Makefile is invoked from the kernel's root Makefile.
+ifndef VERSION
+ifdef RUNNING_REL
-clean:
- $(MAKE) clean SYSSRC=$(KSRC) -C $(M)/$(dirname) -f Makefile $(KPKG_EXTRAV_ARG)
-
- rm -f $(M)/$(dirname)/Makefile || true;
- -rm $(M)/$(dirname)/gcc-check
- -rm $(M)/$(dirname)/cc-sanity-check
-
+# SuSE has the version.h and autoconf.h headers for the current kernel
+# in /boot as /boot/vmlinuz.version.h and /boot/vmlinuz.autoconf.h.
+# Check these first to see if they match the running kernel.
+
+BOOTVERSION_PREFIX = /boot/vmlinuz.
+
+V := $(shell if [ -f $(BOOTVERSION_PREFIX)version.h ]; then \
+ grep UTS_RELEASE $(BOOTVERSION_PREFIX)version.h | \
+ cut -d' ' -f3; fi)
+
+ifeq ($(V),"$(RUNNING_REL)")
+HEADERFROMBOOT := 1
+GETCONFIG := MAKEFILES=$(shell /bin/pwd)/.config
+HAVECONFIG := y
+endif
+
+# On Red Hat we need to check if there is a .config file in the kernel
+# source directory. If there isn't, we need to check if there's a
+# matching file in the configs subdirectory.
+
+ifneq ($(HAVECONFIG),y)
+HAVECONFIG := $(shell if [ -e $(LINUXDIR)/.config ]; then echo y; fi)
+endif
+
+ifneq ($(HAVECONFIG),y)
+REL_BASE := $(shell echo $(RUNNING_REL) | sed 's/-.*//')
+REL_TYPE := $(shell echo $(RUNNING_REL) | sed 's/[0-9.-]//g')
+ifeq ($(REL_TYPE),)
+RHCONFIG := configs/kernel-$(REL_BASE)-$(MACHINE).config
+else
+RHCONFIG := configs/kernel-$(REL_BASE)-$(MACHINE)-$(REL_TYPE).config
+endif
+HAVECONFIG := $(shell if [ -e $(LINUXDIR)/$(RHCONFIG) ]; then echo y; fi)
+ifneq ($(HAVECONFIG),y)
+RHCONFIG :=
+endif
+endif
+
+ifneq ($(HAVECONFIG),y)
+ifneq ($(0),$(LINUXDIR))
+GETCONFIG += O=$(O)
+endif
+HAVECONFIG := $(shell if [ -e $(O)/.config ]; then echo y; fi)
+endif
+
+ifneq ($(HAVECONFIG),y)
+$(error Cannot find a kernel config file)
+endif
+
+endif
+
+CLEANCONFIG := $(shell if cmp -s $(LINUXDIR)/.config .config; then echo y; fi)
+ifeq ($(CLEANCONFIG),y)
+CLEANFILES += $(LINUXDIR)/.config .config $(LINUXDIR)/tmp_include_depends
+endif
+
+all: modules
+
+modules: includes
+ +make -C $(LINUXDIR) $(GETCONFIG) M=`/bin/pwd` modules
+
+ifeq ($(HEADERFROMBOOT),1)
+
+BOOTHEADERS = version.h autoconf.h
+BOOTCONFIG = .config
+
+CLEANFILES += $(BOOTHEADERS) $(BOOTCONFIG)
+
+includes:: $(BOOTHEADERS) $(BOOTCONFIG)
+
+version.h: $(BOOTVERSION_PREFIX)version.h
+ rm -f $@
+ ln -s $< $@
+
+autoconf.h: $(BOOTVERSION_PREFIX)autoconf.h
+ rm -f $@
+ ln -s $< $@
+
+.config: $(BOOTVERSION_PREFIX)config
+ rm -f $@
+ ln -s $< $@
+endif
+
+# This prepares an unused Red Hat kernel tree for the build.
+ifneq ($(RHCONFIG),)
+includes:: $(LINUXDIR)/.config $(LINUXDIR)/tmp_include_depends .config
+
+$(LINUXDIR)/.config: $(LINUXDIR)/$(RHCONFIG)
+ rm -f $@
+ ln -s $< $@
+
+.config: $(LINUXDIR)/$(RHCONFIG)
+ rm -f $@
+ ln -s $< $@
+
+$(LINUXDIR)/tmp_include_depends:
+ echo all: > $@
+endif
+
+clean cleandir:
+ rm -rf $(CLEANFILES)
+
+$(MODULE_LIST)::
+ make modules
+
+install:
+ make -C $(LINUXDIR) $(GETCONFIG) M=`/bin/pwd` modules_install
+
+else
+
+# Check for kernel versions that we don't support.
+
+BELOW26 := $(shell if [ $(VERSION) -lt 2 -o $(PATCHLEVEL) -lt 6 ]; then \
+ echo y; fi)
+
+ifeq ($(BELOW26),y)
+$(error Only 2.6.x and later kernels are supported \
+ ($(VERSION).$(PATCHLEVEL).$(SUBLEVEL)))
+endif
+
+# This needs to go before all other include paths.
+CC += -I$(M)
+
+ifeq ($(CONFIG_X86_64),y)
+NVARCH = .x86_64
+else
+NVARCH = .i386
+endif
+
+include $(M)/Makefile.kbuild
+
+endif
+
+.PHONY: includes
Modified: packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/changelog
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/changelog?rev=552&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/changelog (original)
+++ packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/changelog Tue Apr 21 04:13:29 2009
@@ -1,3 +1,9 @@
+nvidia-kernel-legacy-173xx (173.14.15-2) unstable; urgency=low
+
+ * Remove kernel lintian overrides.
+
+ -- Randall Donald <rdonald at debian.org> Tue, 03 Mar 2009 22:24:14 -0800
+
nvidia-kernel-legacy-173xx (173.14.15-1) unstable; urgency=low
* New upstream.
Modified: packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/rules
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/rules?rev=552&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/rules (original)
+++ packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian.binary/rules Tue Apr 21 04:13:29 2009
@@ -1,116 +1,60 @@
#!/usr/bin/make -f
-# Sample debian/rules that uses debhelper.
-# GNU copyright 1997 to 1999 by Joey Hess.
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
+LEGACY=-legacy-173xx
-# This is the debhelper compatability version to use.
-export DH_COMPAT=4
+CFLAGS = -Wall -g
+ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
+ CFLAGS += -O0
+else
+ CFLAGS += -O2
+endif
+ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+ NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+ MAKEFLAGS += -j$(NUMJOBS)
+endif
-ifeq ($(shell id -u),0)
- ROOT_CMD=
-endif
-
-include $(CURDIR)/debian/conf.mk
+DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+# Prefix of the target package name
+PACKAGE = nvidia-kernel$(LEGACY)
-.PHONY: build build-stamp
-build: configure-stamp build-stamp
-build-stamp:
+-include /usr/share/modass/include/generic.make
+-include /usr/share/modass/include/common-rules.make
- dh_testdir
- dh_testroot
-
-
- @echo "PATCHLEVEL = $(PATCHLEVEL) " ;
- @echo "Kernel compiler version : $(kernel_cc)" ;
- @echo "Detected compiler version : $(module_cc)" ;
-
-
- @if [ "$(kernel_cc)" != "$(module_cc)" ]; then \
- echo " "; \
- echo "You appear to be compiling the NVIDIA kernel module with "; \
- echo "a compiler different from the one that was used to compile "; \
- echo "the running kernel. This may be perfectly alright and you "; \
- echo "may be building this module for another kernel in which case"; \
- echo "you may ignore this message."; \
- echo " " ; \
- echo "The compiler that will be used to compile this module has been"; \
- echo "determined from:" ; \
- echo " 1) the CC environment variable " ; \
- echo " 2) that specified in "; \
- echo " $(KSRC)/include/linux/compile.h" ; \
- echo " 3) gcc " ; \
- fi
- @echo "Using compiler $(CC) version $(module_cc)";
-
-
-
- touch $(CURDIR)/$(dirname)/gcc-check
- touch $(CURDIR)/$(dirname)/cc-sanity-check
-
- ## Main Make ##
- IGNORE_CC_MISMATCH=1 CC="$(CC)" $(MAKE) -C $(CURDIR)/$(dirname) -f Makefile SYSSRC=$(KSRC) $(KPKG_EXTRAV_ARG) KBUILD_PARAMS=$(KBUILD_PARAMS) module;
-
- touch build-stamp
-
-
-.PHONY: install
-install: build
- dh_testdir
- dh_testroot
- dh_clean -k
-
+configure:
sed 's/#KVERS#/$(KVERS)/g' debian/control.template > $(CURDIR)/debian/control
sed 's/#KVERS#/$(KVERS)/g' debian/dirs.template > $(CURDIR)/debian/dirs
sed 's/#KVERS#/$(KVERS)/g' debian/override.template > $(CURDIR)/debian/override
+binary-modules: configure
+ dh_testroot
+
+ dh_prep
+
+ # Build the modules
+ $(MAKE) -C . LINUXDIR=$(KSRC) KVERREL=$(KVERS)
+
+ # Install the modules
dh_installdirs
+ install -m 0644 $(CURDIR)/debian/override $(CURDIR)/debian/nvidia-kernel$(LEGACY)-$(KVERS)/usr/share/lintian/overrides/nvidia-kernel$(LEGACY)-$(KVERS)
+ install -m 0644 $(CURDIR)/nvidia.ko $(CURDIR)/debian/nvidia-kernel$(LEGACY)-$(KVERS)/lib/modules/$(KVERS)/nvidia/nvidia.ko ; \
-
-# install -m 0644 $(CURDIR)/debian/override $(CURDIR)/debian/nvidia-kernel-$(KVERS)/usr/share/lintian/overrides/nvidia-kernel-legacy-173xx-$(KVERS)
- if [ "$(PATCHLEVEL)" = "6" ] ; then \
- install -m 0644 $(CURDIR)/$(dirname)/nvidia.ko $(CURDIR)/debian/nvidia-kernel-legacy-173xx-$(KVERS)/lib/modules/$(KVERS)/nvidia/nvidia.ko ; \
- else \
- install -m 0644 $(CURDIR)/$(dirname)/nvidia.o $(CURDIR)/debian/nvidia-kernel-legacy-173xx-$(KVERS)/lib/modules/$(KVERS)/nvidia/nvidia.o ;\
- fi
-
-
-
-
-
-.PHONY: binary_modules
-binary_modules: build install
- dh_testdir
- dh_testroot
-# dh_installdebconf
dh_installdocs
-# dh_installexamples
-# dh_installmanpages
-# dh_undocumented
dh_installmodules
-
- dh_installinit
-
- dh_installchangelogs
- dh_link
+ dh_installchangelogs
+ dh_installmodules
dh_strip
dh_compress
dh_fixperms
-# You may want to make some executables suid here.
-# dh_suidregister
-# dh_makeshlibs
dh_installdeb
-# dh_shlibdeps
- dh_gencontrol -- -v$(PKG_VERSION)
+ dh_gencontrol -- -v$(VERSION)
dh_md5sums
dh_builddeb --destdir=$(KPKG_DEST_DIR)
+ dh_prep
-
-.PHONY: clean
-clean: clean.Makefile unpatch
+clean: unpatch
if [ -f $(CURDIR)/debian/control.template ]; then \
cp $(CURDIR)/debian/control.template $(CURDIR)/debian/control; \
fi
@@ -121,7 +65,6 @@
$(MAKE) clean SYSSRC=$(KSRC) -C $(CURDIR)/$(dirname) -f Makefile $(KPKG_EXTRAV_ARG)
- rm -f $(CURDIR)/$(dirname)/Makefile || true;
-rm $(CURDIR)/$(dirname)/gcc-check
-rm $(CURDIR)/$(dirname)/cc-sanity-check
@@ -144,38 +87,14 @@
# The kdist_configure target is called by make-kpkg modules_config. It
# should configure the module so it is ready for compilation (mostly
# useful for calling configure)
-.PHONY: kdist_config
-kdist_config:
- $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules configure
-
-.PHONY: kdist_configure
-kdist_configure:
- $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules configure
-
-# the kdist_image target is called by make-kpkg modules_image. It is
-# responsible for compiling the module and creating the package. It
-# should also clean up after making the module. Please note we use a
-# seperate binary-modules target to make testing the package building
-# easier
-.PHONY: kdist_image
-kdist_image:
- echo "ROOT_CMD = $(ROOT_CMD)"
- $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules binary_modules
- $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules clean
-
-
+kdist_config kdist_configure:
+ $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules configure
# the kdist_clean target is called by make-kpkg modules_clean. It is
# responsible for cleaning up any changes that have been made by the
# other kdist_commands (except for the .deb files created).
-.PHONY: kdist_clean
kdist_clean:
- $(MAKE) $(MFLAGS) -f debian/rules clean
+ $(MAKE) -C . LINUXDIR=$(KSRC) KVERREL=$(KVERS) clean
+ dh_clean
-kdist:
- $(ROOT_CMD) $(MAKE) $(MFLAGS) -f debian/rules binary_modules
- # Build a .changes file.
- dpkg-genchanges -b -e"$(KMAINT) <$(KEMAIL)>" -u"$(KPKG_DEST_DIR)" > $(CHFILE)
- debsign -e"$(KMAINT) <$(KEMAIL)>" $(CHFILE)
- $(MAKE) $(MFLAGS) -f debian/rules clean
-
+.PHONY: clean binary-modules
Modified: packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian/rules
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian/rules?rev=552&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian/rules (original)
+++ packages/nvidia-graphics-drivers-legacy-173xx/trunk/debian/rules Tue Apr 21 04:13:29 2009
@@ -27,12 +27,13 @@
dirname_x86:=$(shell sh debian/upstream_info DIRNAME_X86)
dirname_x86_64:=$(shell sh debian/upstream_info DIRNAME_X86_64)
-AUTOGEN=debian/nvidia-kernel-legacy-173xx-source.README.Debian debian/control \
-debian/copyright debian/nvidia-glx-legacy-173xx.links debian/nvidia-glx-legacy-173xx-dev.links \
-debian/nvidia-glx-legacy-173xx.override debian/nvidia-glx-legacy-173xx.docs debian/nvidia-glx-legacy-173xx.examples \
-debian/nvidia-glx-legacy-173xx.postrm debian/nvidia-glx-legacy-173xx.init \
-debian/nvidia-glx-legacy-173xx-ia32.override debian/nvidia-glx-legacy-173xx-ia32.links \
-debian/nvidia-kernel-legacy-173xx-source.docs debian/nvidia-glx-legacy-173xx-dev.preinst
+LEGACY=-legacy-173xx
+AUTOGEN=debian/nvidia-kernel$(LEGACY)-source.README.Debian debian/control \
+debian/copyright debian/nvidia-glx$(LEGACY).links debian/nvidia-glx$(LEGACY)-dev.links \
+debian/nvidia-glx$(LEGACY).override debian/nvidia-glx$(LEGACY).docs debian/nvidia-glx$(LEGACY).examples \
+debian/nvidia-glx$(LEGACY).postrm debian/nvidia-glx$(LEGACY).init \
+debian/nvidia-glx$(LEGACY)-ia32.override debian/nvidia-glx$(LEGACY)-ia32.links \
+debian/nvidia-kernel$(LEGACY)-source.docs debian/nvidia-glx$(LEGACY)-dev.preinst
@@ -59,17 +60,17 @@
# extract both so we can fetch the kernel object code for both arches
./${filename_x86} --extract-only
./${filename_x86_64} --extract-only
- if test -d $(CURDIR)/patchesREMOVEIFNEEDED; \
+ if test -d $(CURDIR)/patches; \
then \
pwd; \
ls -al; \
cd $(dirname)/usr/src/nv; \
- for i in $(CURDIR)/patches/*; \
- do patch -p3 <$$i ; \
- done; \
+# for i in $(CURDIR)/patches/*; \
+# do patch -p3 <$$i; \
+# done; \
fi
- sed 's/^nvidia-graphics-drivers-legacy-173xx/nvidia-kernel-legacy-173xx/g' debian/changelog > debian.binary/changelog
+ sed 's/^nvidia-graphics-drivers$(LEGACY)/nvidia-kernel$(LEGACY)/g' debian/changelog > debian.binary/changelog
touch configure-stamp
@@ -90,10 +91,11 @@
dh_testdir
# build kernel module source tarball
- mkdir -p $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian
+ mkdir -p $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian
- cp -a $(CURDIR)/debian.binary/* $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian
-
+ # Prepare debian files for module package
+ cp -a $(CURDIR)/debian.binary/* $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian
+ cp -a $(CURDIR)/debian.binary/control.template $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian/control
for f in `ls $(CURDIR)/debian.binary` ; do \
perl -p \
-e 's{#BASE_VERSION#}{$(base_version)}g;' \
@@ -101,18 +103,31 @@
-e 's{#VERSION#}{$(version)}g;' \
-e 's{#UPSTREAMVERSION#}{$(upstreamversion)}g;' \
-e 's{#URL#}{$(url)}g' \
- < $(CURDIR)/debian.binary/$$f > $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian/$$f ; \
- chmod 0644 $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian/$$f ; \
+ < $(CURDIR)/debian.binary/$$f > $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian/$$f ; \
+ chmod 0644 $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian/$$f ; \
done
-# chmod 775 $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian/patches
- cp $(CURDIR)/$(dirname)/usr/src/nv/* $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/ || true
-#not yet cp $(CURDIR)/Makefile $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/ || true
- cp $(CURDIR)/$(dirname_x86_64)/usr/src/nv/nv-kernel.o $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/nv-kernel.o.x86_64 || true
- cp $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/Makefile.kbuild $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/Makefile
- chmod 755 $(CURDIR)/debian/temp/modules/nvidia-kernel-legacy-173xx/debian/rules
+
+# chmod 775 $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian/patches
+ cp $(CURDIR)/$(dirname)/usr/src/nv/* $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/
+
+ # We don't want these makefiles that don't work with kbuild
+ rm $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/makefile
+
+ # We want both 32 and 64 bit versions of nv-kernel.o
+ cp $(CURDIR)/$(dirname_x86_64)/usr/src/nv/nv-kernel.o $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/nv-kernel.o.x86_64
+ mv $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/nv-kernel.o $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/nv-kernel.o.i386
+
+ # and then make Makefile.kbuild actually use our names
+ sed -i -e 's/nv-kernel.o$$/nv-kernel.o$$(NVARCH)/' $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/Makefile.kbuild
+
+ # We have new conftest files that work purely with kbuild and doesn't require root
+ cp $(CURDIR)/Makefile $(CURDIR)/conftest.* $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/
+
+ # Fix permissions
+ chmod 755 $(CURDIR)/debian/temp/modules/nvidia-kernel$(LEGACY)/debian/rules
chown -R root:src $(CURDIR)/debian/temp/modules
- tar -jcvf $(CURDIR)/nvidia-kernel-legacy-173xx.tar.bz2 -C $(CURDIR)/debian/temp modules
+ tar -jcvf $(CURDIR)/nvidia-kernel$(LEGACY).tar.bz2 -C $(CURDIR)/debian/temp modules
rm -rf debian/temp
touch build-kernel-stamp
@@ -123,8 +138,7 @@
rm -f build-stamp build-kernel-stamp configure-stamp
dh_clean
- rm -fr $(dirname_x86) $(dirname_x86_64) nvidia-kernel-legacy-173xx.tar.bz2
-
+ rm -fr $(dirname_x86) $(dirname_x86_64) nvidia-kernel$(LEGACY).tar.bz2
.PHONY: install
@@ -134,82 +148,94 @@
dh_clean -k
dh_installdirs
- install -m 644 $(CURDIR)/nvidia-kernel-legacy-173xx.tar.bz2 $(CURDIR)/debian/nvidia-kernel-legacy-173xx-source/usr/src
-
+ install -m 644 $(CURDIR)/nvidia-kernel$(LEGACY).tar.bz2 $(CURDIR)/debian/nvidia-kernel$(LEGACY)-source/usr/src
install -m 0644 $(dirname)/usr/X11R6/lib/modules/drivers/nvidia_drv.so \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/xorg/modules/drivers
-
-
-
- install $(dirname)/usr/X11R6/lib/libXvMCNVIDIA.a $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/lib/libXvMCNVIDIA.a;
- install $(dirname)/usr/X11R6/lib/libXvMCNVIDIA.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/libXvMCNVIDIA.so.${version};
-
-
-
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/xorg/modules/drivers
+
+ install $(dirname)/usr/X11R6/lib/libXvMCNVIDIA.a $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/lib/libXvMCNVIDIA.a;
+ install $(dirname)/usr/X11R6/lib/libXvMCNVIDIA.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/libXvMCNVIDIA.so.${version};
install -m 0644 $(dirname)/usr/include/GL/gl.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/GL
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/GL
install -m 0644 $(dirname)/usr/include/GL/glext.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/GL
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/GL
install -m 0644 $(dirname)/usr/include/cuda/cuda.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/cuda
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/cuda
install -m 0644 $(dirname)/usr/include/cuda/cudaGL.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/cuda
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/cuda
+
+ -install -m 0644 $(dirname)/usr/include/vdpau/vdpau.h \
+ $(CURDIR)/debian/nvidia-glx-dev/usr/include/vdpau
+ -install -m 0644 $(dirname)/usr/include/vdpau/vdpau_x11.h \
+ $(CURDIR)/debian/nvidia-glx-dev/usr/include/vdpau
install -m 0644 $(dirname)/usr/include/GL/glx.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/GL
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/GL
install -m 0644 $(dirname)/usr/include/GL/glxext.h \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/include/GL
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/include/GL
install -m 0644 $(dirname)/usr/lib/libGL.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
install -m 0644 $(dirname)/usr/lib/libGLcore.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
install -m 0644 $(dirname)/usr/lib/libcuda.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib
- sed "s/__GENERATED_BY__/Debian nvidia-graphics-drivers-legacy-173xx/" $(dirname)/usr/lib/libGL.la | sed "s/__LIBGL_PATH__/\/usr\/lib/" > $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/lib/libGL.la
- # install -m 0644 $(dirname)/usr/lib/libGL.la $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/libGL.la
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
+ -install -m 0644 $(dirname)/usr/lib/libvdpau_nvidia.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
+ -install -m 0644 $(dirname)/usr/lib/libvdpau.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
+ -install -m 0644 $(dirname)/usr/lib/libvdpau_trace.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
+
+ sed "s/__GENERATED_BY__/Debian nvidia-graphics-drivers$(LEGACY)/" $(dirname)/usr/lib/libGL.la | sed "s/__LIBGL_PATH__/\/usr\/lib/" > $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/lib/libGL.la
+ # install -m 0644 $(dirname)/usr/lib/libGL.la $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/libGL.la
# TLS (nvidia-tls new for 6106)
- #install $(dirname)/usr/lib/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/
- install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/
-
- #install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/nvidia
- install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/tls/
+ #install $(dirname)/usr/lib/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/
+ install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/
+
+ #install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/nvidia
+ install $(dirname)/usr/lib/tls/libnvidia-tls.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/tls/
- #sed "s/__GENERATED_BY__/Debian nvidia-graphics-drivers-legacy-173xx/" $(dirname)/usr/lib/tls/libGL.la | sed "s/__LIBGL_PATH__/\/usr\/lib\/tls/" > $(CURDIR)/debian/nvidia-glx-legacy-173xx-dev/usr/lib/nvidia/libGL.la
- # install -m 0644 $(dirname)/usr/lib/tls/libGL.la $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/nvidia/libGL.la
+ #sed "s/__GENERATED_BY__/Debian nvidia-graphics-drivers$(LEGACY)/" $(dirname)/usr/lib/tls/libGL.la | sed "s/__LIBGL_PATH__/\/usr\/lib\/tls/" > $(CURDIR)/debian/nvidia-glx$(LEGACY)-dev/usr/lib/nvidia/libGL.la
+ # install -m 0644 $(dirname)/usr/lib/tls/libGL.la $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/nvidia/libGL.la
- install -m 0644 $(dirname)/usr/lib/libnvidia-cfg.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/nvidia/
-
-
- install $(dirname)/usr/X11R6/lib/modules/extensions/libglx.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/xorg/modules/extensions/
-# install $(dirname)/usr/X11R6/lib/modules/libnvidia-wfb.so.${version} $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/xorg/modules/
-
- install $(dirname)/usr/bin/tls_test $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/nvidia
- install $(dirname)/usr/bin/tls_test_dso.so $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib/nvidia
-
- install -d $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/share/lintian/overrides
- install -m 0644 debian/nvidia-glx-legacy-173xx.override \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/share/lintian/overrides/nvidia-glx-legacy-173xx
+ install -m 0644 $(dirname)/usr/lib/libnvidia-cfg.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/nvidia/
+
+
+ install $(dirname)/usr/X11R6/lib/modules/extensions/libglx.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/xorg/modules/extensions/
+# install $(dirname)/usr/X11R6/lib/modules/libnvidia-wfb.so.${version} $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/xorg/modules/
+
+ install $(dirname)/usr/bin/tls_test $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/nvidia
+ install $(dirname)/usr/bin/tls_test_dso.so $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib/nvidia
+
+ install -d $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/share/lintian/overrides
+ install -m 0644 debian/nvidia-glx$(LEGACY).override \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/share/lintian/overrides/nvidia-glx$(LEGACY)
if [ "$(DEB_BUILD_ARCH)" = "amd64" ] ; then \
install $(dirname)/usr/lib32/libGLcore.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-ia32/emul/ia32-linux/usr/lib ; \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
install $(dirname)/usr/lib32/libGL.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-ia32/emul/ia32-linux/usr/lib ; \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
install $(dirname)/usr/lib32/libcuda.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-ia32/emul/ia32-linux/usr/lib ; \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
+ -install $(dirname)/usr/lib32/libvdpau.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
+ -install $(dirname)/usr/lib32/libvdpau_nvidia.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
+ -install $(dirname)/usr/lib32/libvdpau_trace.so.${version} \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
install $(dirname)/usr/lib32/libnvidia-tls.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-ia32/emul/ia32-linux/usr/lib ; \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib ; \
install $(dirname)/usr/lib32/tls/libnvidia-tls.so.${version} \
- $(CURDIR)/debian/nvidia-glx-legacy-173xx-ia32/emul/ia32-linux/usr/lib/tls ; \
+ $(CURDIR)/debian/nvidia-glx$(LEGACY)-ia32/emul/ia32-linux/usr/lib/tls ; \
fi
- install -m 755 $(dirname)/usr/bin/nvidia-bug-report.sh $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/bin/
+ install -m 755 $(dirname)/usr/bin/nvidia-bug-report.sh $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/bin/
# use separate package
#install -m 755 $(dirname)/usr/bin/nvidia-xconfig $(CURDIR)/debian/nvidia-glx/usr/bin/
@@ -218,7 +244,7 @@
#install -m 644 $(dirname)/usr/share/doc/nvidia-settings-user-guide.txt $(CURDIR)/debian/nvidia-settings/usr/share/doc/nvidia-settings
- install $(CURDIR)/script $(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/share/bug/nvidia-glx-legacy-173xx
+ install $(CURDIR)/script $(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/share/bug/nvidia-glx$(LEGACY)
dh_install
@@ -251,9 +277,9 @@
# dh_python
dh_makeshlibs
dh_installdeb
- dh_shlibdeps -Xia32 -Xtls -l$(CURDIR)/debian/nvidia-glx-legacy-173xx/usr/lib
+ dh_shlibdeps -Xia32 -Xtls -l$(CURDIR)/debian/nvidia-glx$(LEGACY)/usr/lib
# quickhack! remove me :-/
- perl -pi.bak -e 's/,\s+nvidia-glx-legacy-173xx-ia32//;' $(CURDIR)/debian/nvidia-glx-legacy-173xx.substvars
+ perl -pi.bak -e 's/,\s+nvidia-glx$(LEGACY)-ia32//;' $(CURDIR)/debian/nvidia-glx$(LEGACY).substvars
dh_gencontrol -s
dh_md5sums
dh_builddeb -s
More information about the Pkg-nvidia-devel
mailing list