0

我正在尝试在 Ubuntu 14.10中构建 jsoncpp 的文档( https://github.com/open-source-parsers/jsoncpp )。正如 github 的 README.md 中所说,我运行 doxybuild.py 脚本,但出现以下错误:

$> cd jsoncpp/
$> python doxybuild.py --doxygen=$(which doxygen) --open --with-dot
Deleting directory: dist/doxygen
Running:  /home/jeremy/Projets/Perso/CmdSeries/libs/jsoncpp/doc/doxyfile
Traceback (most recent call last):
  File "doxybuild.py", line 169, in <module>
    main()
  File "doxybuild.py", line 166, in main
    build_doc( options )
  File "doxybuild.py", line 116, in build_doc
    ok = run_doxygen( options.doxygen_path, 'doc/doxyfile', 'doc', is_silent=options.silent )
  File "doxybuild.py", line 67, in run_doxygen
    process = subprocess.Popen( cmd )
  File "/usr/lib/python2.7/subprocess.py", line 710, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1335, in _execute_child
    raise child_exception
OSError: [Errno 13] Permission denied

$> sudo python doxybuild.py --doxygen=$(which doxygen) --open --with-dot
Deleting directory: dist/doxygen
Running:  /home/jeremy/Projets/Perso/CmdSeries/libs/jsoncpp/doc/doxyfile
Traceback (most recent call last):
  File "doxybuild.py", line 169, in <module>
    main()
  File "doxybuild.py", line 166, in main
    build_doc( options )
  File "doxybuild.py", line 116, in build_doc
    ok = run_doxygen( options.doxygen_path, 'doc/doxyfile', 'doc', is_silent=options.silent )
  File "doxybuild.py", line 67, in run_doxygen
    process = subprocess.Popen( cmd )
  File "/usr/lib/python2.7/subprocess.py", line 710, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1335, in _execute_child
    raise child_exception
OSError: [Errno 13] Permission denied

有人有想法吗?

已经尝试过:

  • chmod u+x doxybuild.py
  • sudo chmod 775 /usr/lib/python2.7/subprocess.py
  • sudo chown $USER /usr/lib/python2.7/subprocess.py

但没有什么能解决我的问题。

4

1 回答 1

3

好的,问题解决了:

$> cd jsoncpp/doc
$> cat readme.txt
The documentation is generated using doxygen (http://www.doxygen.org).
$> sudo apt-get install doxygen
... 
OK
$> python doxybuild.py --doxygen=$(which doxygen) --open --with-dot
...
ok

只需安装 doxygen 并构建文档即可。

于 2014-11-20T12:27:45.790 回答