summaryrefslogtreecommitdiff
path: root/v4l_experimental/pvrusb2/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'v4l_experimental/pvrusb2/Makefile')
-rw-r--r--v4l_experimental/pvrusb2/Makefile40
1 files changed, 22 insertions, 18 deletions
diff --git a/v4l_experimental/pvrusb2/Makefile b/v4l_experimental/pvrusb2/Makefile
index b86f841a5..88eb298b6 100644
--- a/v4l_experimental/pvrusb2/Makefile
+++ b/v4l_experimental/pvrusb2/Makefile
@@ -1,13 +1,13 @@
# Mike Isely <isely@pobox.com>
-# This is the module build file for pvrusb2. It requires the kbuild
-# system from any 2.6.x kernel. It requires the kbuild system from
-# any 2.6.x kernel (but it's only been tried against kernels 2.6.10
-# and later). This WILL NOT BUILD for 2.4.x kernels. Don't even
-# bother trying. Even if you were to fix this build for 2.4.x, you
-# would still have to port the driver as well. Everything here
-# assumes 2.6.x.
+# This is the module build file for pvrusb2 (ONLY when built as part
+# of v4l in the experimental area). It requires the kbuild system
+# from any 2.6.x kernel. It requires the kbuild system from any 2.6.x
+# kernel (but it's only been tried against kernels 2.6.10 and later).
+# This WILL NOT BUILD for 2.4.x kernels. Don't even bother trying.
+# Even if you were to fix this build for 2.4.x, you would still have
+# to port the driver as well. Everything here assumes 2.6.x.
# To build, you can just run this Makefile. There are several
# variables you may want to override however:
@@ -27,6 +27,10 @@
# Sensible build targets include 'modules' (same as no target),
# 'install', and 'clean'
+# For building within the v4l experimental area, we have to adjust our
+# include paths and also ensure that the environment as been set up
+# (which is presumably what the "links" callout is for).
+
ifeq ($(KERNELRELEASE),)
# Override any of these if you'd like
@@ -42,8 +46,17 @@ ifeq ($(KERNELRELEASE),)
default: all
all: modules
- M=$(shell pwd)
- MYFLAGS := "CPPFLAGS= -D __KERNEL__ -I$(M)/../../linux/include -I$(M)/../../v4l $(CPPFLAGS) -I$(KDIR)/include"
+ M:=$(shell pwd)
+
+ CPPFLAGS:= -D__KERNEL__ -I$(M)/../../linux/include -I$(M)/../../v4l $(CPPFLAGS) -I$(KDIR)/include
+
+ modules modules_install clean:
+ $(MAKE) -C $(M)/../.. links
+ $(MAKE) INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) "CPPFLAGS=$(CPPFLAGS)" -C $(KDIR) M=$(M) CONFIG_VIDEO_PVRUSB2=m $@
+
+ install:
+ $(MAKE) -C $(M)/../.. links
+ $(MAKE) INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) "CPPFLAGS=$(CPPFLAGS)" -C $(KDIR) M=$(M) CONFIG_VIDEO_PVRUSB2=m modules_install
else
@@ -52,12 +65,3 @@ else
endif
- modules modules_install clean:
- $(MAKE) -C $(shell pwd)/../.. links
- @echo cppflags=$(MYFLAGS)
- $(MAKE) V=1 $(MYFLAGS) INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) -C $(KDIR) M=$(shell pwd) CONFIG_VIDEO_PVRUSB2=m $@
-
- install:
- $(MAKE) INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) -C $(KDIR) M=$(shell pwd) CONFIG_VIDEO_PVRUSB2=m modules_install
-
-