jessevdk / cldoc

clang based documentation generator for C and C++
GNU General Public License v2.0
552 stars 58 forks source link

Failing to run sudo python setup.py generate #101

Closed divkakwani closed 9 years ago

divkakwani commented 9 years ago

I get the following output when I run the command:

running generate
running coffee
running sass
running scripts/inline

fs.js:1739
  fs.writeSync(this.fd, data, 0, data.length);
                                                      ^
TypeError: Cannot read property 'length' of undefined
    at SyncWriteStream.write (fs.js:1739:38)
    at Object.<anonymous> (/home/divyanshu/cldoc/scripts/inline:8:16)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)
    at node.js:902:3
divkakwani commented 9 years ago

In cldoc/scripts/inline, why do you print the return value of inline? It seems that inline returns nothing, which leads to a call to process.stdout.write with an undefined parameter and hence the error. As the doc of inline-source says, you have to pass it a callback function which will receive the html. This html can be outputted to the index.html file.

jessevdk commented 9 years ago

Because the version of inline-source when I wrote this was doing this differently. I've now pinned to versions of coffee and inline-source in the Makefile. I could use npm/package.json but I didn't want to mix that with python setup.py.