Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libffi: hide platform-ignorant FFI ABI enum values #1318

Merged
merged 3 commits into from
Feb 1, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
2 changes: 1 addition & 1 deletion libffi/src/gen/java/org/bytedeco/libffi/ffi_cif.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
2 changes: 1 addition & 1 deletion libffi/src/gen/java/org/bytedeco/libffi/ffi_closure.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
2 changes: 1 addition & 1 deletion libffi/src/gen/java/org/bytedeco/libffi/ffi_java_raw.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
2 changes: 1 addition & 1 deletion libffi/src/gen/java/org/bytedeco/libffi/ffi_raw.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
2 changes: 1 addition & 1 deletion libffi/src/gen/java/org/bytedeco/libffi/ffi_type.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi;

Expand Down
20 changes: 3 additions & 17 deletions libffi/src/gen/java/org/bytedeco/libffi/global/ffi.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
// Targeted by JavaCPP version 1.5.9-SNAPSHOT: DO NOT EDIT THIS FILE

package org.bytedeco.libffi.global;

Expand Down Expand Up @@ -83,23 +83,9 @@ a copy of this software and associated documentation files (the
// #endif

/** enum ffi_abi */
public static final int
// #if defined(X86_WIN64)

// #elif defined(X86_64) || (defined (__x86_64__) && defined (X86_DARWIN))
;
public static native @MemberGetter int FFI_DEFAULT_ABI();

// #elif defined(X86_WIN32)
// #else
FFI_FIRST_ABI = 0,
FFI_SYSV = 1,
FFI_THISCALL = 3,
FFI_FASTCALL = 4,
FFI_STDCALL = 5,
FFI_PASCAL = 6,
FFI_REGISTER = 7,
FFI_MS_CDECL = 8,
FFI_LAST_ABI = 9,
FFI_DEFAULT_ABI = FFI_SYSV;
// #endif
// #endif

Expand Down
4 changes: 3 additions & 1 deletion libffi/src/main/java/org/bytedeco/libffi/presets/ffi.java
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ public void map(InfoMap infoMap) {
.put(new Info("_ffi_type").pointerTypes("ffi_type"))
.put(new Info("void (*)(void)").cast().pointerTypes("Pointer"))
.put(new Info("__attribute__((deprecated))").annotations("@Deprecated"))
.put(new Info("FFI_FIRST_ABI", "FFI_SYSV", "FFI_THISCALL", "FFI_FASTCALL",
"FFI_STDCALL", "FFI_PASCAL", "FFI_REGISTER", "FFI_MS_CDECL",
"FFI_LAST_ABI", "FFI_DEFAULT_ABI").skip())
saudet marked this conversation as resolved.
Show resolved Hide resolved
;
}

Expand All @@ -100,5 +103,4 @@ public void map(InfoMap infoMap) {
public static native @MemberGetter @Platform(pattern = ".*-ppc64.*") int FFI_LINUX_LONG_DOUBLE_128();
public static native @MemberGetter @Platform(pattern = ".*-ppc64.*") int FFI_LINUX_LONG_DOUBLE_IEEE128();
public static native @MemberGetter int FFI_LAST_ABI();
public static native @MemberGetter int FFI_DEFAULT_ABI();
}