summaryrefslogtreecommitdiff
path: root/v4l
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2006-04-26 10:13:07 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-04-26 10:13:07 -0300
commitecf096774ea92402d1ebea9d8fac8ac12316d766 (patch)
tree8c33d0943ff3bd27e700168bcd18fab0edaea2ba /v4l
parentcd0e65fa8883bb4f885c29ca3f0710cd31265cd3 (diff)
downloadmediapointer-dvb-s2-ecf096774ea92402d1ebea9d8fac8ac12316d766.tar.gz
mediapointer-dvb-s2-ecf096774ea92402d1ebea9d8fac8ac12316d766.tar.bz2
Added some tests at build system to avoid rebuilding kernel stuff
From: Mauro Carvalho Chehab <mchehab@infradead.org> Now, make will first check for the presense of *conf and lxconfig. if already found at kernel tree, it will use without recompiling. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'v4l')
-rw-r--r--v4l/Makefile27
1 files changed, 20 insertions, 7 deletions
diff --git a/v4l/Makefile b/v4l/Makefile
index dc7836557..3afe20e8b 100644
--- a/v4l/Makefile
+++ b/v4l/Makefile
@@ -76,6 +76,7 @@ KDIRUSB := /lib/modules/$(KERNELRELEASE)/kernel/drivers/usb/media
#################################################
# Compiler fixup rules
+HOSTCC:=$(CC)
CC += -I$(obj)
ifeq ($(VERSION).$(PATCHLEVEL),2.6)
@@ -180,22 +181,28 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
else if [ -x /bin/bash ]; then echo /bin/bash; \
else echo sh; fi ; fi)
-build := srctree=$(KDIR) HOSTCXX=$(CXX) HOSTCC=$(CC) CONFIG_SHELL=$(CONFIG_SHELL) -f $(KDIR)/scripts/Makefile.build obj
+build := srctree=$(KDIR) HOSTCXX="$(CXX)" HOSTCC="$(HOSTCC)" CONFIG_SHELL="$(CONFIG_SHELL)" -f $(KDIR)/scripts/Makefile.build obj
xconfig:: links .version
- $(MAKE) -C $(KDIR) $(build)=scripts/kconfig qconf-target=1 scripts/kconfig/qconf
+ -if [ ! -f $(KDIR)/scripts/kconfig/qconf ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/kconfig qconf-target=1 scripts/kconfig/qconf; \
+ fi
./scripts/make_kconfig.pl
$(KDIR)/scripts/kconfig/qconf Kconfig
./scripts/make_noconfig.pl
gconfig:: links .version
- $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/gconf
+ -if [ ! -f $(KDIR)/scripts/kconfig/gconf ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/gconf; \
+ fi
./scripts/make_kconfig.pl
$(KDIR)/scripts/kconfig/gconf Kconfig
./scripts/make_noconfig.pl
config:: links .version
- $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/conf
+ -if [ ! -f $(KDIR)/scripts/kconfig/conf ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/conf; \
+ fi
./scripts/make_kconfig.pl
$(KDIR)/scripts/kconfig/conf Kconfig
./scripts/make_noconfig.pl
@@ -204,15 +211,21 @@ menuconfig:: links .version
./scripts/make_kconfig.pl
-rm scripts/lxdialog scripts/kconfig
-if [ -d $(KDIR)/scripts/lxdialog ]; then \
- $(MAKE) -C $(KDIR) $(build)=scripts/lxdialog; \
+ if [ ! -f $(KDIR)/scripts/lxdialog/lxdialog ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/lxdialog; \
+ fi; \
ln -s $(KDIR)/scripts/lxdialog scripts/lxdialog; \
fi
-if [ -d $(KDIR)/scripts/kconfig ]; then \
if [ -d $(KDIR)/scripts/kconfig/lxdialog ]; then \
- $(MAKE) -C $(KDIR) $(build)=scripts/kconfig/lxdialog; \
+ if [ ! -f $(KDIR)/scripts/kconfig/lxdialog ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/kconfig/lxdialog; \
+ fi; \
else \
- $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/mconf; \
+ if [ ! -f $(KDIR)/scripts/kconfig/mconf ]; then \
+ $(MAKE) -C $(KDIR) $(build)=scripts/kconfig scripts/kconfig/mconf; \
+ fi; \
fi; \
ln -s $(KDIR)/scripts/kconfig scripts/kconfig; \
fi