linuxdoxygen
㈠ 如何用doxygen生成文档
在代码中加入文档 这个是第一步,也是最重要的一步,直接影响着文档的优与劣.
Doxygen是一个比较成熟的工具了,它有非常详细且专业的文档.
文档是写在代码当中的,以注释块的形式,为了区分代码中的正常注释,访文档需要用特殊的形式的注释块来呈现.Doxygen支持多种文档注释块:
javadoc形式的:/** * ... */QT形式的/*! * ... */或者,这样/// /// ... ///或者,这样//! //! .. //!后二种有点非主流,不建议使用.推荐使用前面二种.当然,配置了某些特殊的选项也可以使用其他格式.
当Doxygen看到这种形式的注释块时就会把它从代码中抽取出来,生成HTML形式的文档.
为了让文档更且有可读性,表达出更多的信息,Doxygen就定义了很多的命令,常用的有:
\file 告诉Doxygen这是某个文件的文档块\enum 给一个enum类型加文档\struct 给一个结构体加文档\param 函数的参数\return 函数的返回值\see 交叉参考\brief 简介,用于概览时控制在一行以内,可以空一行,然后写更多的详细的内容\code \endcode 示例代码\note 注意事项\par HTML中的
需要注意的是,这些命令也可以用javadoc格式的来写如@file, @enum, @return等.但建议用标准格式,因为\只需要敲一下,而@需要敲二下,另外就是并不是所有的命令都支持javadoc格式.
还有就是如果想写交叉引用可以在前面加个#就会自动转为相应的链接,直接上个例子就都明白了:/** * \brief Obtain current list of path * * \param [out] paths a pointer to an array of strings * \param [out] count indicating the count of path. * * \note * This function will allocate memory for path array. So caller must free the array, but should not free each item. * * \return #API_RESULT_CODE indicating whether this call success or failed. * * \par Sample code: * \code * char **path = NULL; * int count = 0; * test_get_paths(&path, &count); * // use the path * free(path); * path = NULL; * \endcode */ int test_get_paths(char ***paths, int *count);配置Doxygen Doxygen需要一个配置文件来告诉Doxygen一些选项.配置文件就是一个纯文本文件,格式跟标准的linux配置文件一样:一行一个配置项,前面是配置项的名字,然后是等号后面就是配置项的值了.以#开头都是注释.Doxygen的选项特别的多,不可以手动的去写,通常都是编辑一个现有的模板,这个模板可以用Doxygen来生成:
doxygen -g config-filename
PROJECT_NAME 项目的名字,一定要改成你项目的名字PROJECT_NUMBER 编号,通常使用项目的版本号OUTPUT_DIRECTORY 文档输出存放目录,建议修改,比如docPROJECT_BRIEF 项目的描述,会出现文档每一页的上面,控制在一行80字符内(越短越好)EXTRACT_*** 打头的选项要仔细读,如果是API文档,则这些全都要设成NO,这样就仅抽取特定文档块内的内容. 其他的选项都可以不改,用默认的就成.
生成文档 这步最简单,如果前面都就绪了,仅需要运行命令即可:
doxygen config-filename
后,文档就会出现在所指定的输出目录中.
doxygen会打印出日志信息.为了保证质量,最好把把的Warning都修正掉.(这跟修正代码的所有编译警告一个道理).上面例子生成的文档:int test_get_paths(char *** paths, int * count ) Obtain current list of path. Parameters:[out]pathsa pointer to an array of strings[out]countindicating the count of path.Note:This function will allocate memory for path array. So caller must free the array, but should not free each item.Returns:API_RESULT_CODE indicating whether this call success or failed.Sample code:char **path = NULL; int count = 0; test_get_paths(&path, &count); // use the path free(path); path = NULL; 完整示例下载
㈡ 如何利用doxygen生成pdf文档
在代码中加入文档 这个是第一步,也是最重要的一步,直接影响着文档的优与劣.
Doxygen是一个比较成熟的工具了,它有非常详细且专业的文档.
文档是写在代码当中的,以注释块的形式,为了区分代码中的正常注释,访文档需要用特殊的形式的注释块来呈现.Doxygen支持多种文档注释块:
Javadoc形式的:/** * ... */QT形式的/*! * ... */或者,这样/// /// ... ///或者,这样//! //! .. //!后二种有点非主流,不建议使用.推荐使用前面二种.当然,配置了某些特殊的选项也可以使用其他格式.
当Doxygen看到这种形式的注释块时就会把它从代码中抽取出来,生成HTML形式的文档.
为了让文档更且有可读性,表达出更多的信息,Doxygen就定义了很多的命令,常用的有:
\file 告诉Doxygen这是某个文件的文档块\enum 给一个enum类型加文档\struct 给一个结构体加文档\param 函数的参数\return 函数的返回值\see 交叉参考\brief 简介,用于概览时控制在一行以内,可以空一行,然后写更多的详细的内容\code \endcode 示例代码\note 注意事项\par HTML中的<p> 需要注意的是,这些命令也可以用javadoc格式的来写如@file, @enum, @return等.但建议用标准格式,因为\只需要敲一下,而@需要敲二下,另外就是并不是所有的命令都支持javadoc格式.
还有就是如果想写交叉引用可以在前面加个#就会自动转为相应的链接,直接上个例子就都明白了:/** * \brief Obtain current list of path * * \param [out] paths a pointer to an array of strings * \param [out] count indicating the count of path. * * \note * This function will allocate memory for path array. So caller must free the array, but should not free each item. * * \return #API_RESULT_CODE indicating whether this call success or failed. * * \par Sample code: * \code * char **path = NULL; * int count = 0; * test_get_paths(&path, &count); * // use the path * free(path); * path = NULL; * \endcode */ int test_get_paths(char ***paths, int *count);配置Doxygen Doxygen需要一个配置文件来告诉Doxygen一些选项.配置文件就是一个纯文本文件,格式跟标准的Linux配置文件一样:一行一个配置项,前面是配置项的名字,然后是等号后面就是配置项的值了.以#开头都是注释.Doxygen的选项特别的多,不可以手动的去写,通常都是编辑一个现有的模板,这个模板可以用Doxygen来生成:
doxygen -g config-filename
PROJECT_NAME 项目的名字,一定要改成你项目的名字PROJECT_NUMBER 编号,通常使用项目的版本号OUTPUT_DIRECTORY 文档输出存放目录,建议修改,比如docPROJECT_BRIEF 项目的描述,会出现文档每一页的上面,控制在一行80字符内(越短越好)EXTRACT_*** 打头的选项要仔细读,如果是API文档,则这些全都要设成NO,这样就仅抽取特定文档块内的内容. 其他的选项都可以不改,用默认的就成.
生成文档 这步最简单,如果前面都就绪了,仅需要运行命令即可:
doxygen config-filename
后,文档就会出现在所指定的输出目录中.
doxygen会打印出日志信息.为了保证质量,最好把把的Warning都修正掉.(这跟修正代码的所有编译警告一个道理).上面例子生成的文档:int test_get_paths(char *** paths, int * count ) Obtain current list of path. Parameters:[out]pathsa pointer to an array of strings[out]countindicating the count of path.Note:This function will allocate memory for path array. So caller must free the array, but should not free each item.Returns:API_RESULT_CODE indicating whether this call success or failed.Sample code:char **path = NULL; int count = 0; test_get_paths(&path, &count); // use the path free(path); path = NULL; 完整示例下载
㈢ Linux下源代码编译 没有那个文件或目录
文件在./src/modelRection/,但是makefile里面写的是-I.src/modelRction/,??
㈣ 开发B/S网页(进销存)系统,那款开发工具最方便简单实用
Linux开发工具就C++开发工具而言,与Windows下微软(VC, VS2005等)一统天下相比,Linux/Unix下C++开发,可谓五花八门,各式各样。Emacs, vi, eclipse, anjuta,kdevelop等层出不穷。
Windows下
开发工具多以集成开发环境IDE的形式展现给最终用户。例如,VS2005集成了编辑器,宏汇编ml,C /C++编译器cl,资源编译器rc,调试器,文档生成工具, nmake。它们以集成方式提供给最终用户,对于初学者而言十分方便。但是,这种商业模式,直接导致用户可定制性差,不利于自动化,集成第三方工具的能力弱。例如,无法定制一些宏来处理一些重复操作;体会不到自动化makefile一步到位快感;无法远程登录到服务器上进行开发;无法使用某种”粘合剂”来把第三方工具(例如,文本工具,字符串工具)有效地调用起来。可以说,良好的商业支持和傻瓜式开发,是它们主要的优点。
在linux下
Linux开发工具被切割成一个个独立的小工具。各自处理不同的问题。例如,编辑器(emacs, vim)用来进行编辑程序的,调试器(gdb)用来调试程序,编译器(GCC)用来编译和链接程序的,性能分析工具(gcov, gprof)用来优化程序的,文档生成器(doxygen)用来生成文档的。同时,还有一些系统工具和系统知识,我们是很有必要了解的:程序自动化机制 makefile,系统粘合剂shell,系统查找工具grep, locate, find。其它的工具(例如ctags, OCI公司的MPC等等),一旦熟练掌握,它们将成为你手中的利器。
本文主要是一些针对Linux开发工具使用的经验之谈。由于,工具品种繁多,我们没有能力也没有必要一一介绍。对于Linux下IDE工具,例如 eclipse, anjuta等,它们虽然也很实用,但是使用起来比较简单,而且目前还算不上主流。所以,它们将不被着重介绍。同时,本文也不打算写成各个工具的操作手册,只着眼于介绍各个工具的想要解决的问题、运行机理和主要特性。
㈤ 红旗liunx的工具光盘是什么
具体内容
版本RedFlag DC Server 5
Name Version Summary
ant 1.6.2 Ant build tool for java
ant-antlr 1.6.2 Optional antlr tasks for ant
ant-apache-bcel 1.6.2 Optional apache bcel tasks for ant
ant-apache-log4j 1.6.2 Optional apache log4j tasks for ant
ant-apache-oro 1.6.2 Optional apache oro tasks for ant
ant-apache-regexp 1.6.2 Optional apache regexp tasks for ant
ant-apache-resolver 1.6.2 Optional apache resolver tasks for ant
ant-commons-logging 1.6.2 Optional commons logging tasks for ant
ant-javadoc 1.6.2 Javadoc for ant
ant-jdepend 1.6.2 Optional jdepend tasks for ant
ant-jmf 1.6.2 Optional jmf tasks for ant
ant-junit 1.6.2 Optional junit tasks for ant
ant-antlr 1.6.2 Optional antlr tasks for ant
antlr 2.7.4 ANother Tool for Language Recognition
ant-manual 1.6.2 Manual for ant
ant-nodeps 1.6.2 Optional tasks for ant
ant-scripts 1.6.2 Additional scripts for ant
ant-swing 1.6.2 Optional swing tasks for ant
ant-trax 1.6.2 Optional trax tasks for ant
apel 10.6 A Portable Emacs Library.
apel-xemacs 10.6 A Portable [X]Emacs Library
ArgoUML 0.18.1 Unified Modelling Language (UML) diagram editor
at-spi 1.6.2 Assistive Technology Service Provider Interface
at-spi-devel 1.6.2 Development libraries and headers for at-spi
ant-apache-bcel 1.6.2 Optional apache bcel tasks for ant
bcel 5.1 Byte Code Engineering Library
bin86 0.16.17 Real mode 80x86 assembler and linker
blas 3.0 The BLAS (Basic Linear Algebra Subprograms) library.
bluefish 1.0.2 GTK2 web development application for experienced users
bonobo 1.0.22 Library for compound documents in GNOME.
bonobo-devel 1.0.22 Libraries and include files for the Bonobo document model.
bug-buddy 2.8.0 A bug reporting utility for GNOME.
cdda2wav 2.01.1 A utility for sampling/ing .wav files from digital audio CDs.
cdecl 2.5 Encoding/decoding utilities for C/C++ function declarations.
cproto 4.7c Generates function prototypes and variable declarations from C code.
cscope 15.5 C source code tree search and browse tool
ctags 5.5.4 A C programming language indexing and/or cross-reference tool.
dejagnu 1.4.4 A front end for testing other programs.
desktop-file-utils 0.10 Utilities for manipulating .desktop files
dev86 0.16.17 A real mode 80x86 assembler and linker.
device-mapper-multipath 0.4.4 Tools to manage multipath devices using device-mapper.
diffstat 1.38 A utility which provides statistics based on the output of diff.
distcache-devel 1.4.5 Development tools for distcache distributed session cache
doxygen 1.4.1 A documentation system for C/C++.
doxygen-doxywizard 1.4.1 A GUI for creating and editing configuration files.
eclipse-cdt 2.0.2_fc C/C++ Development Tools (CDT) plugin for Eclipse
eclipse-ecj 3.1.0_fc Eclipse Compiler for Java
eclipse-jdt 3.1.0_fc Eclipse Java development tools
eclipse-jdt-devel 3.1.0_fc Eclipse JDT Source
eclipse-pde 3.1.0_fc Eclipse PDE
eclipse-pde-devel 3.1.0_fc Eclipse PDE Source
eclipse-platform 3.1.0_fc Eclipse platform common files
eclipse-platform-devel 3.1.0_fc Eclipse platform Source
eclipse-pydev 0.9.0_fc Eclipse Python development plug-in
eel2-devel 2.8.1 Libraries and include files for developing with Eel.
ElectricFence 2.2.2 A debugger which detects memory allocation violations.
elp 1 Eclipse Language Package
yelp 2.6.4 A system documentation reader from the Gnome project.
gambas-help 1.0.9 Help files for gambas
apel-xemacs 10.6 A Portable [X]Emacs Library
emacs 21.3 The GNU Emacs text editor.
xemacs 21.4.17 A different version of Emacs.
emacs-redflag-extensions-emacs 0.5 redflag extension for GNU Emacs
emacs-el 21.3 The sources for elisp programs included with Emacs.
xemacs-el 21.4.17 The .el source files for XEmacs.
emacs-leim 21.3 Emacs Lisp code for input methods for international characters.
emacs-nox 21.3 GNU Emacs text editor without X support
xemacs-nox 21.4.17 The .el source files for XEmacs.
emacs-redflag-extensions-emacs 0.5 redflag extension for GNU Emacs
eog 2.9.0 Eye of GNOME image viewer
evolution-data-server 1.0.2 Backend data server for evolution
evolution-data-server-devel 1.0.2 Development files for building against evolution-data-server
fam 2.6.10 FAM, the File Alteration Monitor.
fam-devel 2.6.10 FAM, the File Alteration Monitor development files.
fpc 2.0.0 Free Pascal Compiler
freeglut 2.2.0 A freely licensed alternative to the GLUT library
freeglut-devel 2.2.0 freeglut developmental libraries and header files
FreeWnn 1.10pl020 A Japanese character set conversion system.
FreeWnn-devel 1.10pl020 Development library and header files for FreeWnn.
FreeWnn-libs 1.10pl020 A runtime library for FreeWnn.
gambas 1.0.9 IDE based on a basic interpreter with object extensions
gambas-devel 1.0.9 Development libraries and headers for gambas
gambas-examples 1.0.9 Examples for gambas
gambas-help 1.0.9 Help files for gambas
gcc4 4.0.0 Preview of GCC version 4.0
gcc4-c++ 4.0.0 C++ support for GCC version 4.0 preview
gcc4-gfortran 4.0.0 Fortran 95 support
gjdoc 0.7.1 GNU Javadoc
glade2 2.6.8 A GTK+ GUI builder.
gnome-desktop 2.8.0 Package containing code shared among gnome-panel, gnome-session, nautilus, etc.
gnome-desktop-devel 2.8.0 Libraries and headers for libgnome-desktop
gnome-icon-theme 2.8.0 Base gnome icons
gnome-panel 2.8.1 GNOME panel
gnome-panel-devel 2.8.1 Headers and libraries for Panel Applet development
gnutls 1.0.20 A TLS implementation.
gnutls-devel 1.0.20 Development files for the gnutls package.
gperf 3.0.1 A perfect hash function generator.
graphviz 2.2.1 Graph Visualization Tools
graphviz-devel 2.2.1 Development package for graphviz
graphviz-doc 2.2.1 PDF and HTML documents for graphviz
graphviz-graphs 2.2.1 Demo graphs for graphviz
graphviz-tcl 2.2.1 Tcl extension tools for graphviz
gtk-doc 1.2 An API documentation generation tool for GTK+ and GNOME.
inews 2.4.2 Sends Usenet articles to a local news server for distribution.
intltool 0.33 Utility for internationalizing various kinds of data files.
jadetex 3.12 TeX macros used by Jade TeX output.
jakarta-commons-beanutils 1.7.0 Jakarta Commons BeanUtils Package
jakarta-commons-collections 3.1 Jakarta Commons Collections Package
jakarta-commons-digester 1.6 Jakarta Commons Digester Package
jakarta-commons-logging 1.0.4 Jakarta Commons Logging Package
jakarta-commons-modeler 1.1 Jakarta Commons Modeler Package
jakarta-regexp 1.2 Java Regular Expression package
java-1.4.2-gcj-compat 1.4.2.0 JPackage runtime scripts for GCJ
java-1.4.2-gcj-compat-devel 1.4.2.0 JPackage development scripts for GCJ
ant-jdepend 1.6.2 Optional jdepend tasks for ant
jdepend 2.6 Java Design Quality Metrics
jikes 1.22 A Java source file to bytecode compiler
jpackage-utils 1.6.3 JPackage utilities
ant-junit 1.6.2 Optional junit tasks for ant
junit 3.8.1 Java regression test package
kdbg 1.2.9 A GUI for gdb, the GNU debugger, and KDE.
kdesdk 3.2.3 The KDE Software Development Kit (SDK)
kdevelop 3.1.1 Integrated Development Environment for C++/C
kscope 1.3.0 KDE frontend to Cscope
lam 7.0.6 The LAM (Local Area Multicomputer) programming environment.
lapack 3.0 The LAPACK libraries for numerical linear algebra.
lesstif 0.93.36 An OSF/Motif(R) clone.
lesstif-devel 0.93.36 Static library and header files for LessTif/Motif development.
libao 0.8.5 Cross Platform Audio Output Library.
libao-devel 0.8.5 Cross Platform Audio Output Library Development.
libexif 0.5.12 Library for extracting extra information from image files
libexif-devel 0.5.12 Files needed for libexif application development
libgcj 4.0.0 The Java runtime library for gcc.
libgda 1.2.0 Library for writing gnome database programs
libgda-devel 1.2.0 Development libraries and header files for libgda.
libgfortran 4.0.0 Fortran 95 runtime
libghttp 1.0.9 GNOME HTTP client library.
libghttp-devel 1.0.9 Files for development using libghttp.
libmudflap 4.0.0 GCC mudflap shared support library
libmudflap-devel 4.0.0 GCC mudflap support
libswt3-gtk2 3.1.0_fc SWT Library for GTK2
libxml 1.8.17 An XML library.
libxml-devel 1.8.17 Files for developing libxml applications.
ant-apache-log4j 1.6.2 Optional apache log4j tasks for ant
log4j 1.2.8 Java logging package
memprof 0.5.1 A tool for memory profiling and leak detection.
mx4j 2.1.0 Open source implementation of JMX Java API
nasm 0.98.38 A portable x86 assembler which uses Intel-like syntax.
nasm-doc 0.98.38 Documentation for NASM.
nasm-rdoff 0.98.38 Tools for the RDOFF binary format, sometimes used with NASM.
nautilus 2.8.1 Nautilus is a network user environment.
nautilus-cd-burner 2.8.3 Easy to use CD burning for Gnome
nautilus-cd-burner-devel 2.8.3 The files needed for nautilus-cd-burner application development.
nedit 5.4 A GUI text editor for systems with X and Motif.
oaf 0.6.10 Object activation framework for GNOME.
oaf-devel 0.6.10 Libraries and include files for OAF
octave 2.1.57 A high-level language for numerical computations.
octave-devel 2.1.57 Development headers and files for Octave
ant-apache-oro 1.6.2 Optional apache oro tasks for ant
oro 2.0.8 Full regular expressions API
passivetex 1.25 Macros to process XSL formatting objects.
pilot-link-devel 0.11.8 PalmPilot development header files.
planner 0.13 A graphical project management tool.
planner-devel 0.13 Libraries and include files for developing with planner
pvm 3.4.5 Libraries for distributed computing.
pvm-gui 3.4.5 A Tcl/Tk GUI frontend for monitoring and managing a PVM cluster.
qt-designer 3.3.3 Interface designer (IDE) for the Qt toolkit
quanta 3.2.2 An HTML editor for KDE.
quanta-devel 3.2.2 Header files and documentation for compiling quanta applications.
ant-apache-regexp 1.6.2 Optional apache regexp tasks for ant
jakarta-regexp 1.2 Java Regular Expression package
regexp 1.3 Simple regular expressions API
rzsz 0.12.20 X-, Y-, and Z-Modem Data Transfer Protocols
scrollkeeper 0.3.14 ScrollKeeper is a cataloging system for documentation on open systems.
specspo 9.0.92 Red Hat package descriptions, summaries, and groups.
switchdesk 4.0.6 A desktop environment switcher.
thunderbird 1.0 Mozilla Thunderbird mail/newsgroup client
valgrind 2.2.0 Tool for finding memory management bugs in programs
w3c-libwww 5.4.0 An HTTP library of common code.
w3c-libwww-apps 5.4.0 Applications built using Libwww Web library.
w3c-libwww-devel 5.4.0 Libraries and header files for programs that use libwww.
Wnn6-SDK 1.0 A client library for Wnn6.
Wnn6-SDK-devel 1.0 Files needed for development of Wnn6 clients.
xalan-j2 2.6.0 Java XSLT processor
Xaw3d 1.5E A version of the MIT Athena widget set for X.
Xaw3d-devel 1.5E Header files and static libraries for development using Xaw3d.
apel-xemacs 10.6 A Portable [X]Emacs Library
xemacs 21.4.17 A different version of Emacs.
xemacs-common 21.4.17 The byte-compiled lisp files and other common files for XEmacs.
xemacs-el 21.4.17 The .el source files for XEmacs.
xemacs-info 21.4.17 Information files for XEmacs.
xemacs-nox 21.4.17 The .el source files for XEmacs.
xemacs-sumo 20040818 XEmacs Lisp sumo packages
xerces-j2 2.6.2 Java XML parser
xml-commons-resolver 1.1 Resolver subproject of xml-commons.
xmltex 20020625 Namespace-aware XML parser written in TeX.
xmlto 0.0.18 A tool for converting XML files to various formats.
yelp 2.6.4 A system documentation reader from the Gnome project.
zhcon 0.2.3 A Fast Console CJK System Using FrameBuffer
㈥ 怎么在linux下查看某个函数在c++下的用法
GNU GCC 提供了一份关于 MAN 格式的 C++ 标准库的文档,可以在其镜像点(http://gcc.gnu.org/mirrors.html)中下载。具体的路径是:libstdc++/doxygen/libstdc++-man-xxxxxx.tar.bz2,可找一个最新日期的下载。展开包之后将 man/man3 中的所有文件拷贝到系统上已经存在的一个 man/man3 目录中即可使用。
可首先 man C++Intro 阅读 Introction to the GNU libstdc++-v3 man pages。
对于 cout,你需要知道它是 std::ostream 类的一个对象,所以应该 man std::ostream。
㈦ 在linux系统下 怎么查看C++的库函数 如man cout
GNU GCC 提供了一份关于 MAN 格式的 C++ 标准库的文档,可以在其镜像点(http://gcc.gnu.org/mirrors.html)中下载。具体的路径是:libstdc++/doxygen/libstdc++-man-xxxxxx.tar.bz2,可找一个最新日期的下载。展开包之后将 man/man3 中的所有文...
㈧ linux系统中常用开发工具有哪些
编辑器(emacs,
vim
vim用的较多)用来进行编辑程序的,调试器(gdb)用来调试程序,编译器(GCC)用来编译和链接程序的,性能分析工具(gcov,
gprof)用来优化程序的,文档生成器(doxygen)用来生成文档的
当然其它的还有很多,这个要根据你的开发来的。
望采纳!
㈨ 在linux下用什么工具写C++代码
在Linux下,C++开发工具被切割成一个个独立的小工具。各自处理不同的问题。例如,编辑器(emacs, vim)用来进行编辑程序的,调试器(gdb)用来调试程序,编译器(GCC)用来编译和链接程序的,性能分析工具(gcov, gprof)用来优化程序的,文档生成器(doxygen)用来生成文档的。
同时,还有一些系统工具和系统知识,我们是很有必要了解的:程序自动化机制 makefile,系统粘合剂shell,系统查找工具grep, locate, find.其它的工具(例如ctags, OCI公司的MPC等等),一旦熟练掌握,它们将成为你手中的利器。