summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rwxr-xr-xscripts/gentables13
2 files changed, 7 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index 4105040..bff9337 100644
--- a/Makefile
+++ b/Makefile
@@ -150,7 +150,7 @@ $(DEPFILE): Makefile
$(CXX) $(CXXFLAGS) $(DEFINES) $(INCLUDES) -c $<
mg_tables.h: scripts/genres.txt scripts/iso_639.xml scripts/musictypes.txt scripts/sources.txt
- scripts/gentables
+ scripts/gentables > $@
libvdr-$(PLUGIN).so: $(OBJS)
$(CXX) $(CXXFLAGS) -shared $(OBJS) $(PLAYLIBS) $(SQLLIBS) -o $@
diff --git a/scripts/gentables b/scripts/gentables
index f7fcc89..7d2494a 100755
--- a/scripts/gentables
+++ b/scripts/gentables
@@ -1,3 +1,4 @@
+#!/bin/sh
(
echo "
@@ -5,7 +6,7 @@
genres_t genres[] = {"
-cat scripts/genres.txt | while read gdid id3 name
+cat `dirname $0`/genres.txt | while read gdid id3 name
do
test "$id3" = N && id3=-1
test "$gdid" = NULL && break
@@ -16,7 +17,7 @@ echo '};
echo "lang_t languages[] = {"
-scripts/iso639tab.py scripts/iso_639.xml |
+`dirname $0`/iso639tab.py `dirname $0`/iso_639.xml |
grep -v '^#' |
grep -v '^$' |
while read iso1 iso2 iso3 name
@@ -28,7 +29,7 @@ echo '};
echo "musictypes_t musictypes[] = {"
-cat scripts/musictypes.txt | while read mtype
+cat `dirname $0`/musictypes.txt | while read mtype
do
echo ' { "'$mtype'"},'
done
@@ -37,11 +38,9 @@ echo '};
echo "sources_t sources[] = {"
-cat scripts/sources.txt | while read stype
+cat `dirname $0`/sources.txt | while read stype
do
echo ' { "'$stype'"},'
done
echo '};'
-) >mg_tables.h
-
-
+)