Skip to content

Loading…

Added Node >= v0.9.0 and node-gyp support #28

Merged
merged 3 commits into from

2 participants

@fardjad

No description provided.

@fardjad fardjad referenced this pull request in ajaxorg/node-libxml
Open

Added node-gyp support. #9

@fjakobs fjakobs merged commit 1575184 into ajaxorg:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 3, 2013
  1. @fardjad

    Added node-gyp support.

    fardjad committed
  2. @fardjad

    Changed minimum node version to 0.6

    fardjad committed
    Added node >= 0.9 support
  3. @fardjad
This page is out of date. Refresh to see the latest.
Showing with 53 additions and 1 deletion.
  1. +47 −0 binding.gyp
  2. +2 −0 hosts/node-o3/sh_node.cc
  3. +4 −1 package.json
View
47 binding.gyp
@@ -0,0 +1,47 @@
+{
+ "targets": [
+ {
+ "target_name": "o3",
+ "include_dirs": [
+ "include",
+ "hosts",
+ "modules",
+ "deps"
+ ],
+ "sources": [
+ "hosts/node-o3/sh_node.cc",
+ "hosts/node-o3/sh_node_libs.cc"
+ ],
+ "cflags_cc!": ["-fno-exceptions"],
+ "conditions": [
+ ["OS==\"win\"", {
+ # TODO: Add Windows libraries
+ }, {
+ "libraries": [
+ "<!@(xml2-config --libs)"
+ ]
+ }],
+ ["OS==\"mac\"", {
+ "xcode_settings": {
+ "GCC_ENABLE_CPP_EXCEPTIONS": "YES",
+ "OTHER_CFLAGS": [
+ "<!@(xml2-config --cflags)",
+ "-O3",
+ "-msse2",
+ "-ffast-math",
+ "-fexceptions"
+ ]
+ }
+ }, {
+ "cflags": [
+ "<!@(xml2-config --cflags)",
+ "-O3",
+ "-msse2",
+ "-ffast-math",
+ "-fexceptions"
+ ]
+ }]
+ ]
+ }
+ ]
+}
View
2 hosts/node-o3/sh_node.cc
@@ -19,6 +19,7 @@
#define O3_NODE
//#define O3_V8_GLUE
#include <v8.h>
+#include <node.h>
#include <o3.h>
#include <js/js.h>
//#include <buffer/buffer.h>
@@ -61,3 +62,4 @@ init (Handle<Object> target)
}
+NODE_MODULE(o3, init)
View
5 package.json
@@ -1,5 +1,8 @@
{
"name": "o3-xml",
"version": "0.1.0",
- "private": true
+ "private": true,
+ "engines" : {
+ "node" : ">= 0.6.0"
+ }
}
Something went wrong with that request. Please try again.