mirror of
https://github.com/TheCase/IPMIView.app.git
synced 2025-12-11 17:49:43 +01:00
Compare commits
4 Commits
e06b3da5ad
...
1a3d28205d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1a3d28205d | ||
|
|
15dd265c54 | ||
|
|
5bc388f167 | ||
|
|
6093ffba4c |
Binary file not shown.
@@ -1,18 +0,0 @@
|
||||
public class PropertyPrint {
|
||||
public static void main(String[] args) {
|
||||
if(null == args || 0 == args.length) {
|
||||
args = new String[] { "java.version" };
|
||||
}
|
||||
|
||||
for(int i=0; i<args.length; ++i) {
|
||||
String property = args[i];
|
||||
|
||||
if(i > 0) {
|
||||
System.out.print(' ');
|
||||
}
|
||||
|
||||
System.out.print(System.getProperty(property));
|
||||
}
|
||||
System.out.println();
|
||||
}
|
||||
}
|
||||
16
script.sh
16
script.sh
@@ -82,21 +82,11 @@ fi
|
||||
echo "Using Java from $JAVA_HOME"
|
||||
arch=$( arch )
|
||||
if [ "$arch" = "x86_64" ] ; then
|
||||
echo "Okay, using x86-64 platform."
|
||||
echo "Using ${arch} platform."
|
||||
elif [ "$arch" = "arm64" -o "$arch" = "aarch64" ] ; then
|
||||
echo "Using aarm64 platform. Checking Java version..."
|
||||
echo "Using ${arch} platform. Checking Java version..."
|
||||
|
||||
if [ -x "$JAVA_HOME/bin/javac" ] ; then
|
||||
if [ ! -f PropertyPrint.class ] ; then
|
||||
"$JAVA_HOME/bin/javac" -target 1.8 PropertyPrint.java
|
||||
fi
|
||||
else
|
||||
echo "Cannot determine Java architecture because you do not have a JDK installed."
|
||||
|
||||
exit 1
|
||||
fi
|
||||
|
||||
jarch=$( $JAVA_HOME/bin/java -classpath . PropertyPrint os.arch )
|
||||
jarch=$( "${JAVA_HOME}/bin/java" -XshowSettings:properties -version 2>&1 | grep 'os.arch' | sed -e 's/.*=[ ]*//' )
|
||||
|
||||
if [ "x86_64" != "$jarch" ] ; then
|
||||
echo "*"
|
||||
|
||||
Reference in New Issue
Block a user