summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--v4l/Makefile11
1 files changed, 9 insertions, 2 deletions
diff --git a/v4l/Makefile b/v4l/Makefile
index c8f42006d..7674abd98 100644
--- a/v4l/Makefile
+++ b/v4l/Makefile
@@ -301,8 +301,13 @@ CONF := $(KDIR)/scripts/kconfig/conf
# lxdialog can be in either scripts/lxdialog or scripts/kconfig/lxdialog
LXDIALOG_DIR := $(shell if [ -d $(KDIR)/scripts/kconfig/lxdialog ]; then echo kconfig/ ; fi)
-LXDIALOG_LNK := $(if $(LXDIALOG_DIR),scripts/kconfig,scripts/lxdialog)
-LXDIALOG := $(KDIR)/scripts/$(LXDIALOG_DIR)lxdialog/lxdialog
+# lxdialog might not be a separate program that needs to be built, check
+# for lxdialog/Makefile to find out.
+ifneq ($(wildcard $(KDIR)/scripts/$(LXDIALOG_DIR)lxdialog/Makefile),)
+ # lxdialog must be built
+ LXDIALOG_LNK := $(if $(LXDIALOG_DIR),scripts/kconfig,scripts/lxdialog)
+ LXDIALOG := $(KDIR)/scripts/$(LXDIALOG_DIR)lxdialog/lxdialog
+endif
# Ideally, some kind of oldconfig process would be used to update .config
# without destroying the user's configuration. Lacking that, we will
@@ -345,11 +350,13 @@ $(QCONF) $(GCONF) $(MCONF) $(CONF):
.PHONY: lxdialog
lxdialog: $(LXDIALOG) $(LXDIALOG_LNK)
+ifdef LXDIALOG
$(LXDIALOG_LNK):
ln -snf $(KDIR)/$(LXDIALOG_LNK) $(LXDIALOG_LNK)
$(LXDIALOG):
$(MAKE) -C $(KDIR) -f $(PWD)/Makefile.kernel $(KMAKEVARS) v4l-$(LXDIALOG)
+endif
#################################################
# IVTV link rules