1#!/bin/sh 2 3set -e 4 5if [ -d bin ]; then 6 cd bin 7else 8 echo "Please run this script from the source root folder" 9 exit 10fi 11 12PWD="$(dirname "$0")" 13 14if [ -f "$PWD/lv2_ttl_generator.exe" ]; then 15 GEN="$PWD/lv2_ttl_generator.exe" 16 EXT=dll 17else 18 GEN="$PWD/lv2_ttl_generator" 19 if [ -d /Library/Audio ]; then 20 EXT=dylib 21 else 22 EXT=so 23 fi 24fi 25 26FOLDERS=`find . -type d -name \*.lv2` 27 28for i in $FOLDERS; do 29 cd $i 30 FILE="$(ls *.$EXT | sort | head -n 1)" 31 "$GEN" "./$FILE" 32 cd .. 33done 34