diff options
author | Sven Gothel <[email protected]> | 2014-06-18 20:15:09 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2014-06-18 20:15:09 +0200 |
commit | 9a66c005a3cd304c4b47abd9a287a60e3545b9da (patch) | |
tree | 2f03b70459159bd3b2575446ef8fcbc9a461a71f | |
parent | f670d9486765a68bf933b75be46bb277b9b4f1e9 (diff) |
Add java major version checks for generated class files
-rwxr-xr-x | scripts/check-java-major-version.sh | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/scripts/check-java-major-version.sh b/scripts/check-java-major-version.sh new file mode 100755 index 0000000..8526c02 --- /dev/null +++ b/scripts/check-java-major-version.sh @@ -0,0 +1,29 @@ +#! /bin/bash + +TDIR=`pwd` + +function dump_version() { + echo -n "$1: " + javap -v $1 | grep 'major version' +} + +function dump_versions() { + cd $1 + #dump_version jogamp.common.Debug + javap -v `find . -name '*.class'` | grep -e '^Classfile' -e 'major version' + #for i in `find . -name '*.class'` ; do + # dump_version `echo $i | sed -e 's/\//./g' -e 's/\.class//g'` + #done + cd $TDIR +} + +function do_it() { + dump_versions target/classes +} + +do_it 2>&1 | tee check-java-major-version.log +echo +echo VERSIONS found: +echo +grep 'major version' check-java-major-version.log | sort -u + |