【问题标题】:How to run Doxygen Makefile?如何运行 Doxygen Makefile?
【发布时间】:2012-07-09 04:00:43
【问题描述】:

我创建了一个 .NET C# 项目,我使用类似于 ///<summary>A summary...</summary> 的块对其进行了评论,我想使用 Doxygen 对其进行记录。我已经设置了 Doxygen,它运行生成了大约 100 个 .tex 文件和一个 Makefile。

据我了解,Makefile 是将文档生成为 PDF 的关键,但我无法使用它。

当我在 Doxygen LaTeX 输出目录中时,我正在使用 Mac 通过在终端中写入 make -f Makefile 来执行 LaTeX 和 Doxygen 位。

all: refman.pdf

pdf: refman.pdf

refman.pdf: clean refman.tex
            pdflatex refman
        makeindex refman.idx
        pdflatex refman
        latex_count=5 ; \
        while egrep -s 'Rerun (LaTeX|to get cross-references right)' refman.log && [ $$latex_count -gt 0 ] ;\
            do \
              echo "Rerunning latex...." ;\
              pdflatex refman ;\
              latex_count=`expr $$latex_count - 1` ;\
            done


    clean:
        rm -f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out *.brf *.blg *.bbl refman.pdf

运行时,我收到以下消息:

MacBook-Pro-13:latex sehlstrom$ make
rm -f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out *.brf *.blg *.bbl refman.pdf
make: *** No rule to make target `refman.tex', needed by `refman.pdf'.  Stop.

我怎样才能让 Makefil 工作?

【问题讨论】:

  • 你先运行 doxygen 了吗? Doxyfile 中是否启用了 LaTeX 输出?是否创建了refman.tex
  • @BenVoigt 是的,我已经运行了 Doxygen,它在目标文件夹中给了我大约 100 个 .tex 文件。如问题所示,Doxygen 还创建了 Makefile。但是没有创建文件refman.tex - 我必须创建该文件吗?如果是这种情况,是否有一种特定的方式应该编写该文档以使 Makefile 兼容?
  • 我认为这应该是由 Doxygen 生成的。 doxygen 命令完成时没有错误吗?
  • @BenVoigt 它没有错误地完成。

标签: c# makefile latex doxygen


【解决方案1】:

refman.tex 应该是由 Doxygen 创建的。我刚刚用我安装的版本 doxygen 1.7.2 进行了测试,它创建了一个refman.tex

确保您没有设置任何选项,表明这是一个不应有自己的索引的大型项目的组件。

【讨论】:

  • 感谢您抽出宝贵时间查看!我重置了所有设置并再次提供了它,现在它生成了 refman.tex 文件。但是,运行make -f Makefile时,输出是4页,没有任何内容=/
  • @sehlstrom:你们有 HTML 格式的内容吗?有一些设置,例如 EXTRACT_PRIVATE_MEMBERSEXTRACT_UNDOCUMENTED 可以导致几乎所有内容消失,但它们应该同样影响 LaTeX 和 HTML。
  • HTML 输出很好,一切都在那里。进行了一些测试,最后我收到一条错误消息,说明出了什么问题。对于要包含在 refman.tex 中的所有 .tex 文件,我在第 5 页上得到类似 LaTeX Warning: Reference class_f_e_1_1solid2d_1_1_f_eplani4' 在输入第 10 行未定义。` refman.tex 中的对应行看起来像这样 \input{class_f_e_1_1solid2d_1_1_f_eplani4}。跨度>
  • 脚本从未结束。只需按几次 Enter 即可跳过所有警告。完成后,我有 43 页的文档。感谢您的所有帮助@ben!
  • @sehlstrom:啊,是的,tex 警告很有趣。无论如何,您可以按q,enter 将其置于静音模式并消除剩余的警告。
猜你喜欢
  • 1970-01-01
  • 2022-10-05
  • 2022-11-20
  • 1970-01-01
  • 2015-06-21
  • 2016-01-21
  • 2018-07-07
  • 2013-06-14
  • 2010-12-17
相关资源
最近更新 更多