Skip to content

Commit

Permalink
Layout simplification (move wscript to root level, remove lib folder)…
Browse files Browse the repository at this point in the history
… and fix bug tracker url
  • Loading branch information
wdavidw committed Apr 23, 2011
1 parent 6cab948 commit b6d36fb
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion index.js
@@ -1 +1 @@
module.exports = require('./lib/hash_ring');
module.exports = require("./build/default/hash_ring").HashRing;
1 change: 0 additions & 1 deletion lib/hash_ring.js

This file was deleted.

7 changes: 2 additions & 5 deletions package.json
Expand Up @@ -2,7 +2,7 @@
"name" : "hash_ring"
, "version" : "0.1.0"
, "description" : "Consistent hashing C++ Add-on for node.js"
, "keywords": [ "node", "hash ring", "sharding", "distributed" ]
, "keywords": [ "node", "hash ring", "consistent hashing", "sharding", "distributed" ]
, "author": "Brian Noguchi <brian.noguchi@gmail.com>"
, "contributors": [
{ "name": "Brian Noguchi", "web": "http://ngchi.wordpress.com" }
Expand All @@ -13,9 +13,6 @@
"type": "git"
, "url": "https://github.com/bnoguchi/node-hash-ring"
}
, "bugs": { "web": "http://github.com/bnoguchi/redis-node/issues" }
, "bugs": { "web": "http://github.com/bnoguchi/node-hash-ring/issues" }
, "engines": { "node": ">=0.2.0" }
, "scripts": {
"install": "cd src; node-waf configure build"
}
}
14 changes: 10 additions & 4 deletions src/wscript → wscript
@@ -1,15 +1,21 @@
srcdir = '.'
blddir = '../build'
VERSION = '0.0.1'
from os.path import exists
from shutil import rmtree

def set_options(ctx):
ctx.tool_options('compiler_cxx')

def clean(cln):
if exists('build'): rmtree('build')

def configure(ctx):
ctx.check_tool('compiler_cxx')
ctx.check_tool('node_addon')

def build(ctx):
t = ctx.new_task_gen('cxx', 'shlib', 'node_addon')
t.target = 'hash_ring'
t.source = 'md5.cc hash_ring.cc module.cc'
t.source = [
'src/md5.cc',
'src/hash_ring.cc',
'src/module.cc'
]

0 comments on commit b6d36fb

Please sign in to comment.