From b5ec1820000c433ddc9ca648b1a0d9f8d43a9d49 Mon Sep 17 00:00:00 2001 From: Thomas Jarosch Date: Fri, 6 Oct 2006 15:11:09 +0000 Subject: [PATCH] libftdi: (tomj) finishing touches on API documentation --- doc/Doxyfile.in | 12 ++++++------ doc/Makefile.am | 2 -- libftdi.spec | 3 ++- src/ftdi.c | 15 +++++++++++++++ src/ftdi.h | 6 +++--- 5 files changed, 26 insertions(+), 12 deletions(-) diff --git a/doc/Doxyfile.in b/doc/Doxyfile.in index 28ad155..29d7544 100644 --- a/doc/Doxyfile.in +++ b/doc/Doxyfile.in @@ -106,7 +106,7 @@ INLINE_INHERITED_MEMB = NO # path before files name in the file list and in the header files. If set # to NO the shortest path that makes the file name unique will be used. -FULL_PATH_NAMES = YES +FULL_PATH_NAMES = NO # If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag # can be used to strip a user-defined part of the path. Stripping is @@ -170,7 +170,7 @@ SEPARATE_MEMBER_PAGES = NO # The TAB_SIZE tag can be used to set the number of spaces in a tab. # Doxygen uses this value to replace tabs by spaces in code fragments. -TAB_SIZE = 8 +TAB_SIZE = 4 # This tag can be used to specify a number of aliases that acts # as commands in the documentation. An alias has the form "name=value". @@ -186,7 +186,7 @@ ALIASES = # For instance, some of the names that are used will be different. The list # of all members will be omitted, etc. -OPTIMIZE_OUTPUT_FOR_C = NO +OPTIMIZE_OUTPUT_FOR_C = YES # Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java # sources only. Doxygen will then generate output that is more tailored for Java. @@ -238,7 +238,7 @@ EXTRACT_PRIVATE = NO # If the EXTRACT_STATIC tag is set to YES all static members of a file # will be included in the documentation. -EXTRACT_STATIC = YES +EXTRACT_STATIC = NO # If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) # defined locally in source files will be included in the documentation. @@ -259,14 +259,14 @@ EXTRACT_LOCAL_METHODS = NO # various overviews, but no documentation section is generated. # This option has no effect if EXTRACT_ALL is enabled. -HIDE_UNDOC_MEMBERS = NO +HIDE_UNDOC_MEMBERS = YES # If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all # undocumented classes that are normally visible in the class hierarchy. # If set to NO (the default) these classes will be included in the various # overviews. This option has no effect if EXTRACT_ALL is enabled. -HIDE_UNDOC_CLASSES = NO +HIDE_UNDOC_CLASSES = YES # If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all # friend (class|struct|union) declarations. diff --git a/doc/Makefile.am b/doc/Makefile.am index f4e1cd4..96fd82e 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -1,5 +1,3 @@ -EXTRA_DIST = - # I grabbed this same hack from the VACM docs/Makfile.am CLEANFILES = rm -rf html man diff --git a/libftdi.spec b/libftdi.spec index de69af9..78b96f4 100644 --- a/libftdi.spec +++ b/libftdi.spec @@ -8,7 +8,7 @@ Vendor: Intra2net AG Source: %{name}-%{version}.tar.gz Buildroot: /tmp/%{name}-%{version}-root Requires: libusb -BuildRequires: libusb, libusb-devel, pkgconfig +BuildRequires: libusb, libusb-devel, pkgconfig, doxygen Prefix: /usr %package devel @@ -42,6 +42,7 @@ rm -fr $RPM_BUILD_ROOT %files devel %defattr(-,root,root) +%doc doc/html doc/man %{prefix}/bin/libftdi-config %{prefix}/lib/libftdi.*a %{prefix}/include/*.h diff --git a/src/ftdi.c b/src/ftdi.c index 0b8b269..df7daaf 100644 --- a/src/ftdi.c +++ b/src/ftdi.c @@ -14,6 +14,18 @@ * * ***************************************************************************/ +/** + \mainpage libftdi API documentation + + Library to talk to FTDI chips. See http://www.ftdichip.com + + The latest versions of libftdi is available at + http://www.intra2net.com/de/produkte/opensource/ftdi/ + +*/ +/** \addtogroup libftdi */ +/* @{ */ + #include #include #include @@ -402,6 +414,7 @@ int ftdi_usb_close(struct ftdi_context *ftdi) /* ftdi_convert_baudrate returns nearest supported baud rate to that requested. Function is only used internally + \internal */ static int ftdi_convert_baudrate(int baudrate, struct ftdi_context *ftdi, unsigned short *value, unsigned short *index) @@ -1273,3 +1286,5 @@ int ftdi_setrts(struct ftdi_context *ftdi, int state) return 0; } + +/* @} end of doxygen libftdi group */ diff --git a/src/ftdi.h b/src/ftdi.h index 1040e2e..2d3a5cc 100644 --- a/src/ftdi.h +++ b/src/ftdi.h @@ -112,7 +112,7 @@ enum ftdi_interface { #define SIO_RTS_CTS_HS (0x1 << 8) /** - Main context structure for all libftdi functions. + \brief Main context structure for all libftdi functions. Do not access directly if possible. */ @@ -161,7 +161,7 @@ struct ftdi_context { }; /** - Single linked list of usb devices created by ftdi_usb_find_all() + \brief list of usb devices created by ftdi_usb_find_all() */ struct ftdi_device_list { /// pointer to next entry @@ -171,7 +171,7 @@ struct ftdi_device_list { }; /** - FTDI eeprom structure + \brief FTDI eeprom structure */ struct ftdi_eeprom { /// vendor id -- 1.7.1