diff --git a/couchjs/c_src/SConscript b/couchjs/c_src/SConscript index a5f8b66b..da3752bc 100644 --- a/couchjs/c_src/SConscript +++ b/couchjs/c_src/SConscript @@ -86,6 +86,13 @@ if not env.GetOption('clean'): conf.Define(vsn) break + ## Find the proper type for JS script objects + + if conf.CheckType("JSScript*", '#include "%s"' % jsapi): + conf.Define("JSSCRIPT_TYPE", "JSScript*") + else: + conf.Define("JSSCRIPT_TYPE", "JSObject*") + ## Define properties for -h / -V (_, vsn) = runcmd("git describe --match 1.*")