summaryrefslogtreecommitdiff
path: root/v4l
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2006-06-21 16:31:24 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-06-21 16:31:24 -0300
commitba915ac86439f7c2e134346710e2c95835fa8b68 (patch)
tree021452a2fb46ed3b552e37383b212e482163f2e8 /v4l
parente7a1d090b86f3e99145a255967b4d49cbaf36087 (diff)
downloadmediapointer-dvb-s2-ba915ac86439f7c2e134346710e2c95835fa8b68.tar.gz
mediapointer-dvb-s2-ba915ac86439f7c2e134346710e2c95835fa8b68.tar.bz2
Some cleanups at the release script
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'v4l')
-rw-r--r--v4l/Makefile11
1 files changed, 6 insertions, 5 deletions
diff --git a/v4l/Makefile b/v4l/Makefile
index 881329d7d..a034be061 100644
--- a/v4l/Makefile
+++ b/v4l/Makefile
@@ -158,12 +158,13 @@ ifneq ($(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
ifneq ($(DIR),)
- @perl -e 'open IN,"<$(DIR)/Makefile"; \
+ @echo "Seeking for a version at $(DIR)/Makefile."
+ @perl -e 'open IN,"$(DIR)/Makefile"; \
while (<IN>) { \
- if (/^VERSION\s*=\s*([0-9]+)/){ $$version=$$1; next; }\
- if (/^PATCHLEVEL\s*=\s*([0-9]+)/){ $$level=$$1; next; }\
- if (/^SUBLEVEL\s*=\s*([0-9]+)/){ $$sublevel=$$1; next; }\
- if (/^EXTRAVERSION\s*=\s*([^\s]+)\n/){ $$extra=$$1; next; }\
+ if (/^VERSION\s*=\s*([0-9]+)/){ $$version=$$1; }\
+ elsif (/^PATCHLEVEL\s*=\s*([0-9]+)/){ $$level=$$1; }\
+ elsif (/^SUBLEVEL\s*=\s*([0-9]+)/){ $$sublevel=$$1; }\
+ elsif (/^EXTRAVERSION\s*=\s*([^\s]+)\n/){ $$extra=$$1; }\
}; \
printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n", \
$$version,$$level,$$sublevel,$$version,$$level,$$sublevel,$$extra); \