changeset 1:ac47394e6503

Initial processing
author Chris Cannam
date Mon, 14 Jul 2014 13:47:37 +0100
parents e3a9ff791a5e
children 4e4f3903643d
files .hgignore process.sh
diffstat 2 files changed, 46 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.hgignore	Mon Jul 14 13:47:37 2014 +0100
@@ -0,0 +1,2 @@
+syntax: glob
+*~
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/process.sh	Mon Jul 14 13:47:37 2014 +0100
@@ -0,0 +1,44 @@
+#!/bin/bash
+
+## Things to test:
+##   the plugin builds!
+##   plugin loads
+##   passes vamp-plugin-tester tests
+##   does not export any unnecessary symbols
+##   has valid .cat and .n3
+
+platform=linux
+
+configure_maybe() {
+    dir="$1"
+    if [ ! -f "$dir/Makefile" ] ; then
+	if [ -f "$dir/configure" ] ; then
+	    ( cd "$dir" ; ./configure )
+	fi
+    fi
+}
+
+find_makefile() {
+    dir="$1"
+    for f in Makefile Makefile.$platform build/$platform/Makefile build/$platform/Makefile.$platform ; do
+	if [ -f "$dir/$f" ]; then
+	    echo $f
+	    break
+	fi
+    done
+}
+
+for dir in $(cat .hgsub | awk '{ print $1; }') ; do
+    echo
+    echo "Processing: $dir"
+    if configure_maybe "$dir"; then
+	mfile=$(find_makefile "$dir")
+	if [ -n "$mfile" ]; then
+	    make -C "$dir" -f "$mfile"
+	else
+	    echo "Failed to find a Makefile in $dir"
+	fi
+    fi
+done
+
+