../.meta/prefix.mk: ../.meta/prefix-Liste ../.meta/generiere-mks.mk { \ cat "$<"; \ for ton in c d e f g a h; do \ for halbton in "" is es; do \ for oktave in "" ,; do \ printf '%s%s%s\n' "$${ton}" "$${halbton}" "$${oktave}"; \ done; \ done; \ done \ | sed " \ s/^ees/es/; \ s/^hes/b/; \ s/^/transponiert-/; \ "; \ seq 20 \ | sed 'p;h;s/$$/E/;g;s/$$/S/'; \ for i in {1..20}; do \ for j in {1..6}; do \ printf '%s.%s\n' "$${i}" "$${j}"; \ printf '%sS.%s\n' "$${i}" "$${j}"; \ printf '%sE.%s\n' "$${i}" "$${j}"; \ done; \ done; \ } \ | while read -r prefix; do \ printf '%%-%s.pre: ' "$${prefix}"; \ printf '%%.pre\n' "$${prefix}"; \ printf '\tsed " \\\n'; \ if [ -z "$${prefix##transponiert-*}" ]; then \ printf '\t\t1i define(\\`transponiert'"'"',\\`%s'"'"') \\\n' "$${prefix#transponiert-}"; \ elif echo "$${prefix}" | grep -qx "[0-9]\+[ES]\?"; then \ nummer=$$(echo "$${prefix}" | sed 's/[ES]$$//'); \ printf '\t\t1i define(\\`STR_%s'"'"',\\`%s'"'"') \\\n' "$${prefix}" "$${nummer}"; \ elif echo "$${prefix}" | grep -qx "[0-9]\+[ES]\?\.[0-9]\+"; then \ printf '\t\t1i define(\\`STR_%s'"'"',\\`%s'"'"') \\\n' "$${prefix%.*}" "$${prefix#*.}"; \ else \ printf '\t\t1i define(\\`%s'"'"') \\\n' "$${prefix}"; \ fi; \ printf '\t" "$$<" >"$$@"\n'; \ printf '\n'; \ done \ >"$@" ../.meta/papierformat.mk: ../.meta/generiere-mks.mk ../.meta/*.papierformat for datei in ../.meta/*.papierformat; do \ name="$${datei##*/}"; \ name="$${name%.*}"; \ printf "%%-%s.pre: %s %%.pre\n" "$${name}" "$${datei}"; \ printf "\tcat \$$^ > \$$@\n"; \ done \ >"$@" meta.mk: ../.meta/papierformat.mk ../.meta/prefix.mk .PHONY: meta.mk