Skip to content

Commit

Permalink
Merge pull request JustinTulloss#44 from miksago/master
Browse files Browse the repository at this point in the history
Fixed issue with missing pkg-config or libzmq still allowing build.
  • Loading branch information
JustinTulloss committed Aug 4, 2011
2 parents 43f8856 + 82cc4f5 commit 3fddfdd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
10 changes: 2 additions & 8 deletions wscript
Expand Up @@ -11,18 +11,12 @@ def set_options(opt):
def configure(conf):
conf.check_tool("compiler_cxx")
conf.check_tool("node_addon")
conf.check_cfg(package='libzmq', uselib_store='ZMQ', atleast_version='2.1.0', args='--cflags --libs')
conf.check_cfg(atleast_pkgconfig_version='0.0.0', mandatory=True, errmsg='pkg-config was not found')
conf.check_cfg(package='libzmq', atleast_version='2.1.0', uselib_store='ZMQ', args='--cflags --libs', mandatory=True, errmsg='Package libzmq was not found')

def build(bld):
obj = bld.new_task_gen("cxx", "shlib", "node_addon")
obj.cxxflags = ["-Wall", "-Werror"]
obj.target = "binding"
obj.source = "binding.cc"
obj.uselib = "ZMQ"

def shutdown():
# HACK to get binding.node out of build directory.
# better way to do this?
if exists('./binding.node'): unlink('./binding.node')
if Options.commands['build']:
link('./build/default/binding.node', './binding.node')
2 changes: 1 addition & 1 deletion zmq.js
Expand Up @@ -3,7 +3,7 @@
var util = require('util');
var EventEmitter = require('events').EventEmitter;
var IOWatcher = process.binding('io_watcher').IOWatcher;
var zmq = require('./binding');
var zmq = require('./build/default/binding');
var sys = require('sys');

// A map of convenient names to the ZMQ constants for socket types.
Expand Down

0 comments on commit 3fddfdd

Please sign in to comment.