All pastes #159677 Raw Edit

Anonymous

public text v1 · immutable
·published 2006-09-03 10:57 UTC
rendered paste body
diff -r 3a266801fc9d v4l/Makefile
--- a/v4l/Makefile      Sat Sep 02 13:29:14 2006 -0300
+++ b/v4l/Makefile      Sun Sep 03 03:52:51 2006 -0700
@@ -74,7 +74,7 @@ endif
 # make will try to automatically rebuild the Makefile and all includes,
 # and if any of them change, make will start over with the updated files
 
-.myconfig: .config Kconfig
+.myconfig: $(obj)/.config $(obj)/Kconfig
        ./scripts/make_myconfig.pl
 
 # If it doesn't exist, this rule will build Makefile.media.  If it does
@@ -308,12 +308,12 @@ LXDIALOG := $(KDIR)/scripts/$(LXDIALOG_D
 # without destroying the user's configuration.  Lacking that, we will
 # just touch .config if it already exists, and run make_kconfig if it
 # doesn't.
-.config: .version
+$(obj)/.config: $(obj)/.version
        @echo Updating/Creating .config
        @if [ -e .config ]; then touch .config ; else \
                ./scripts/make_kconfig.pl $(KDIR) ; fi
 
-Kconfig: .version
+$(obj)/Kconfig: $(obj)/.version
        ./scripts/make_kconfig.pl $(KDIR)
 
 # With make -j, it's possible that both the .config and Kconfig rules
diff -r 3a266801fc9d v4l/scripts/make_kconfig.pl
--- a/v4l/scripts/make_kconfig.pl       Sat Sep 02 13:29:14 2006 -0300
+++ b/v4l/scripts/make_kconfig.pl       Sun Sep 03 03:52:51 2006 -0700
@@ -316,6 +316,8 @@ sub open_kconfig($$) {
                } elsif (m|^\s*menu\s+"[^"]*"\s*$|) {
                        $key = 'menu';
                }
+               # Remaining Kconfig directives only makse sense inside Kconfig blocks
+               next unless(defined $key);
 
                # Don't process any directives in comment blocks (or menus)
                next if ($key eq 'comment' || $key eq 'menu');