Permalink
Browse files

LINUX ARM compatibility

  • Loading branch information...
Thomas Butter
Thomas Butter committed Feb 7, 2015
1 parent 1fdc77b commit 055e273ecc0f7448fc074f202beff0e384bf31af
View
@@ -12,7 +12,7 @@ repositories {
dependencies {
compile 'net.java.dev.jna:jna:3.5.2'
compile 'net.java.dev.jna:jna:4.1.0'
compile "org.codehaus.groovy:groovy-all:2.1.5"
}
@@ -12,7 +12,7 @@
{
public static enum PlatformEnum
{
LINUX_X86_64, LINUX_I686, LINUX_PPC, MAC, MAC_MACFUSE, FREEBSD
LINUX_X86_64, LINUX_I686, LINUX_PPC, MAC, MAC_MACFUSE, FREEBSD, LINUX_ARM
}
private static final String[] osxFuseLibraries = { "fuse4x", "osxfuse", "macfuse", "fuse" };
@@ -81,6 +81,9 @@ private static final void init()
if (com.sun.jna.Platform.isIntel()) {
platform = com.sun.jna.Platform.is64Bit() ? PlatformEnum.LINUX_X86_64 : PlatformEnum.LINUX_I686;
}
else if (com.sun.jna.Platform.isARM()) {
platform = PlatformEnum.LINUX_ARM;
}
else {
platform = PlatformEnum.LINUX_PPC;
}
@@ -98,6 +98,7 @@ public final int callback(final String path, final StructStat.X86_64.ByReference
}
};
break;
case LINUX_ARM:
case LINUX_I686:
getattr = new Callback()
{
@@ -17,6 +17,7 @@
size = 8;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
size = Platform.size(TypeLongLong.class);
break;
@@ -17,6 +17,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(NativeLong.class);
@@ -16,6 +16,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(TypeLongLong.class);
@@ -17,6 +17,7 @@
size = Platform.size(NativeLong.class);
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(TypeLongLong.class);
@@ -16,6 +16,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(Integer.class);
@@ -19,6 +19,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
size = Platform.size(TypeLongLong.class);
break;
@@ -164,6 +164,7 @@ public final long getBits()
size = 2;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(Integer.class);
@@ -17,6 +17,7 @@
size = 2;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
size = Platform.size(Integer.class);
break;
@@ -16,6 +16,7 @@
size = 8;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(TypeLongLong.class);
@@ -16,6 +16,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(Integer.class);
@@ -17,6 +17,7 @@
size = 8;
break;
case LINUX_I686:
case LINUX_ARM:
size = 4;
break;
case LINUX_PPC:
@@ -16,6 +16,7 @@
size = 4;
break;
case LINUX_I686:
case LINUX_ARM:
case LINUX_PPC:
case LINUX_X86_64:
size = Platform.size(Integer.class);

0 comments on commit 055e273

Please sign in to comment.