c++ - 将 HeaderDoc 与 .hpp 文件而不是 .h 文件一起使用

标签 c++ header-files headerdoc

我想记录我的界面。该界面是用 C++ 编写的,位于 .hpp 文件中。但是,headerdoc2html 似乎不知道 .hpp 文件;它需要 .h 文件。

$ headerdoc2html include/*.hpp
HTML output mode.
File include/serializer.hpp is not of a known header or source code file type
No valid input files specified. 

Usage: headerdoc2html [-dq] [-o <output directory>] <input file(s) or directory>.

如何强制 HeaderDoc 将输入解释为 C++ 代码?

最佳答案

我只有一个肮脏的建议:将 .hpp 文件复制到 .h 文件。您可以在 makefile 中执行此操作。

这是 Makefile 的一个片段

.SUFFIXES: .h .hpp
.hpp.h:
     cp $< $@

记住 Makefile 中的选项卡,在“cp”行之前

关于c++ - 将 HeaderDoc 与 .hpp 文件而不是 .h 文件一起使用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9240028/

相关文章:

ios - 在 Xcode 8 中记录代码

c++ - 使用标准 C++ 库调试符号? Ubuntu/Linux/libstdc++6-8-dbg?

c++ - 如何摆脱重复编写 namespace_name::inside 类头

c++ - 错误: variable or field 'functionName' declared void

c++ - 是否可以仅在 .cpp 中声明/定义静态方法?

ios - Doxygen/headerdoc 是否支持 swift 4.0?

c++ - gdb,hp ux : getting message Couldn't find virtual table -- object may not be constructed yet

c++ - 这个 C++ 片段有问题

c++ - 如何以线程安全的方式初始化 C++ 全局互斥量