summaryrefslogtreecommitdiff
path: root/v4l
diff options
context:
space:
mode:
Diffstat (limited to 'v4l')
-rw-r--r--v4l/Makefile29
1 files changed, 20 insertions, 9 deletions
diff --git a/v4l/Makefile b/v4l/Makefile
index 3afe20e8b..bf4aa56f2 100644
--- a/v4l/Makefile
+++ b/v4l/Makefile
@@ -120,12 +120,21 @@ all:: allmodconfig default
Makefile.media::
scripts/make_makefile.pl
-.version:
+.version::
ifneq ($(KERNELRELEASE),)
- echo -e VERSION=$(VERSION)\\nPATCHLEVEL:=$(PATCHLEVEL)\\nSUBLEVEL:=$(SUBLEVEL)\\nKERNELRELEASE:=$(KERNELRELEASE) > $(obj)/.version
+ @echo -e VERSION=$(VERSION)\\nPATCHLEVEL:=$(PATCHLEVEL)\\nSUBLEVEL:=$(SUBLEVEL)\\nKERNELRELEASE:=$(KERNELRELEASE) > $(obj)/.version
else
- echo "No version yet."
- uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version
+ @echo "No version yet."
+ @uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version
+endif
+
+release::
+ifneq ($(VER),)
+ @echo "Forcing compiling to version $(VER)."
+ @echo $(VER)|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version
+else
+ @echo "No version specified. Using `uname -r`."
+ @uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version
endif
links::
@@ -139,7 +148,7 @@ kernel-links makelinks::
#################################################
# Cardlist updating rule
-card cardlist cardlists:
+card cardlist cardlists::
scripts/cardlist
#################################################
@@ -281,9 +290,6 @@ old-install:: rminstall
#################################################
# Tree management rules
-change changes changelog::
- make -C .. changelog
-
update::
make -C .. update
@@ -294,6 +300,11 @@ push::
make -C .. push
#################################################
+# Help
+help::
+ @cat ../INSTALL
+
+#################################################
# build tarballs rules
RPWD := $(shell cd .. && pwd)
@@ -305,7 +316,7 @@ tardest ?= .
snapdir := $(HOME)/snapshot
snap := $(name)
-snapshot snap tarball: update distclean
+snapshot snap tarball:: update distclean
echo $(thisdir)
echo $(name)
echo $(date) > .snapshot