diff options
Diffstat (limited to 'print/lilypond-devel/scripts/post-patch')
-rw-r--r-- | print/lilypond-devel/scripts/post-patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/print/lilypond-devel/scripts/post-patch b/print/lilypond-devel/scripts/post-patch new file mode 100644 index 000000000000..aff5fb958c45 --- /dev/null +++ b/print/lilypond-devel/scripts/post-patch @@ -0,0 +1,20 @@ +#!/bin/sh +outdir=out +cd ${WRKSRC} || exit 2 +echo "Patching for FlexLexer.h <->gcc3 issues" + +file="" +candidates=`find /usr/include -name FlexLexer.h` +#take first found file. +for d in $candidates; do if [ -f $d ]; then file=$d; break; fi; done +if [ -z "${file}" ]; then echo "Cannot find FlexLexer.h"; exit 2; fi + +echo -n "Copying and fixing $file... " +mkdir -p lily/$outdir +rm -f lily/$outdir/FlexLexer.h +sed \ + -e 's/istream/std::istream/' \ + -e 's/[^i]ostream/std::ostream/' \ + -e 's/iostream.h/iostream/' \ + $file > lily/$outdir/FlexLexer.h +echo "done" |