ffi 1.0.11 → 1.0.12.pre
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of ffi might be problematic. Click here for more details.
- data/Rakefile +1 -1
- data/ext/ffi_c/AbstractMemory.c +9 -0
- data/ext/ffi_c/AbstractMemory.h +4 -0
- data/ext/ffi_c/Buffer.c +8 -0
- data/ext/ffi_c/Call.c +8 -0
- data/ext/ffi_c/ClosurePool.c +12 -0
- data/ext/ffi_c/DynamicLibrary.c +7 -1
- data/ext/ffi_c/Function.c +11 -1
- data/ext/ffi_c/Function.h +6 -0
- data/ext/ffi_c/FunctionInfo.c +8 -0
- data/ext/ffi_c/LastError.c +8 -0
- data/ext/ffi_c/MemoryPointer.c +8 -0
- data/ext/ffi_c/MemoryPointer.h +6 -0
- data/ext/ffi_c/MethodHandle.c +8 -0
- data/ext/ffi_c/Platform.c +8 -0
- data/ext/ffi_c/Pointer.c +8 -0
- data/ext/ffi_c/Pointer.h +6 -0
- data/ext/ffi_c/Struct.c +6 -0
- data/ext/ffi_c/StructByReference.c +8 -0
- data/ext/ffi_c/StructByValue.c +8 -0
- data/ext/ffi_c/StructLayout.c +6 -0
- data/ext/ffi_c/Thread.c +7 -0
- data/ext/ffi_c/Thread.h +6 -0
- data/ext/ffi_c/Type.c +3 -0
- data/ext/ffi_c/Types.h +4 -0
- data/ext/ffi_c/Variadic.c +8 -0
- data/ext/ffi_c/endian.h +3 -0
- data/ext/ffi_c/extconf.rb +6 -1
- data/ext/ffi_c/libffi.vc.mk +26 -0
- data/ext/ffi_c/libffi.vc64.mk +26 -0
- data/ext/ffi_c/libffi/ChangeLog +541 -0
- data/ext/ffi_c/libffi/ChangeLog.libffi +13 -87
- data/ext/ffi_c/libffi/LICENSE +3 -3
- data/ext/ffi_c/libffi/Makefile.am +41 -32
- data/ext/ffi_c/libffi/Makefile.in +95 -66
- data/ext/ffi_c/libffi/Makefile.vc +141 -0
- data/ext/ffi_c/libffi/Makefile.vc64 +141 -0
- data/ext/ffi_c/libffi/README +40 -4
- data/ext/ffi_c/libffi/aclocal.m4 +729 -7854
- data/ext/ffi_c/libffi/build-ios.sh +67 -0
- data/ext/ffi_c/libffi/compile +11 -10
- data/ext/ffi_c/libffi/config.guess +4 -1
- data/ext/ffi_c/libffi/config.sub +6 -3
- data/ext/ffi_c/libffi/configure +6264 -6354
- data/ext/ffi_c/libffi/configure.ac +155 -63
- data/ext/ffi_c/libffi/depcomp +81 -35
- data/ext/ffi_c/libffi/doc/libffi.info +78 -18
- data/ext/ffi_c/libffi/doc/libffi.texi +64 -5
- data/ext/ffi_c/libffi/doc/stamp-vti +4 -4
- data/ext/ffi_c/libffi/doc/version.texi +4 -4
- data/ext/ffi_c/libffi/fficonfig.h.in +18 -0
- data/ext/ffi_c/libffi/fficonfig.hw +57 -0
- data/ext/ffi_c/libffi/include/Makefile.in +21 -3
- data/ext/ffi_c/libffi/include/ffi.h.in +42 -14
- data/ext/ffi_c/libffi/include/ffi.h.vc +427 -0
- data/ext/ffi_c/libffi/include/ffi.h.vc64 +427 -0
- data/ext/ffi_c/libffi/include/ffi_common.h +9 -5
- data/ext/ffi_c/libffi/install-sh +364 -167
- data/ext/ffi_c/libffi/ltmain.sh +2599 -1369
- data/ext/ffi_c/libffi/m4/ax_cc_maxopt.m4 +176 -0
- data/ext/ffi_c/libffi/m4/ax_cflags_warn_all.m4 +195 -0
- data/ext/ffi_c/libffi/m4/ax_check_compiler_flags.m4 +76 -0
- data/ext/ffi_c/libffi/m4/ax_compiler_vendor.m4 +63 -0
- data/ext/ffi_c/libffi/m4/ax_configure_args.m4 +70 -0
- data/ext/ffi_c/libffi/m4/ax_enable_builddir.m4 +300 -0
- data/ext/ffi_c/libffi/m4/ax_gcc_archflag.m4 +215 -0
- data/ext/ffi_c/libffi/m4/ax_gcc_x86_cpuid.m4 +79 -0
- data/ext/ffi_c/libffi/m4/libtool.m4 +1239 -768
- data/ext/ffi_c/libffi/m4/ltoptions.m4 +7 -6
- data/ext/ffi_c/libffi/m4/ltversion.m4 +6 -6
- data/ext/ffi_c/libffi/m4/lt~obsolete.m4 +9 -3
- data/ext/ffi_c/libffi/man/Makefile.in +21 -3
- data/ext/ffi_c/libffi/mdate-sh +0 -0
- data/ext/ffi_c/libffi/missing +60 -44
- data/ext/ffi_c/libffi/msvcc.sh +197 -0
- data/ext/ffi_c/libffi/src/alpha/osf.S +39 -18
- data/ext/ffi_c/libffi/src/arm/ffi.c +443 -24
- data/ext/ffi_c/libffi/src/arm/ffitarget.h +17 -1
- data/ext/ffi_c/libffi/src/arm/gentramp.sh +118 -0
- data/ext/ffi_c/libffi/src/arm/sysv.S +206 -15
- data/ext/ffi_c/libffi/src/arm/trampoline.S +4450 -0
- data/ext/ffi_c/libffi/src/avr32/ffi.c +4 -2
- data/ext/ffi_c/libffi/src/avr32/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/closures.c +17 -35
- data/ext/ffi_c/libffi/src/cris/ffi.c +1 -1
- data/ext/ffi_c/libffi/src/cris/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/dlmalloc.c +66 -4
- data/ext/ffi_c/libffi/src/frv/ffitarget.h +2 -6
- data/ext/ffi_c/libffi/src/ia64/ffi.c +7 -5
- data/ext/ffi_c/libffi/src/ia64/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/java_raw_api.c +1 -1
- data/ext/ffi_c/libffi/src/m32r/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/m68k/ffi.c +10 -0
- data/ext/ffi_c/libffi/src/m68k/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/m68k/sysv.S +36 -0
- data/ext/ffi_c/libffi/src/mips/ffi.c +12 -5
- data/ext/ffi_c/libffi/src/mips/ffitarget.h +18 -11
- data/ext/ffi_c/libffi/src/mips/n32.S +4 -4
- data/ext/ffi_c/libffi/src/moxie/eabi.S +128 -0
- data/ext/ffi_c/libffi/src/moxie/ffi.c +276 -0
- data/ext/ffi_c/libffi/src/pa/ffi.c +7 -4
- data/ext/ffi_c/libffi/src/pa/ffitarget.h +6 -5
- data/ext/ffi_c/libffi/src/powerpc/aix.S +5 -1
- data/ext/ffi_c/libffi/src/powerpc/aix_closure.S +2 -0
- data/ext/ffi_c/libffi/src/powerpc/asm.h +1 -1
- data/ext/ffi_c/libffi/src/powerpc/darwin.S +215 -77
- data/ext/ffi_c/libffi/src/powerpc/darwin_closure.S +358 -100
- data/ext/ffi_c/libffi/src/powerpc/ffi.c +11 -5
- data/ext/ffi_c/libffi/src/powerpc/ffi_darwin.c +603 -172
- data/ext/ffi_c/libffi/src/powerpc/ffitarget.h +17 -4
- data/ext/ffi_c/libffi/src/prep_cif.c +16 -13
- data/ext/ffi_c/libffi/src/s390/ffitarget.h +4 -2
- data/ext/ffi_c/libffi/src/sh/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/sh64/ffitarget.h +2 -2
- data/ext/ffi_c/libffi/src/sparc/ffi.c +55 -11
- data/ext/ffi_c/libffi/src/sparc/ffitarget.h +5 -3
- data/ext/ffi_c/libffi/src/x86/ffi.c +54 -92
- data/ext/ffi_c/libffi/src/x86/ffi64.c +17 -8
- data/ext/ffi_c/libffi/src/x86/ffitarget.h +15 -14
- data/ext/ffi_c/libffi/src/x86/sysv.S +40 -26
- data/ext/ffi_c/libffi/src/x86/unix64.S +4 -0
- data/ext/ffi_c/libffi/src/x86/win32.S +379 -191
- data/ext/ffi_c/libffi/src/x86/win64.S +15 -7
- data/ext/ffi_c/libffi/testsuite/Makefile.am +1 -1
- data/ext/ffi_c/libffi/testsuite/Makefile.in +22 -4
- data/ext/ffi_c/libffi/testsuite/lib/libffi.exp +350 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/call.exp +1 -5
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_align_longdouble_split.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_align_longdouble_split2.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_align_sint64.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_align_uint64.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_double_va.c +3 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_longdouble.c +2 -2
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_longdouble_va.c +3 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_pointer.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_pointer_stack.c +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/err_bad_abi.c +2 -3
- data/ext/ffi_c/libffi/testsuite/libffi.call/err_bad_typedef.c +2 -1
- data/ext/ffi_c/libffi/testsuite/libffi.call/ffitest.h +36 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/huge_struct.c +17 -17
- data/ext/ffi_c/libffi/testsuite/libffi.call/return_ll1.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.call/stret_medium2.c +1 -0
- data/ext/ffi_c/libffi/testsuite/libffi.special/ffitestcxx.h +1 -1
- data/ext/ffi_c/libffi/testsuite/libffi.special/special.exp +1 -3
- data/ext/ffi_c/win32/stdint.h +199 -0
- data/gen/Rakefile +18 -2
- data/lib/ffi/platform/arm-linux/types.conf +102 -0
- data/lib/ffi/platform/i486-gnu/types.conf +107 -0
- data/lib/ffi/platform/ia64-linux/types.conf +102 -0
- data/lib/ffi/platform/mips-linux/types.conf +102 -0
- data/lib/ffi/platform/mipsel-linux/types.conf +102 -0
- data/lib/ffi/platform/powerpc-linux/types.conf +100 -0
- data/lib/ffi/platform/s390-linux/types.conf +102 -0
- data/lib/ffi/platform/s390x-linux/types.conf +102 -0
- data/lib/ffi/platform/sparc-linux/types.conf +102 -0
- data/lib/ffi/tools/types_generator.rb +8 -1
- data/lib/ffi_c.bundle +0 -0
- metadata +72 -42
data/Rakefile
CHANGED
@@ -75,7 +75,7 @@ PROJ.name = 'ffi'
|
|
75
75
|
PROJ.authors = 'Wayne Meissner'
|
76
76
|
PROJ.email = 'wmeissner@gmail.com'
|
77
77
|
PROJ.url = 'http://wiki.github.com/ffi/ffi'
|
78
|
-
PROJ.version = '1.0.
|
78
|
+
PROJ.version = '1.0.12.pre'
|
79
79
|
PROJ.rubyforge.name = 'ffi'
|
80
80
|
PROJ.readme_file = 'README.rdoc'
|
81
81
|
|
data/ext/ffi_c/AbstractMemory.c
CHANGED
@@ -19,11 +19,20 @@
|
|
19
19
|
*/
|
20
20
|
|
21
21
|
#include <sys/types.h>
|
22
|
+
#ifndef _MSC_VER
|
22
23
|
#include <sys/param.h>
|
23
24
|
#include <stdint.h>
|
24
25
|
#include <stdbool.h>
|
26
|
+
#else
|
27
|
+
typedef int bool;
|
28
|
+
#define true 1
|
29
|
+
#define false 0
|
30
|
+
#endif
|
25
31
|
#include <limits.h>
|
26
32
|
#include <ruby.h>
|
33
|
+
#if defined(_MSC_VER) && !defined(INT8_MIN)
|
34
|
+
# include "win32/stdint.h"
|
35
|
+
#endif
|
27
36
|
#include "rbffi.h"
|
28
37
|
#include "compat.h"
|
29
38
|
#include "AbstractMemory.h"
|
data/ext/ffi_c/AbstractMemory.h
CHANGED
@@ -21,9 +21,13 @@
|
|
21
21
|
#ifndef RBFFI_ABSTRACTMEMORY_H
|
22
22
|
#define RBFFI_ABSTRACTMEMORY_H
|
23
23
|
|
24
|
+
#ifndef _MSC_VER
|
24
25
|
#include <sys/param.h>
|
26
|
+
#endif
|
25
27
|
#include <sys/types.h>
|
28
|
+
#ifndef _MSC_VER
|
26
29
|
#include <stdint.h>
|
30
|
+
#endif
|
27
31
|
|
28
32
|
#include "compat.h"
|
29
33
|
#include "Types.h"
|
data/ext/ffi_c/Buffer.c
CHANGED
@@ -18,8 +18,16 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <stdbool.h>
|
23
|
+
#else
|
24
|
+
typedef int bool;
|
25
|
+
#define true 1
|
26
|
+
#define false 0
|
27
|
+
#endif
|
28
|
+
#ifndef _MSC_VER
|
22
29
|
#include <stdint.h>
|
30
|
+
#endif
|
23
31
|
#include <limits.h>
|
24
32
|
#include <ruby.h>
|
25
33
|
#include "rbffi.h"
|
data/ext/ffi_c/Call.c
CHANGED
@@ -20,11 +20,19 @@
|
|
20
20
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
21
21
|
*/
|
22
22
|
|
23
|
+
#ifndef _MSC_VER
|
23
24
|
#include <sys/param.h>
|
25
|
+
#endif
|
24
26
|
#include <sys/types.h>
|
25
27
|
#include <stdio.h>
|
28
|
+
#ifndef _MSC_VER
|
26
29
|
#include <stdint.h>
|
27
30
|
#include <stdbool.h>
|
31
|
+
#else
|
32
|
+
typedef int bool;
|
33
|
+
#define true 1
|
34
|
+
#define false 0
|
35
|
+
#endif
|
28
36
|
#include <errno.h>
|
29
37
|
#include <ruby.h>
|
30
38
|
#if defined(HAVE_NATIVETHREAD) && defined(HAVE_RB_THREAD_BLOCKING_REGION) && !defined(_WIN32)
|
data/ext/ffi_c/ClosurePool.c
CHANGED
@@ -17,23 +17,35 @@
|
|
17
17
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
18
18
|
*/
|
19
19
|
|
20
|
+
#ifndef _MSC_VER
|
20
21
|
#include <sys/param.h>
|
22
|
+
#endif
|
21
23
|
#include <sys/types.h>
|
22
24
|
#ifndef _WIN32
|
23
25
|
# include <sys/mman.h>
|
24
26
|
#endif
|
25
27
|
#include <stdio.h>
|
28
|
+
#ifndef _MSC_VER
|
26
29
|
#include <stdint.h>
|
27
30
|
#include <stdbool.h>
|
31
|
+
#else
|
32
|
+
typedef int bool;
|
33
|
+
#define true 1
|
34
|
+
#define false 0
|
35
|
+
#endif
|
28
36
|
#ifndef _WIN32
|
29
37
|
# include <unistd.h>
|
30
38
|
#else
|
39
|
+
# include <winsock2.h>
|
31
40
|
# define _WINSOCKAPI_
|
32
41
|
# include <windows.h>
|
33
42
|
#endif
|
34
43
|
#include <errno.h>
|
35
44
|
#include <ruby.h>
|
36
45
|
|
46
|
+
#if defined(_MSC_VER) && !defined(INT8_MIN)
|
47
|
+
# include "win32/stdint.h"
|
48
|
+
#endif
|
37
49
|
#include <ffi.h>
|
38
50
|
#include "rbffi.h"
|
39
51
|
#include "compat.h"
|
data/ext/ffi_c/DynamicLibrary.c
CHANGED
@@ -20,14 +20,20 @@
|
|
20
20
|
|
21
21
|
#include <sys/types.h>
|
22
22
|
#include <stdio.h>
|
23
|
-
#
|
23
|
+
#ifndef _MSC_VER
|
24
|
+
# include <stdint.h>
|
25
|
+
#endif
|
24
26
|
#if defined(_WIN32) || defined(__WIN32__)
|
27
|
+
# include <winsock2.h>
|
25
28
|
# define _WINSOCKAPI_
|
26
29
|
# include <windows.h>
|
27
30
|
#else
|
28
31
|
# include <dlfcn.h>
|
29
32
|
#endif
|
30
33
|
#include <ruby.h>
|
34
|
+
#if defined(_MSC_VER) && !defined(INT8_MIN)
|
35
|
+
# include "win32/stdint.h"
|
36
|
+
#endif
|
31
37
|
|
32
38
|
#include <ffi.h>
|
33
39
|
|
data/ext/ffi_c/Function.c
CHANGED
@@ -20,16 +20,26 @@
|
|
20
20
|
|
21
21
|
#include "MethodHandle.h"
|
22
22
|
|
23
|
-
|
23
|
+
#ifndef _MSC_VER
|
24
24
|
#include <sys/param.h>
|
25
|
+
#endif
|
25
26
|
#include <sys/types.h>
|
26
27
|
#ifndef _WIN32
|
27
28
|
# include <sys/mman.h>
|
28
29
|
#endif
|
29
30
|
#include <stdio.h>
|
31
|
+
#ifndef _MSC_VER
|
30
32
|
#include <stdint.h>
|
31
33
|
#include <stdbool.h>
|
34
|
+
#else
|
35
|
+
typedef int bool;
|
36
|
+
#define true 1
|
37
|
+
#define false 0
|
38
|
+
#endif
|
32
39
|
#include <ruby.h>
|
40
|
+
#if defined(_MSC_VER) && !defined(INT8_MIN)
|
41
|
+
# include "win32/stdint.h"
|
42
|
+
#endif
|
33
43
|
|
34
44
|
#include <ffi.h>
|
35
45
|
#if defined(HAVE_NATIVETHREAD) && !defined(_WIN32)
|
data/ext/ffi_c/Function.h
CHANGED
data/ext/ffi_c/FunctionInfo.c
CHANGED
@@ -17,11 +17,19 @@
|
|
17
17
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
18
18
|
*/
|
19
19
|
|
20
|
+
#ifndef _MSC_VER
|
20
21
|
#include <sys/param.h>
|
22
|
+
#endif
|
21
23
|
#include <sys/types.h>
|
22
24
|
#include <stdio.h>
|
25
|
+
#ifndef _MSC_VER
|
23
26
|
#include <stdint.h>
|
24
27
|
#include <stdbool.h>
|
28
|
+
#else
|
29
|
+
typedef int bool;
|
30
|
+
#define true 1
|
31
|
+
#define false 0
|
32
|
+
#endif
|
25
33
|
#include <errno.h>
|
26
34
|
#include <ruby.h>
|
27
35
|
|
data/ext/ffi_c/LastError.c
CHANGED
@@ -18,11 +18,19 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <sys/param.h>
|
23
|
+
#endif
|
22
24
|
#include <sys/types.h>
|
23
25
|
#include <stdio.h>
|
26
|
+
#ifndef _MSC_VER
|
24
27
|
#include <stdint.h>
|
25
28
|
#include <stdbool.h>
|
29
|
+
#else
|
30
|
+
typedef int bool;
|
31
|
+
#define true 1
|
32
|
+
#define false 0
|
33
|
+
#endif
|
26
34
|
#include <errno.h>
|
27
35
|
#include <ruby.h>
|
28
36
|
|
data/ext/ffi_c/MemoryPointer.c
CHANGED
@@ -19,8 +19,16 @@
|
|
19
19
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
20
20
|
*/
|
21
21
|
|
22
|
+
#ifndef _MSC_VER
|
22
23
|
#include <stdbool.h>
|
24
|
+
#else
|
25
|
+
typedef int bool;
|
26
|
+
#define true 1
|
27
|
+
#define false 0
|
28
|
+
#endif
|
29
|
+
#ifndef _MSC_VER
|
23
30
|
#include <stdint.h>
|
31
|
+
#endif
|
24
32
|
#include <limits.h>
|
25
33
|
#include <ruby.h>
|
26
34
|
#include "rbffi.h"
|
data/ext/ffi_c/MemoryPointer.h
CHANGED
data/ext/ffi_c/MethodHandle.c
CHANGED
@@ -17,14 +17,22 @@
|
|
17
17
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
18
18
|
*/
|
19
19
|
|
20
|
+
#ifndef _MSC_VER
|
20
21
|
#include <sys/param.h>
|
22
|
+
#endif
|
21
23
|
#include <sys/types.h>
|
22
24
|
#ifndef _WIN32
|
23
25
|
# include <sys/mman.h>
|
24
26
|
#endif
|
25
27
|
#include <stdio.h>
|
28
|
+
#ifndef _MSC_VER
|
26
29
|
#include <stdint.h>
|
27
30
|
#include <stdbool.h>
|
31
|
+
#else
|
32
|
+
typedef int bool;
|
33
|
+
#define true 1
|
34
|
+
#define false 0
|
35
|
+
#endif
|
28
36
|
#ifndef _WIN32
|
29
37
|
# include <unistd.h>
|
30
38
|
#endif
|
data/ext/ffi_c/Platform.c
CHANGED
@@ -18,10 +18,18 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <sys/param.h>
|
23
|
+
#endif
|
22
24
|
#include <sys/types.h>
|
25
|
+
#ifndef _MSC_VER
|
23
26
|
#include <stdint.h>
|
24
27
|
#include <stdbool.h>
|
28
|
+
#else
|
29
|
+
typedef int bool;
|
30
|
+
#define true 1
|
31
|
+
#define false 0
|
32
|
+
#endif
|
25
33
|
#include <ruby.h>
|
26
34
|
#include <ctype.h>
|
27
35
|
#include "endian.h"
|
data/ext/ffi_c/Pointer.c
CHANGED
@@ -18,8 +18,16 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <stdbool.h>
|
23
|
+
#else
|
24
|
+
typedef int bool;
|
25
|
+
#define true 1
|
26
|
+
#define false 0
|
27
|
+
#endif
|
28
|
+
#ifndef _MSC_VER
|
22
29
|
#include <stdint.h>
|
30
|
+
#endif
|
23
31
|
#include <limits.h>
|
24
32
|
#include <ruby.h>
|
25
33
|
#include "rbffi.h"
|
data/ext/ffi_c/Pointer.h
CHANGED
data/ext/ffi_c/Struct.c
CHANGED
@@ -22,9 +22,15 @@
|
|
22
22
|
#include <sys/types.h>
|
23
23
|
|
24
24
|
#include "Function.h"
|
25
|
+
#ifndef _MSC_VER
|
25
26
|
#include <sys/param.h>
|
26
27
|
#include <stdint.h>
|
27
28
|
#include <stdbool.h>
|
29
|
+
#else
|
30
|
+
typedef int bool;
|
31
|
+
#define true 1
|
32
|
+
#define false 0
|
33
|
+
#endif
|
28
34
|
#include <ruby.h>
|
29
35
|
#include "rbffi.h"
|
30
36
|
#include "compat.h"
|
@@ -25,11 +25,19 @@
|
|
25
25
|
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
26
26
|
*/
|
27
27
|
|
28
|
+
#ifndef _MSC_VER
|
28
29
|
#include <sys/param.h>
|
30
|
+
#endif
|
29
31
|
#include <sys/types.h>
|
30
32
|
#include <stdio.h>
|
33
|
+
#ifndef _MSC_VER
|
31
34
|
#include <stdint.h>
|
32
35
|
#include <stdbool.h>
|
36
|
+
#else
|
37
|
+
typedef int bool;
|
38
|
+
#define true 1
|
39
|
+
#define false 0
|
40
|
+
#endif
|
33
41
|
#include <errno.h>
|
34
42
|
#include <ruby.h>
|
35
43
|
|
data/ext/ffi_c/StructByValue.c
CHANGED
@@ -18,11 +18,19 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <sys/param.h>
|
23
|
+
#endif
|
22
24
|
#include <sys/types.h>
|
23
25
|
#include <stdio.h>
|
26
|
+
#ifndef _MSC_VER
|
24
27
|
#include <stdint.h>
|
25
28
|
#include <stdbool.h>
|
29
|
+
#else
|
30
|
+
typedef int bool;
|
31
|
+
#define true 1
|
32
|
+
#define false 0
|
33
|
+
#endif
|
26
34
|
#include <errno.h>
|
27
35
|
#include <ruby.h>
|
28
36
|
|
data/ext/ffi_c/StructLayout.c
CHANGED
@@ -22,9 +22,15 @@
|
|
22
22
|
#include <sys/types.h>
|
23
23
|
|
24
24
|
#include "Function.h"
|
25
|
+
#ifndef _MSC_VER
|
25
26
|
#include <sys/param.h>
|
26
27
|
#include <stdint.h>
|
27
28
|
#include <stdbool.h>
|
29
|
+
#else
|
30
|
+
typedef int bool;
|
31
|
+
#define true 1
|
32
|
+
#define false 0
|
33
|
+
#endif
|
28
34
|
#include <ruby.h>
|
29
35
|
#include "rbffi.h"
|
30
36
|
#include "compat.h"
|
data/ext/ffi_c/Thread.c
CHANGED
@@ -18,13 +18,20 @@
|
|
18
18
|
* version 3 along with this work. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
*/
|
20
20
|
|
21
|
+
#ifndef _MSC_VER
|
21
22
|
#include <stdbool.h>
|
23
|
+
#else
|
24
|
+
typedef int bool;
|
25
|
+
#define true 1
|
26
|
+
#define false 0
|
27
|
+
#endif
|
22
28
|
|
23
29
|
#ifndef _WIN32
|
24
30
|
# include <pthread.h>
|
25
31
|
# include <errno.h>
|
26
32
|
# include <signal.h>
|
27
33
|
#else
|
34
|
+
# include <winsock2.h>
|
28
35
|
# define _WINSOCKAPI_
|
29
36
|
# include <windows.h>
|
30
37
|
#endif
|
data/ext/ffi_c/Thread.h
CHANGED