mirror of
https://github.com/mkxp-z/mkxp-z.git
synced 2025-08-10 08:55:33 +02:00
Use proper Ruby 1.8 header path
This commit is contained in:
parent
ce4fdf3104
commit
18bd8084ec
4 changed files with 9 additions and 12 deletions
|
@ -31,11 +31,10 @@
|
|||
#include "audio.h"
|
||||
#include "boost-hash.h"
|
||||
|
||||
#ifndef OLD_RUBY
|
||||
#include <ruby.h>
|
||||
|
||||
#ifndef OLD_RUBY
|
||||
#include <ruby/encoding.h>
|
||||
#else
|
||||
#include <ruby/ruby.h>
|
||||
#endif
|
||||
|
||||
#include <assert.h>
|
||||
|
|
|
@ -22,11 +22,7 @@
|
|||
#ifndef BINDING_UTIL_H
|
||||
#define BINDING_UTIL_H
|
||||
|
||||
#ifndef OLD_RUBY
|
||||
#include <ruby.h>
|
||||
#else
|
||||
#include <ruby/ruby.h>
|
||||
#endif
|
||||
|
||||
#include "exception.h"
|
||||
|
||||
|
@ -69,7 +65,7 @@ raiseRbExc(const Exception &exc);
|
|||
#ifndef OLD_RUBY
|
||||
#define DECL_TYPE(Klass) \
|
||||
extern rb_data_type_t Klass##Type
|
||||
#endif
|
||||
|
||||
|
||||
/* 2.1 has added a new field (flags) to rb_data_type_t */
|
||||
#include <ruby/version.h>
|
||||
|
@ -79,6 +75,7 @@ raiseRbExc(const Exception &exc);
|
|||
#else
|
||||
#define DEF_TYPE_FLAGS
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef OLD_RUBY
|
||||
#define DEF_TYPE_CUSTOMNAME_AND_FREE(Klass, Name, Free) \
|
||||
|
@ -130,8 +127,7 @@ raiseRbExc(const Exception &exc);
|
|||
#define DEF_ALLOCFUNC_CUSTOMFREE(type,free) \
|
||||
static VALUE type##Allocate(VALUE klass)\
|
||||
{ \
|
||||
void *sval = 0; \
|
||||
return Data_Wrap_Struct(klass, 0, free, sval); \
|
||||
return Data_Wrap_Struct(klass, 0, free, 0); \
|
||||
}
|
||||
|
||||
#define DEF_ALLOCFUNC(type) DEF_ALLOCFUNC_CUSTOMFREE(type, freeInstance<type>)
|
||||
|
|
|
@ -27,8 +27,10 @@
|
|||
|
||||
#ifndef OLD_RUBY
|
||||
#include "ruby/encoding.h"
|
||||
#endif
|
||||
#include "ruby/intern.h"
|
||||
#else
|
||||
#include "intern.h"
|
||||
#endif
|
||||
|
||||
static void
|
||||
fileIntFreeInstance(void *inst)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// Most of the MiniDL class was taken from Ruby 1.8's Win32API.c,
|
||||
// it's just as basic but should work fine for the moment
|
||||
|
||||
#include <ruby/ruby.h>
|
||||
#include <ruby.h>
|
||||
#include <SDL.h>
|
||||
#if defined(__WIN32__) && defined(USE_ESSENTIALS_FIXES)
|
||||
#include <SDL_syswm.h>
|
||||
|
|
Loading…
Add table
Reference in a new issue