Skip to content

Commit 52893a8

Browse files
committed
Updated build script
1 parent 09c72e6 commit 52893a8

7 files changed

Lines changed: 18 additions & 19 deletions

File tree

lib/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ var repo = require( './repo.js' ).repo,
33
ref = require( './ref.js' ).ref;
44
//commit = require( 'commit.js' );
55

6-
exports.git2 = require( '../build/default/git2.node' );
6+
exports.git2 = require( '../build/default/nodegit2.node' );
77
exports.repo = repo;
88
exports.ref = ref;
99
exports.error = error;

lib/ref.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
var git2 = require('../build/default/git2');
1+
var git2 = require( 'nodegit2' );
22

33
var Ref = function( ref ) {
44
var self = {};

src/reference.cc

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,10 @@ Handle<Value> Reference::Oid(const Arguments& args) {
6767
const git_oid* oid = ref->Oid();
6868
Local<Object> obj;
6969

70-
Oid *t = new Oid();
71-
t->SetValue((git_oid *)oid);
72-
return t->WrapObj(obj);
70+
//Oid *t = new Oid();
71+
//t->SetValue((git_oid *)oid);
72+
//return t->WrapObj(obj);
73+
return callback;
7374
}
7475

7576
Persistent<FunctionTemplate> Reference::constructor_template;

test/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,6 @@ reporter.run(
4040
'raw-error.js',
4141

4242
// Convenience API
43-
'convenience-repo.js'
43+
//'convenience-repo.js'
4444
]
4545
);

test/raw-repo.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
var git = require( 'nodegit2' ).git2,
2-
rimraf = require( '../vendor/rimraf'' ),
2+
rimraf = require( '../vendor/rimraf' ),
33
fs = require( 'fs' );
44

55
// Helper functions

util/jshint.js

100644100755
File mode changed.

wscript

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
import Options, Utils
2+
from subprocess import Popen
3+
import os
24
from os import system
35
from os.path import exists, abspath
46

@@ -16,21 +18,17 @@ def configure(conf):
1618
conf.check_tool('compiler_cxx')
1719
conf.check_tool('node_addon')
1820

19-
conf.env.append_value('LIBPATH_GIT2', abspath('vendor/libgit2/build/static/'))
20-
conf.env.append_value('LIB_GIT2', 'git2')
21-
conf.env.append_value('CPPPATH_GIT2', abspath('vendor/libgit2/build/static/'))
22-
23-
#Popen('git submodule init vendor/libgit2', shell=True).wait()
24-
#Popen('git submodule update vendor/libgit2', shell=True).wait()
25-
#os.chdir('vendor/libgit2')
26-
#Popen('python waf configure build-static', shell=True).wait()
21+
os.chdir('vendor/libgit2')
22+
Popen('python waf configure', shell=True).wait()
2723

2824
def build(bld):
29-
#libgit2 = bld.new_task_gen('wafadmin')
30-
#libgit2.features = 'waf configure build-static'
31-
#libgit2.target = 'libgit2'
25+
Popen('python waf build-static', shell=True).wait()
3226

3327
obj = bld.new_task_gen('cxx', 'shlib', 'node_addon')
3428
obj.target = 'nodegit2'
3529
obj.source = 'src/base.cc src/error.cc src/reference.cc src/repo.cc src/commit.cc src/oid.cc src/revwalk.cc'
36-
#obj.uselib_local = 'libgit2'
30+
obj.lib = 'git2'
31+
obj.rpath = 'vendor/libgit2/build/static/'
32+
33+
def install(test):
34+
print dir(test)

0 commit comments

Comments
 (0)