aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <m.chehab@samsung.com>2014-09-04 22:53:32 -0300
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-09-04 22:53:32 -0300
commit78988921cd3cdef0d94ba111fbcf7d813e07e02a (patch)
treea27260e961c0d5daf8503ea2f44a6dee8e52ac08
parenta5a55e789f991fccc307794a9d500b8e530c2674 (diff)
downloaddtv-scan-tables-78988921cd3cdef0d94ba111fbcf7d813e07e02a.tar.gz
Makefile: Add support to convert from DVBv5 to DVBv3
That does the conversion from a previously generated DVBv5 directory back to DVBv3. This is useful to check if dvb-fe-convert is doing the right thing. Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r--Makefile15
1 files changed, 13 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index fac40e71..d1c1e938 100644
--- a/Makefile
+++ b/Makefile
@@ -13,13 +13,24 @@
MKDIR = mkdir -p
DVBFORMATCONVERT = dvb-format-convert
-DVBFORMATCONVERT_CHANNEL_DVBV5 = -ICHANNEL -ODVBV5
-
DVBV3DIRS = atsc dvb-c dvb-s dvb-t
+
DVBV3CHANNELFILES = $(foreach dir,$(DVBV3DIRS),$(wildcard $(dir)/*))
+DVBFORMATCONVERT_CHANNEL_DVBV5 = -ICHANNEL -ODVBV5
+DVBFORMATCONVERT_CHANNEL_DVBV3 = -IDVBV5 -OCHANNEL
+
+DVBV3OUTPUTDIR = dvbv3
DVBV5OUTPUTDIR = dvbv5
makedvbv5:
@$(foreach var,$(DVBV3DIRS), $(MKDIR) $(DVBV5OUTPUTDIR)/$(var);)
@$(foreach var,$(DVBV3CHANNELFILES), $(DVBFORMATCONVERT) $(DVBFORMATCONVERT_CHANNEL_DVBV5) $(var) $(DVBV5OUTPUTDIR)/$(var);)
+
+makedvbv3:
+ @$(foreach var,$(DVBV3DIRS), $(MKDIR) $(DVBV3OUTPUTDIR)/$(var);)
+ @$(foreach var,$(DVBV3CHANNELFILES), $(DVBFORMATCONVERT) $(DVBFORMATCONVERT_CHANNEL_DVBV3) $(DVBV5OUTPUTDIR)/$(var) $(DVBV3OUTPUTDIR)/$(var);)
+
+
+clean:
+ rm -rf $(DVBV3OUTPUTDIR)/ $(DVBV5OUTPUTDIR)/