Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix for 1.9 and loading the extension

  • Loading branch information...
commit 687795a28c8458ac9c920fda897e2adfe19288a4 1 parent b150e07
Evan Phoenix authored
Showing with 11 additions and 2 deletions.
  1. +4 −0 ext/lost/extconf.rb
  2. +5 −0 ext/lost/lost.c
  3. +2 −2 lib/lost.rb
4 ext/lost/extconf.rb
View
@@ -2,4 +2,8 @@
$LDFLAGS += " -framework cocoa -framework CoreLocation "
+if RUBY_VERSION > "1.8"
+ $defs.push "-DRUBY_19"
+end
+
create_makefile("lost")
5 ext/lost/lost.c
View
@@ -1,5 +1,10 @@
#include "ruby.h"
+
+#ifdef RUBY_19
+#include "ruby/intern.h"
+#else
#include "intern.h"
+#endif
int int_coreloc_enable();
void int_coreloc_get(double* lat, double* log);
4 lib/lost.rb
View
@@ -1,7 +1,7 @@
-require 'lost/lost.so'
+require 'lost.so'
module Lost
- VERSION = "1.0.0"
+ VERSION = "1.0.1"
coreloc_enable
end
Please sign in to comment.
Something went wrong with that request. Please try again.