--- libiksemel-1.2.orig/doc/iksemel.texi +++ libiksemel-1.2/doc/iksemel.texi @@ -4,6 +4,10 @@ @setcontentsaftertitlepage @settitle Iksemel Programmers Manual @set VERSION 1.2 +@dircategory Libraries +@direntry +* Iksemel Programmers Manual: (iksemel). A tutorial and API reference for the iksemel library +@end direntry @c %**end of header @titlepage --- libiksemel-1.2.orig/doc/iksemel +++ libiksemel-1.2/doc/iksemel @@ -1,4 +1,9 @@ -This is iksemel, produced by makeinfo version 4.6 from iksemel.texi. +This is iksemel, produced by makeinfo version 4.8 from iksemel.texi. + +INFO-DIR-SECTION Libraries +START-INFO-DIR-ENTRY +* Iksemel Programmers Manual: (iksemel). A tutorial and API reference for the iksemel library +END-INFO-DIR-ENTRY  File: iksemel, Node: Top, Up: (dir) @@ -31,8 +36,8 @@  File: iksemel, Node: Introduction, Next: Tutorials, Up: Top -Introduction -************ +1 Introduction +************** iksemel is an XML (eXtensible Markup Language) parser library designed for Jabber applications. It is coded in ANSI C for POSIX compatible @@ -44,10 +49,10 @@ are familiar with the C programming language, basic programming concepts, XML and Jabber protocol. -Compiling the Library -===================== +1.1 Compiling the Library +========================= -You need to install MinGW () under Windows to be able +You need to install MinGW (`http://mingw.org') under Windows to be able to compile iksemel. Although not tested by the author, Cygwin should work equally well. @@ -64,8 +69,8 @@ make install -Using iksemel in Applications -============================= +1.2 Using iksemel in Applications +================================= You need to include `iksemel.h' file in your source to access library API. You can do this with: @@ -91,8 +96,8 @@  File: iksemel, Node: Tutorials, Next: Development, Prev: Introduction, Up: Top -Tutorials -********* +2 Tutorials +*********** * Menu: @@ -109,8 +114,8 @@  File: iksemel, Node: Parsing an XML Document, Next: Working with XML Trees, Up: Tutorials -Parsing an XML Document -======================= +2.1 Parsing an XML Document +=========================== iksemel parser sequentally processes the XML document. Each encountered XML element (i.e. tags, character data, comments, processing @@ -121,13 +126,13 @@ Parser stores its state in a small structure. This structure is referenced by `iksparser' type, and managed with following functions: - - Function: iksparser* iks_sax_new (void* USER_DATA, iksTagHook* + -- Function: iksparser* iks_sax_new (void* USER_DATA, iksTagHook* TAGHOOK, iksCDataHook* CDATAHOOK); This function allocates and initializes a parser structure. If allocation fails, NULL value is returned. USER_DATA is passed directly to hook functions. - - Typedef: iksTagHook + -- Typedef: iksTagHook int iksTagHook (void* USER_DATA, char* NAME, char** ATTS, int TYPE); @@ -147,7 +152,7 @@ `IKS_SINGLE' Standalone tag, i.e. - - Typedef: iksCDataHook + -- Typedef: iksCDataHook int iksCDataHook (void* USER_DATA, char* DATA, size_t LEN); DATA is a pointer to the character data. Encoding is UTF-8 and it @@ -157,13 +162,13 @@ `IKS_OK', it is passed immediately to the caller of the `iks_parse'. - - Function: int iks_parse (iksparser* PRS, char *DATA, size_t LEN, int - FİNİSH); + -- Function: int iks_parse (iksparser* PRS, char *DATA, size_t LEN, + int FINISH); You give XML document to the parser with this function. DATA is a LEN bytes string. If LEN is zero, data must be a null terminated string. - If FİNİSH value is zero, parser waits for more data later. If you + If FINISH value is zero, parser waits for more data later. If you want to finish parsing without giving data, call it like: iks_parse (my_parser, NULL, 0, 1); @@ -180,7 +185,7 @@ `IKS_HOOK' Your hook decided that there is an error. - - Function: void iks_parser_delete (iksparser* PRS); + -- Function: void iks_parser_delete (iksparser* PRS); This function frees parser structure and associated data. Now we have learned how to create and use a sax parser. Lets parse a @@ -188,7 +193,7 @@ #include #include - + int pr_tag (void *udata, char *name, char **atts, int type) { switch (type) { @@ -211,7 +216,7 @@ } return IKS_OK; } - + enum ikserror pr_cdata (void *udata, char *data, size_t len) { int i; @@ -221,7 +226,7 @@ printf ("]\n"); return IKS_OK; } - + int main (int argc, char *argv[]) { iksparser *p; @@ -266,23 +271,23 @@ (i.e. markup or character data) is passed, position is at the end of the erroneous element for `IKS_HOOK' errors. - - Function: unsigned long iks_nr_bytes (iksparser* PRS); + -- Function: unsigned long iks_nr_bytes (iksparser* PRS); Returns how many number of bytes parsed. - - Function: unsigned long iks_nr_lines (iksparser* PRS); + -- Function: unsigned long iks_nr_lines (iksparser* PRS); Returns how many number of lines parsed. If you want to parse another document with your parser again, you should use the following function to reset your parser. - - Function: void iks_parser_reset (iksparser* PRS); + -- Function: void iks_parser_reset (iksparser* PRS); Resets the parser's internal state.  File: iksemel, Node: Working with XML Trees, Next: XML Streams, Prev: Parsing an XML Document, Up: Tutorials -Working with XML Trees -====================== +2.2 Working with XML Trees +========================== SAX interface uses very little memory, but it forces you to access XML documents sequentally. In many cases you want to keep a tree like @@ -310,8 +315,8 @@  File: iksemel, Node: Memory Management, Next: Creating a Tree, Up: Working with XML Trees -Memory Management ------------------ +2.2.1 Memory Management +----------------------- Since keeping whole document content uses a lot of memory and requires many calls to OS's memory allocation layer, iksemel uses a simple object @@ -340,11 +345,11 @@ reached without allocating too many blocks, or wasting memory with too big blocks. - - Typedef: ikstack + -- Typedef: ikstack This is a structure defining the object stack. Its fields are private and subject to change with new iksemel releases. - - Function: ikstack * iks_stack_new (size_t META_CHUNK, size_t + -- Function: ikstack * iks_stack_new (size_t META_CHUNK, size_t DATA_CHUNK); Creates an object stack. META_CHUNK is the initial size of the data block used for structures and aligned data. DATA_CHUNK is the @@ -354,27 +359,27 @@ These two initial chunks and a small object stack structure is allocated in one `malloc' call for optimization purproses. - - Function: void * iks_stack_alloc (ikstack * STACK, size_t SİZE); - Allocates SİZE bytes of space from the object stack's meta chunk. + -- Function: void * iks_stack_alloc (ikstack * STACK, size_t SIZE); + Allocates SIZE bytes of space from the object stack's meta chunk. Allocated space is aligned on platform's default alignment boundary and isn't initialized. Returns a pointer to the space, or NULL if there isn't enough space available and allocating a new block fails. - - Function: void * iks_stack_strdup (ikstack * STACK, const char * + -- Function: void * iks_stack_strdup (ikstack * STACK, const char * SRC, size_t LEN); Copies given string SRC into the object stack's data chunk. Returns a pointer to the new string, or NULL if there isn't enough space in the stack. If LEN is zero string must be null terminated. - - Function: void iks_stack_delete (ikstack * STACK); + -- Function: void iks_stack_delete (ikstack * STACK); Gives all memory associated with object stack to the system. Since character data sections are usually parsed in separate blocks, a growable string implementation is necessary for saving memory. - - Function: char * iks_stack_strcat (ikstack *STACK, char *OLD, size_t - OLD_LEN, const char *SRC, size_t SRC_LEN); + -- Function: char * iks_stack_strcat (ikstack *STACK, char *OLD, + size_t OLD_LEN, const char *SRC, size_t SRC_LEN); This function appends the string SRC to the string OLD in the stack's data chunk. If OLD is NULL it behaves like `iks_stack_strdup'. Otherwise OLD has to be a string created with @@ -391,31 +396,31 @@  File: iksemel, Node: Creating a Tree, Next: Accessing the Tree, Prev: Memory Management, Up: Working with XML Trees -Creating a Tree ---------------- +2.2.2 Creating a Tree +--------------------- - - Typedef: iks + -- Typedef: iks This is a structure defining a XML node. Its fields are private and only accessed by following functions. - - Function: iks* iks_new (const char *NAME); + -- Function: iks* iks_new (const char *NAME); Creates an object stack and creates a IKS_TAG type of node with given tag name inside the stack. Tag name is also copied into the stack. Returns the node pointer, or NULL if there isn't enough memory. - - Function: iks* iks_new_within (const char *NAME, ikstack* STACK); + -- Function: iks* iks_new_within (const char *NAME, ikstack* STACK); Creates a IKS_TAG type of node with the given tag name. Node and tag name is allocated inside the given object stack. Returns the node pointer, or NULL if there isn't enough memory. - - Function: iks* iks_insert (iks *X, const char *NAME); + -- Function: iks* iks_insert (iks *X, const char *NAME); Creates a IKS_TAG type of node with the given tag name. Node and tag name is allocated inside the X node's object stack and linked to X as a child node. Returns the node pointer, or NULL if there isn't enough memory. - - Function: iks* iks_insert_cdata (iks* X, const char* DATA, size_t + -- Function: iks* iks_insert_cdata (iks* X, const char* DATA, size_t LEN); Creates a IKS_CDATA type of node with given character data. Node is allocated inside the X node's object stack and linked to X as a @@ -423,7 +428,7 @@ null terminated string. Returns the node pointer, or NULL if there isn't enough memory. - - Function: iks* iks_insert_attrib (iks* X, const char* NAME, const + -- Function: iks* iks_insert_attrib (iks* X, const char* NAME, const char* VALUE); Creates a IKS_ATTRIBUTE type of node with given attribute name and the value. Node is allocated inside the X node's object stack and @@ -435,15 +440,15 @@ attribute's value. If VALUE is NULL, attribute is removed from the tag. - - Function: iks* iks_insert_node (iks* X, iks* Y); + -- Function: iks* iks_insert_node (iks* X, iks* Y); Links node Y to node X as a child node. Nodes are not copied between object stacks, be careful. - - Function: void iks_hide (iks *X); + -- Function: void iks_hide (iks *X); Changes the links of the other nodes so that X becomes invisible. It stays in the same object stack with neighbour nodes, be careful. - - Function: void iks_delete (iks *X); + -- Function: void iks_delete (iks *X); Frees the object stack of the node X. Now lets create a tree representation of following XML document: @@ -460,7 +465,7 @@ here is the code: iks *x, *y, *z; - + x = iks_new ("message"); iks_insert_attrib (x, "type", "chat"); iks_insert_attrib (x, "from", "bob@bd.com"); @@ -488,42 +493,42 @@ There are also functions for duplicating xml trees. They are: - - Function: iks * iks_copy (iks* X); + -- Function: iks * iks_copy (iks* X); Creates a full copy of the tree in a newly created object stack. - - Function: iks * iks_copy_within (iks* X, ikstack *S); + -- Function: iks * iks_copy_within (iks* X, ikstack *S); Creates a full copy of the tree in given object stack.  File: iksemel, Node: Accessing the Tree, Next: Converting a Tree into an XML Document, Prev: Creating a Tree, Up: Working with XML Trees -Accessing a Tree ----------------- +2.2.3 Accessing a Tree +---------------------- Basic access functions allow you to move on the tree: - - Function: iks* iks_next (iks* X); + -- Function: iks* iks_next (iks* X); - - Function: iks* iks_prev (iks* X); + -- Function: iks* iks_prev (iks* X); - - Function: iks* iks_parent (iks* X); + -- Function: iks* iks_parent (iks* X); - - Function: iks* iks_child (iks* X); + -- Function: iks* iks_child (iks* X); - - Function: iks* iks_attrib (iks* X); + -- Function: iks* iks_attrib (iks* X); These functions return a pointer to the next, previous, parent, first child, and first attribute node of the given node X. If that node doesn't exist or X is NULL, a NULL value is returned. - - Function: iks * iks_root (iks *X); + -- Function: iks * iks_root (iks *X); Returns the topmost parent node of the X. - - Function: iks* iks_next_tag (iks* X); + -- Function: iks* iks_next_tag (iks* X); - - Function: iks* iks_prev_tag (iks* X); + -- Function: iks* iks_prev_tag (iks* X); - - Function: iks* iks_first_tag (iks* X); + -- Function: iks* iks_first_tag (iks* X); These functions return a pointer to the next, previous, first child node of the given node X. Only tag nodes are considered, other type of @@ -533,10 +538,10 @@ Another group of functions allow you to access specific information and content of the nodes: - - Function: ikstack* iks_stack (iks* X); + -- Function: ikstack* iks_stack (iks* X); Returns the object stack which node X stays. - - Function: enum ikstype iks_type (iks* X); + -- Function: enum ikstype iks_type (iks* X); Returns the type of the node. `IKS_TAG' @@ -548,39 +553,39 @@ `IKS_ATTRIBUTE' Node contains an attribute and its value. - - Function: char* iks_name (iks* X); + -- Function: char* iks_name (iks* X); Returns the name of the tag for nodes with the type IKS_TAG. - - Function: char* iks_cdata (iks* X); + -- Function: char* iks_cdata (iks* X); Returns a pointer to node's character data if available, NULL otherwise. - - Function: size_t iks_cdata_size (iks* X); + -- Function: size_t iks_cdata_size (iks* X); Returns the size of the node's character data in bytes. - - Function: int iks_has_children (iks* X); + -- Function: int iks_has_children (iks* X); Returns a non-zero value if node X has a child node. - - Function: int iks_has_attribs (iks* X); + -- Function: int iks_has_attribs (iks* X); Returns a non-zero value if node X has attributes. Last group of the functions simplifies finding and accessing the content of a specific node: - - Function: iks* iks_find (iks* X, const char* NAME); + -- Function: iks* iks_find (iks* X, const char* NAME); Searches a IKS_TAG type of node with NAME as tag name in child nodes of X. Returns a pointer to the node if found, NULL otherwise. - - Function: char* iks_find_cdata (iks* X, const char* NAME); + -- Function: char* iks_find_cdata (iks* X, const char* NAME); Searches a IKS_TAG type of node with NAME as tag name in child nodes of X. Returns a pointer to the character data of the node's first child node if found, NULL otherwise. - - Function: char* iks_find_attrib (iks* X, const char* NAME); + -- Function: char* iks_find_attrib (iks* X, const char* NAME); Searches an attribute with given name in attributes of the X. Returns a pointer to attribute value if found, NULL otherwise. - - Function: iks * iks_find_with_attrib (iks *X, const char *TAGNAME, + -- Function: iks * iks_find_with_attrib (iks *X, const char *TAGNAME, const char *ATTRNAME, const char *VALUE); Searches for a child tag of X which has an attribute with name ATTRNAME and value VALUE. If TAGNAME isn't NULL, name of the tag @@ -613,12 +618,12 @@ #include #include - + int main (int argc, char *argv[]) { iks *x, *y; int e; - + if (argc < 2) { printf ("usage: %s ", argv[0]); return 0; @@ -644,13 +649,13 @@  File: iksemel, Node: Converting a Tree into an XML Document, Next: Parsing an XML Document into a Tree, Prev: Accessing the Tree, Up: Working with XML Trees -Converting a Tree to an XML Document ------------------------------------- +2.2.4 Converting a Tree to an XML Document +------------------------------------------ There is a function for converting given XML tree into a null terminated string. - - Function: char * iks_string (ikstack* STACK, iks* X); + -- Function: char * iks_string (ikstack* STACK, iks* X); Converts given tree into a string. String is created inside the given object stack. Returns a pointer to the string, or NULL if there isn't enough memory available. @@ -662,7 +667,7 @@ iks *x; char *t; - + x = iks_new ("test"); iks_insert_cdata (iks_insert (x, "a"), "1234", 4); iks_insert (x, "br"); @@ -674,15 +679,15 @@  File: iksemel, Node: Parsing an XML Document into a Tree, Prev: Converting a Tree into an XML Document, Up: Working with XML Trees -Parsing a Document into a Tree ------------------------------- +2.2.5 Parsing a Document into a Tree +------------------------------------ If you want to automatically convert an XML document into a tree, you can use iksemel's DOM parser. It is created with following function: - - Function: iksparser* iks_dom_new (iks **İKSPTR); + -- Function: iksparser* iks_dom_new (iks **IKSPTR); Creates a DOM parser. A pointer to the created XML tree is put - into the variable pointed by İKSPTR. Returns a pointer to the + into the variable pointed by IKSPTR. Returns a pointer to the parser, or NULL is there isn't enough memory. Usage is same as SAX parser. You feed the data with `iks_parse', and @@ -693,13 +698,13 @@ iks *x; iksparser *p; - + p = iks_dom_new (&x); if (IKS_OK != iks_parse (p, "bcd", 9, 1)) { puts ("parse error"); } /* x is useable after that point */ - + /* this will print 'bcd' */ printf ("%s\n", iks_cdata (iks_child (x))); @@ -707,16 +712,17 @@ idea, you can tell this to the dom parser for choosing a better memory allocation strategy. Here is the function for this. - - Function: void iks_set_size_hint (iksparser *PRS, size_t - APPROX_SİZE); - Parser PRS must be a dom type parser. APPROX_SİZE is the expected + -- Function: void iks_set_size_hint (iksparser *PRS, size_t + APPROX_SIZE); + Parser PRS must be a dom type parser. APPROX_SIZE is the expected size of the xml document. Parser chooses its chunk size based on this information. Helps performance while processing big files. If you already have your XML document in memory, you can simply parse it with: - - Function: iks * iks_tree (const char *XML_STR, size_t LEN, int *ERR); + -- Function: iks * iks_tree (const char *XML_STR, size_t LEN, int + *ERR); This function parses the buffer pointed by XML_STR. If LEN is zero buffer is considered as a null terminated utf8 string. Returns the parsed tree, or NULL if there is an error. If ERR is not NULL, @@ -726,11 +732,11 @@ files directly into trees. iksemel provides two functions to greatly simplify this: - - Function: int iks_load (const char *FNAME, iks **XPTR); + -- Function: int iks_load (const char *FNAME, iks **XPTR); Loads the XML file. Tree is placed into the variable pointed by XPTR. - - Function: int iks_save (const char *FNAME, iks *X); + -- Function: int iks_save (const char *FNAME, iks *X); Converts tree X into a string and saves to the file. Both functions return same error codes as `iks_parse'. Some @@ -750,7 +756,7 @@ another: iks *x; - + if (IKS_OK != iks_load ("file1.xml", &x)) { puts ("loading error"); } @@ -761,8 +767,8 @@  File: iksemel, Node: XML Streams, Next: Writing a Jabber Client, Prev: Working with XML Trees, Up: Tutorials -XML Streams -=========== +2.3 XML Streams +=============== XML streams function as containers for any XML chunks sent asynchronously between network endpoints. They are used for @@ -788,13 +794,13 @@ You can create such a parser with: - - Function: iksparser* iks_stream_new (char* NAME_SPACE, void* + -- Function: iksparser* iks_stream_new (char* NAME_SPACE, void* USER_DATA, iksStreamHook* STREAMHOOK); Allocates and initalizes a stream parser. NAME_SPACE indicates the stream type, jabber clients use "jabber:client" namespace. USER_DATA is passed directly to your hook function. - - Typedef: iksStreamHook + -- Typedef: iksStreamHook int iksStreamHook (void* USER_DATA, int TYPE, iks* NODE); Depending on the value of the TYPE, NODE contains: @@ -842,51 +848,51 @@ `iks_disconnect' after getting this error from data transfer functions. - - Function: int iks_connect_tcp (iksparser *PRS, const char *SERVER, + -- Function: int iks_connect_tcp (iksparser *PRS, const char *SERVER, int PORT); This function connects the parser to a server and sends stream header for you. SERVER is the host name of the server and PORT is the tcp port number which server is listening to. You can use `IKS_JABBER_PORT' macro for the default jabber client port (5222). - - Function: int iks_connect_fd (iksparser *PRS, int FD); + -- Function: int iks_connect_fd (iksparser *PRS, int FD); Attaches parser to an already opened connection. FD is the socket descriptor. Note that `iks_disconnect' doesn't close the socket for this kind of connection, opening and closing of the socket is up to your application. Stream header is not sent automatically. You can use `iks_send_header' function for sending it. - - Function: void iks_disconnect (iksparser *PRS); + -- Function: void iks_disconnect (iksparser *PRS); Closes connection to the server, and frees connection resources. After successfully connecting to a server, you can use following functions for exchanging information with server. - - Function: int iks_recv (iksparser* PRS, int TİMEOUT); - If TİMEOUT is `-1', waits until some data arrives from server, and + -- Function: int iks_recv (iksparser* PRS, int TIMEOUT); + If TIMEOUT is `-1', waits until some data arrives from server, and process the data. Your stream hook can be called if a complete chunk is arrived. - If TİMEOUT is a positive integer, `iks_recv' returns if no data - arrives for TİMEOUT seconds. + If TIMEOUT is a positive integer, `iks_recv' returns if no data + arrives for TIMEOUT seconds. - If TİMEOUT is zero, `iks_recv' checks if there is any data waiting + If TIMEOUT is zero, `iks_recv' checks if there is any data waiting at the network buffer, and returns without waiting for data. - - Function: int iks_fd (iksparser* PRS); + -- Function: int iks_fd (iksparser* PRS); Returns the file descriptor of the connected socket. You can use this in your `select' function or some other input loop to act whenever some data from the server arrives. This value of only valid between a successful `iks_connect_tcp' and `iks_disconnect'. - - Function: int iks_send (iksparser* PRS, iks* X); + -- Function: int iks_send (iksparser* PRS, iks* X); Converts the tree given in X to a string, and sends to the server. String is created inside the object stack of X. - - Function: int iks_send_raw (iksparser* PRS, char* XMLSTR); + -- Function: int iks_send_raw (iksparser* PRS, char* XMLSTR); Sends the string given in XMLSTR to the server. - - Function: int iks_send_header (iksparser *PRS, char *TO); + -- Function: int iks_send_header (iksparser *PRS, char *TO); Sends the stream header. TO is the name of the server. Normally `iks_connect_tcp' function calls this for you. This is only useful if you are using `iks_connect_fd'. @@ -895,28 +901,28 @@ parser for debugging your applications. iksemel provides a logging facility for you. - - Function: void iks_set_log_hook (iksparser* PRS, iksLogHook* + -- Function: void iks_set_log_hook (iksparser* PRS, iksLogHook* LOGHOOK); Sets the log function for your stream parser. You can't use this function on any other type of parser. - - Typedef: iksLogHook - void iksLogHook (void* USER_DATA, const char* DATA, size_t SİZE, - int İS_İNCOMİNG); + -- Typedef: iksLogHook + void iksLogHook (void* USER_DATA, const char* DATA, size_t SIZE, + int IS_INCOMING); USER_DATA is same value which you give with `iks_stream_new'. - DATA is SİZE bytes of data. Be very careful that this data may be + DATA is SIZE bytes of data. Be very careful that this data may be coming from other side of the connection and can contain malicius bytes. It isn't checked by iksemel yet, so you should check it yourself before displaying or passing to other systems in your - application or computer. If İS_İNCOMİNG is a non-zero value, data + application or computer. If IS_INCOMING is a non-zero value, data is incoming from server, otherwise it is outgoing to the server.  File: iksemel, Node: Writing a Jabber Client, Next: Utility Functions, Prev: XML Streams, Up: Tutorials -Writing a Jabber Client -======================= +2.4 Writing a Jabber Client +=========================== * Menu: @@ -931,28 +937,28 @@  File: iksemel, Node: Security, Next: Packets, Up: Writing a Jabber Client -Security --------- +2.4.1 Security +-------------- iksemel supports TLS protocol for encrypted communication and SASL protocol for authentication. TLS is handled by gnutls library. - - Function: int iks_has_tls (void); + -- Function: int iks_has_tls (void); If iksemel is compiled with gnutls library, this function returns a non-zero value indicating you can try encrypted connection with the server. - - Function: int iks_start_tls (iksparser* PRS); + -- Function: int iks_start_tls (iksparser* PRS); Starts a TLS handshake over already connected parser. Returns IKS_OK or one of the IKS_NET_ errors. If handshake succeeds you'll get another stream header from server. - - Function: int iks_is_secure (iksparser* PRS); + -- Function: int iks_is_secure (iksparser* PRS); Returns a non-zero value if a secure connection is fully established between server. - - Function: int iks_start_sasl (iksparser* PRS, enum ikssasltype TYPE, - char* USERNAME, char* PASS); + -- Function: int iks_start_sasl (iksparser* PRS, enum ikssasltype + TYPE, char* USERNAME, char* PASS); Starts SASL operation. See tools/iksroster.c for a good example. @@ -960,8 +966,8 @@  File: iksemel, Node: Packets, Next: Packet Filter, Prev: Security, Up: Writing a Jabber Client -Packets -------- +2.4.2 Packets +------------- iksemel can parse a jabber XML node and provide you a public packet structure which contains information like node type and subtype, id, @@ -970,7 +976,7 @@ This handles a lot of node parsing for you. Packets are also used in the packet filter subsystem. - - Function: ikspak * iks_packet (iks *X); + -- Function: ikspak * iks_packet (iks *X); Takes a node from stream and extracts information from it to a packet structure. Structure is allocated inside the node's object stack. @@ -1095,7 +1101,7 @@ iksemel has two functions to parse and compare jabber IDs. - - Function: iksid * iks_id_new (ikstack *S, const char *JİD); + -- Function: iksid * iks_id_new (ikstack *S, const char *JID); Parses a jabber id into its parts. `iksid' structure is created inside the S object stack. @@ -1119,7 +1125,7 @@ You can access this fields and read their values. Comparing two parsed jabber ids can be done with: - - Function: int iks_id_cmp (iksid *A, iksid *B, int PARTS); + -- Function: int iks_id_cmp (iksid *A, iksid *B, int PARTS); Compares PARTS of A and B. Part values are: `IKS_ID_USER' @@ -1144,28 +1150,28 @@  File: iksemel, Node: Packet Filter, Next: Creating Common Packets, Prev: Packets, Up: Writing a Jabber Client -Packet Filter -------------- +2.4.3 Packet Filter +------------------- Packet filter handles routing incoming packets to related functions. - - Function: iksfilter * iks_filter_new (void); + -- Function: iksfilter * iks_filter_new (void); Creates a new packet filter. - - Function: void iks_filter_packet (iksfilter *F, ikspak *PAK); + -- Function: void iks_filter_packet (iksfilter *F, ikspak *PAK); Feeds the filter with given packet. Packet is compared to registered rules and hook functions of the matching rules are called in most matched to least matched order. - - Function: void iks_filter_delete (iksfilter *F); + -- Function: void iks_filter_delete (iksfilter *F); Frees filter and rules. Rules are created with following function: - - Function: iksrule * iks_filter_add_rule (iksfilter *F, iksFilterHook - *FİLTERHOOK, void *USER_DATA, ...); + -- Function: iksrule * iks_filter_add_rule (iksfilter *F, + iksFilterHook *FILTERHOOK, void *USER_DATA, ...); Adds a rule to the filter F. USER_DATA is passed directly to your - hook function FİLTERHOOK. + hook function FILTERHOOK. A rule consist of one or more type and value pairs. Possible types: `IKS_RULE_ID' @@ -1192,7 +1198,7 @@ Here is an example which creates a filter and adds three rules: iksfilter *f; - + f = iks_filter_new (); iks_filter_add_rule (f, on_msg, NULL, IKS_RULE_TYPE, IKS_PAK_MESSAGE, @@ -1208,7 +1214,7 @@ IKS_RULE_NS, "jabber:iq:roster", IKS_RULE_DONE); - - Typedef: iksFilterHook + -- Typedef: iksFilterHook int iksFilterHook (void *user_data, ikspak *pak); Your hook is called with your USER_DATA and matching packet PAK. @@ -1221,58 +1227,59 @@ You can remove the rules with following functions: - - Function: void iks_filter_remove_rule (iksfilter *F, iksrule *RULE); + -- Function: void iks_filter_remove_rule (iksfilter *F, iksrule *RULE); Removes the rule from filter. - - Function: void iks_filter_remove_hook (iksfilter *F, iksFilterHook - *FİLTERHOOK); - Remove the rules using FİLTERHOOK function from filter. + -- Function: void iks_filter_remove_hook (iksfilter *F, iksFilterHook + *FILTERHOOK); + Remove the rules using FILTERHOOK function from filter.  File: iksemel, Node: Creating Common Packets, Prev: Packet Filter, Up: Writing a Jabber Client -Creating Common Packets ------------------------ +2.4.4 Creating Common Packets +----------------------------- A usual jabber network traffic contains many similar XML constructs. iksemel provides several utility functions for creating them. They all generate an XML tree, so you can add or modify some parts of the tree, and send to server then. - - Function: iks * iks_make_auth (iksid *İD, const char *PASS, const - char *SİD); - Creates an authorization packet. İD is your parsed jabber id, and + -- Function: iks * iks_make_auth (iksid *ID, const char *PASS, const + char *SID); + Creates an authorization packet. ID is your parsed jabber id, and PASS is your password. - If stream id SİD isn't NULL, SHA1 authentication is used, + If stream id SID isn't NULL, SHA1 authentication is used, otherwise password is attached in plain text. You can learn stream id from `IKS_STREAM_START' packet in your stream hook like this: char *sid; - + if (type == IKS_STREAM_START) { sid = iks_find_attrib (node, "id"); } - - Function: iks * iks_make_msg (enum iksubtype TYPE, const char *TO, + -- Function: iks * iks_make_msg (enum iksubtype TYPE, const char *TO, const char *BODY); Creates a message packet. TYPE is the message type, TO is jabber id of the recipient, BODY is the message. - - Function: iks * iks_make_s10n (enum iksubtype TYPE, const char *TO, + -- Function: iks * iks_make_s10n (enum iksubtype TYPE, const char *TO, const char *MSG); Creates a presence packet for subscription operations. TYPE is operation, TO is jabber id of the recipient, MSG is a small message for introducing yourself, or explaning the reason of why you are subscribing or unsubscribing. - - Function: iks * iks_make_pres (enum ikshowtype SHOW, const char + -- Function: iks * iks_make_pres (enum ikshowtype SHOW, const char *STATUS); Creates a presence packet for publishing your presence. SHOW is your presence state and STATUS is a message explaining why you are not available at the moment, or what you are doing now. - - Function: iks * iks_make_iq (enum iksubtype TYPE, const char *XMLNS); + -- Function: iks * iks_make_iq (enum iksubtype TYPE, const char + *XMLNS); Creates an IQ packet. TYPE is operation type and XMLNS is the namespace of the content. You usually have to add real content to the tag before sending this packet. @@ -1280,15 +1287,15 @@  File: iksemel, Node: Utility Functions, Prev: Writing a Jabber Client, Up: Tutorials -Utility Functions -================= +2.5 Utility Functions +===================== -Memory Utilities ----------------- +2.5.1 Memory Utilities +---------------------- - - Function: void * iks_malloc (size_t SİZE); + -- Function: void * iks_malloc (size_t SIZE); - - Function: void iks_free (void *PTR); + -- Function: void iks_free (void *PTR); These are wrappers around ANSI malloc and free functions used by the iksemel library itself. You can free the output of iks_string (only if @@ -1296,21 +1303,21 @@ if you are using a malloc debugger in your application but not in iksemel or vice versa. -String Utilities ----------------- +2.5.2 String Utilities +---------------------- - - Function: char * iks_strdup (const char *SRC); + -- Function: char * iks_strdup (const char *SRC); - - Function: int iks_strcmp (const char *A, const char *B); + -- Function: int iks_strcmp (const char *A, const char *B); - - Function: int iks_strcasecmp (const char *A, const char *B); + -- Function: int iks_strcasecmp (const char *A, const char *B); - - Function: int iks_strncmp (const char *A, const char *B, size_t N); + -- Function: int iks_strncmp (const char *A, const char *B, size_t N); - - Function: int iks_strncasecmp (const char *A, const char *B, size_t + -- Function: int iks_strncasecmp (const char *A, const char *B, size_t N); - - Function: size_t iks_strlen (const char *SRC); + -- Function: size_t iks_strlen (const char *SRC); These functions work exactly like their ANSI equivalents except that they allow NULL values for string pointers. If SRC is NULL, iks_strdup @@ -1326,8 +1333,8 @@ iks_find_attrib returns NULL. So you don't need to use temporary variables in such situations. -SHA1 Hash ---------- +2.5.3 SHA1 Hash +--------------- Secure Hash Algorithm (SHA1) is used in the Jabber authentication protocol for encoding your password when sending to the server. This @@ -1335,23 +1342,23 @@ handle it manually, or if you need a good hash function for other purproses you can use these functions. - - Function: iksha* iks_sha_new (void); + -- Function: iksha* iks_sha_new (void); Allocates a structure for keeping calculation values and the state. - - Function: void iks_sha_reset (iksha *SHA); + -- Function: void iks_sha_reset (iksha *SHA); Resets the state of the calculation. - - Function: void iks_sha_hash (iksha *SHA, const unsigned char *DATA, - int LEN, int FİNİSH); - Calculates the hash value of the given data. If FİNİSH is non + -- Function: void iks_sha_hash (iksha *SHA, const unsigned char *DATA, + int LEN, int FINISH); + Calculates the hash value of the given data. If FINISH is non zero, applies the last step of the calculation. - - Function: void iks_sha_print (iksha *SHA, char *HASH); + -- Function: void iks_sha_print (iksha *SHA, char *HASH); Prints the result of a finished calculation into the buffer pointed by HASH in hexadecimal string form. Buffer must be at least 40 bytes long. String is not null terminated. - - Function: void iks_sha (const char *DATA, char *HASH); + -- Function: void iks_sha (const char *DATA, char *HASH); Calculates the hash value of DATA and prints into HASH. This is a helper function for simple hash calculations. It calls other functions for the actual work. @@ -1359,14 +1366,14 @@  File: iksemel, Node: Development, Next: Datatype Index, Prev: Tutorials, Up: Top -Development -*********** +3 Development +************* This chapter contains information on plan, procedure and standarts of iksemel development. -Roadmap -======= +3.1 Roadmap +=========== There are three main functions iksemel tries to provide to applications: * A generic XML parser with SAX and DOM interfaces. @@ -1400,8 +1407,8 @@ development. Instead of using an autogenerated system or simply listing function descriptions, a task oriented tutorial approach is used. -Coding Style -============ +3.2 Coding Style +================ Here is a short list describing preferred coding style for iksemel. Please keep in mind when sending patches. @@ -1435,7 +1442,7 @@ iks_new_func (char *text) { int i; - + i = an_internal_func (text); if (IKS_SOME_VALUE == i) { iks_some_func (text); @@ -1444,17 +1451,17 @@ return i; } -Resources -========= +3.3 Resources +============= - * RFC 2279, UTF-8 format + * RFC 2279, UTF-8 format `http://www.ietf.org/rfc/rfc2279.txt' * W3C Recommendation, Extensible Markup Language 1.0 - + `http://www.w3.org/TR/REC-xml' - * Annotated XML Specification + * Annotated XML Specification `http://www.xml.com/axml/testaxml.htm' - * Jabber Protocol Documents + * Jabber Protocol Documents `http://www.jabber.org/protocol/'  File: iksemel, Node: Datatype Index, Next: Function Index, Prev: Development, Up: Top @@ -1462,21 +1469,25 @@ Datatype Index ************** +[index] * Menu: -* iks: Creating a Tree. +* iks: Creating a Tree. (line 7) * iksCDataHook: Parsing an XML Document. -* iksfilter: Packet Filter. -* iksFilterHook: Packet Filter. -* iksid: Packets. -* iksLogHook: XML Streams. -* ikspak: Packets. + (line 42) +* iksfilter: Packet Filter. (line 8) +* iksFilterHook: Packet Filter. (line 68) +* iksid: Packets. (line 142) +* iksLogHook: XML Streams. (line 143) +* ikspak: Packets. (line 18) * iksparser: Parsing an XML Document. -* iksrule: Packet Filter. -* iksStreamHook: XML Streams. -* ikstack: Memory Management. + (line 12) +* iksrule: Packet Filter. (line 21) +* iksStreamHook: XML Streams. (line 37) +* ikstack: Memory Management. (line 34) * iksTagHook: Parsing an XML Document. -* ikstype: Accessing the Tree. + (line 22) +* ikstype: Accessing the Tree. (line 45)  File: iksemel, Node: Function Index, Prev: Datatype Index, Up: Top @@ -1484,119 +1495,137 @@ Function Index ************** +[index] * Menu: -* iks_attrib: Accessing the Tree. -* iks_cdata: Accessing the Tree. -* iks_cdata_size: Accessing the Tree. -* iks_child: Accessing the Tree. -* iks_connect_fd: XML Streams. -* iks_connect_tcp: XML Streams. -* iks_copy: Creating a Tree. -* iks_copy_within: Creating a Tree. -* iks_delete: Creating a Tree. -* iks_disconnect: XML Streams. +* iks_attrib: Accessing the Tree. (line 17) +* iks_cdata: Accessing the Tree. (line 58) +* iks_cdata_size: Accessing the Tree. (line 62) +* iks_child: Accessing the Tree. (line 15) +* iks_connect_fd: XML Streams. (line 92) +* iks_connect_tcp: XML Streams. (line 86) +* iks_copy: Creating a Tree. (line 101) +* iks_copy_within: Creating a Tree. (line 104) +* iks_delete: Creating a Tree. (line 56) +* iks_disconnect: XML Streams. (line 99) * iks_dom_new: Parsing an XML Document into a Tree. -* iks_fd: XML Streams. -* iks_filter_add_rule: Packet Filter. -* iks_filter_delete: Packet Filter. -* iks_filter_new: Packet Filter. -* iks_filter_packet: Packet Filter. -* iks_filter_remove_hook: Packet Filter. -* iks_filter_remove_rule: Packet Filter. -* iks_find: Accessing the Tree. -* iks_find_attrib: Accessing the Tree. -* iks_find_cdata: Accessing the Tree. -* iks_find_with_attrib: Accessing the Tree. -* iks_first_tag: Accessing the Tree. -* iks_free: Utility Functions. -* iks_has_attribs: Accessing the Tree. -* iks_has_children: Accessing the Tree. -* iks_has_tls: Security. -* iks_hide: Creating a Tree. -* iks_id_cmp: Packets. -* iks_id_new: Packets. -* iks_insert: Creating a Tree. -* iks_insert_attrib: Creating a Tree. -* iks_insert_cdata: Creating a Tree. -* iks_insert_node: Creating a Tree. -* iks_is_secure: Security. + (line 10) +* iks_fd: XML Streams. (line 116) +* iks_filter_add_rule: Packet Filter. (line 23) +* iks_filter_delete: Packet Filter. (line 17) +* iks_filter_new: Packet Filter. (line 9) +* iks_filter_packet: Packet Filter. (line 12) +* iks_filter_remove_hook: Packet Filter. (line 85) +* iks_filter_remove_rule: Packet Filter. (line 81) +* iks_find: Accessing the Tree. (line 74) +* iks_find_attrib: Accessing the Tree. (line 83) +* iks_find_cdata: Accessing the Tree. (line 78) +* iks_find_with_attrib: Accessing the Tree. (line 88) +* iks_first_tag: Accessing the Tree. (line 30) +* iks_free: Utility Functions. (line 12) +* iks_has_attribs: Accessing the Tree. (line 68) +* iks_has_children: Accessing the Tree. (line 65) +* iks_has_tls: Security. (line 10) +* iks_hide: Creating a Tree. (line 52) +* iks_id_cmp: Packets. (line 163) +* iks_id_new: Packets. (line 139) +* iks_insert: Creating a Tree. (line 22) +* iks_insert_attrib: Creating a Tree. (line 37) +* iks_insert_cdata: Creating a Tree. (line 29) +* iks_insert_node: Creating a Tree. (line 48) +* iks_is_secure: Security. (line 20) * iks_load: Parsing an XML Document into a Tree. + (line 57) * iks_make_auth: Creating Common Packets. + (line 13) * iks_make_iq: Creating Common Packets. + (line 46) * iks_make_msg: Creating Common Packets. + (line 28) * iks_make_pres: Creating Common Packets. + (line 40) * iks_make_s10n: Creating Common Packets. -* iks_malloc: Utility Functions. -* iks_name: Accessing the Tree. -* iks_new: Creating a Tree. -* iks_new_within: Creating a Tree. -* iks_next: Accessing the Tree. -* iks_next_tag: Accessing the Tree. + (line 33) +* iks_malloc: Utility Functions. (line 10) +* iks_name: Accessing the Tree. (line 55) +* iks_new: Creating a Tree. (line 11) +* iks_new_within: Creating a Tree. (line 17) +* iks_next: Accessing the Tree. (line 9) +* iks_next_tag: Accessing the Tree. (line 26) * iks_nr_bytes: Parsing an XML Document. + (line 161) * iks_nr_lines: Parsing an XML Document. -* iks_packet: Packets. -* iks_parent: Accessing the Tree. + (line 164) +* iks_packet: Packets. (line 14) +* iks_parent: Accessing the Tree. (line 13) * iks_parse: Parsing an XML Document. + (line 53) * iks_parser_delete: Parsing an XML Document. + (line 75) * iks_parser_reset: Parsing an XML Document. -* iks_prev: Accessing the Tree. -* iks_prev_tag: Accessing the Tree. -* iks_recv: XML Streams. -* iks_root: Accessing the Tree. + (line 170) +* iks_prev: Accessing the Tree. (line 11) +* iks_prev_tag: Accessing the Tree. (line 28) +* iks_recv: XML Streams. (line 105) +* iks_root: Accessing the Tree. (line 23) * iks_save: Parsing an XML Document into a Tree. + (line 61) * iks_sax_new: Parsing an XML Document. -* iks_send: XML Streams. -* iks_send_header: XML Streams. -* iks_send_raw: XML Streams. -* iks_set_log_hook: XML Streams. + (line 17) +* iks_send: XML Streams. (line 122) +* iks_send_header: XML Streams. (line 129) +* iks_send_raw: XML Streams. (line 126) +* iks_set_log_hook: XML Streams. (line 139) * iks_set_size_hint: Parsing an XML Document into a Tree. -* iks_sha: Utility Functions. -* iks_sha_hash: Utility Functions. -* iks_sha_new: Utility Functions. -* iks_sha_print: Utility Functions. -* iks_sha_reset: Utility Functions. -* iks_stack: Accessing the Tree. -* iks_stack_alloc: Memory Management. -* iks_stack_delete: Memory Management. -* iks_stack_new: Memory Management. -* iks_stack_strcat: Memory Management. -* iks_stack_strdup: Memory Management. -* iks_start_sasl: Security. -* iks_start_tls: Security. -* iks_strcasecmp: Utility Functions. -* iks_strcmp: Utility Functions. -* iks_strdup: Utility Functions. -* iks_stream_new: XML Streams. + (line 38) +* iks_sha: Utility Functions. (line 75) +* iks_sha_hash: Utility Functions. (line 66) +* iks_sha_new: Utility Functions. (line 59) +* iks_sha_print: Utility Functions. (line 70) +* iks_sha_reset: Utility Functions. (line 62) +* iks_stack: Accessing the Tree. (line 40) +* iks_stack_alloc: Memory Management. (line 48) +* iks_stack_delete: Memory Management. (line 61) +* iks_stack_new: Memory Management. (line 39) +* iks_stack_strcat: Memory Management. (line 68) +* iks_stack_strdup: Memory Management. (line 56) +* iks_start_sasl: Security. (line 25) +* iks_start_tls: Security. (line 15) +* iks_strcasecmp: Utility Functions. (line 27) +* iks_strcmp: Utility Functions. (line 25) +* iks_strdup: Utility Functions. (line 23) +* iks_stream_new: XML Streams. (line 32) * iks_string: Converting a Tree into an XML Document. -* iks_strlen: Utility Functions. -* iks_strncasecmp: Utility Functions. -* iks_strncmp: Utility Functions. + (line 10) +* iks_strlen: Utility Functions. (line 34) +* iks_strncasecmp: Utility Functions. (line 32) +* iks_strncmp: Utility Functions. (line 29) * iks_tree: Parsing an XML Document into a Tree. -* iks_type: Accessing the Tree. + (line 47) +* iks_type: Accessing the Tree. (line 43)  Tag Table: -Node: Top70 -Node: Introduction752 -Node: Tutorials2511 -Node: Parsing an XML Document2753 -Node: Working with XML Trees8583 -Node: Memory Management9400 -Node: Creating a Tree13024 -Node: Accessing the Tree17285 -Node: Converting a Tree into an XML Document22000 -Node: Parsing an XML Document into a Tree23003 -Node: XML Streams25987 -Node: Writing a Jabber Client32524 -Node: Security32768 -Node: Packets33759 -Node: Packet Filter37935 -Node: Creating Common Packets40818 -Node: Utility Functions42853 -Node: Development45645 -Node: Datatype Index48552 -Node: Function Index49439 +Node: Top239 +Node: Introduction921 +Node: Tutorials2700 +Node: Parsing an XML Document2946 +Node: Working with XML Trees8777 +Node: Memory Management9602 +Node: Creating a Tree13244 +Node: Accessing the Tree17523 +Node: Converting a Tree into an XML Document22260 +Node: Parsing an XML Document into a Tree23271 +Node: XML Streams26267 +Node: Writing a Jabber Client32824 +Node: Security33076 +Node: Packets34083 +Node: Packet Filter38274 +Node: Creating Common Packets41171 +Node: Utility Functions43223 +Node: Development46072 +Node: Datatype Index49002 +Node: Function Index50295  End Tag Table --- libiksemel-1.2.orig/debian/control +++ libiksemel-1.2/debian/control @@ -0,0 +1,46 @@ +Source: libiksemel +Section: libs +Priority: optional +Maintainer: Thadeu Lima de Souza Cascardo +Build-Depends: cdbs, debhelper (>= 4.1.0), libgnutls-dev, texinfo +Standards-Version: 3.7.2 + +Package: libiksemel-dev +Section: libdevel +Architecture: any +Depends: libiksemel3 (= ${Source-Version}), libc6-dev | libc-dev +Conflicts: libiksemel1-dev +Replaces: libiksemel1-dev +Description: C library for the Jabber IM platform + iksemel handles Jabber connections, parses XML, and sends and + receives Jabber messages. It works pretty good for parsing other + kinds of XML, too, if the need arises. + . + This package provides headers, static linked library and info + documentation. + +Package: libiksemel3 +Section: libs +Architecture: any +Depends: ${shlibs:Depends} +Conflicts: libiksemel1 +Replaces: libiksemel1 +Description: C library for the Jabber IM platform + iksemel handles Jabber connections, parses XML, and sends and + receives Jabber messages. It works pretty good for parsing other + kinds of XML, too, if the need arises. + +Package: libiksemel-utils +Section: utils +Architecture: any +Depends: ${shlibs:Depends} +Replaces: libiksemel1-dev +Description: utilities from the iksemel library + iksemel handles Jabber connections, parses XML, and sends and + receives Jabber messages. It works pretty good for parsing other + kinds of XML, too, if the need arises. + . + This package includes three utilitaries from the library: ikslint, + which checks xml files for well-formedness, iksperf, which tests + speed and memory usage, and, finally, iksroster, which backups your + roster. --- libiksemel-1.2.orig/debian/changelog +++ libiksemel-1.2/debian/changelog @@ -0,0 +1,51 @@ +libiksemel (1.2-3) unstable; urgency=low + + * Fixed info file installation in rules and libiksemel-dev.info. closes: + #390068 + * Added HACKING file to libiksemel-dev docs. + * Updated Standards-Version to 3.7.20, no changes required. + * Removed prerm and postrm since dh_installinfo automatically generates + them for the purpose they were being used. + * Modified source texinfo file to include the section and description + for the info directory, which install-info will use. + * Added Section for source in control. + * Included texinfo as Build-Dep. + * Removed useless libiksemel-utils.dirs. + * Changed packages descriptions. + * Added copyright and the LGPL notices to the copyright file. + + -- Thadeu Lima de Souza Cascardo Thu, 28 Sep 2006 23:25:06 -0300 + +libiksemel (1.2-2) unstable; urgency=low + + * Build-Depends on libgnutls-dev instead of libgnutls11-dev, closes: #335758 + * Renames package from libiksemel1 to libiksemel3, fixing the soname + relationship with the package name. + * Builds a new package which distributes the utilities, + libiksemel-utils. + + -- Thadeu Lima de Souza Cascardo Tue, 25 Oct 2005 18:58:28 -0200 + +libiksemel (1.2-1) unstable; urgency=low + + * New upstream release + * New Maintainer, closes: #282296 + * Included pkg-config file in libiksemel1-dev, closes: #282266 + + -- Thadeu Lima de Souza Cascardo Thu, 25 Nov 2004 02:18:51 -0200 + +libiksemel (1.1-1) unstable; urgency=low + + * New upstream release. + * CDBS build system transition. + * Standards-Version raised to 4.6.0. + * Watch file added. + + -- Adam Byrtek Mon, 26 Jan 2004 02:16:50 +0100 + +libiksemel (0.0.1-1) unstable; urgency=low + + * Initial Release. + + -- Adam Byrtek Tue, 6 May 2003 00:08:01 +0200 + --- libiksemel-1.2.orig/debian/libiksemel3.dirs +++ libiksemel-1.2/debian/libiksemel3.dirs @@ -0,0 +1 @@ +usr/lib --- libiksemel-1.2.orig/debian/rules +++ libiksemel-1.2/debian/rules @@ -0,0 +1,9 @@ +#!/usr/bin/make -f + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/autotools.mk + +DEB_SHLIBDEPS_INCLUDE := debian/tmp/usr/lib/ + +install/libiksemel-dev:: + mv debian/tmp/usr/share/info/iksemel debian/tmp/usr/share/info/iksemel.info --- libiksemel-1.2.orig/debian/watch +++ libiksemel-1.2/debian/watch @@ -0,0 +1,3 @@ +version=2 +http://www.jabberstudio.org/projects/iksemel/releases/.*iksemel-([0-9\.]+).tar.gz.* \ + debian uupdate --- libiksemel-1.2.orig/debian/libiksemel3.docs +++ libiksemel-1.2/debian/libiksemel3.docs @@ -0,0 +1,2 @@ +AUTHORS +README --- libiksemel-1.2.orig/debian/libiksemel-dev.install +++ libiksemel-1.2/debian/libiksemel-dev.install @@ -0,0 +1,4 @@ +debian/tmp/usr/include/* +debian/tmp/usr/lib/lib*.a +debian/tmp/usr/lib/lib*.so +debian/tmp/usr/lib/pkgconfig/* --- libiksemel-1.2.orig/debian/libiksemel-utils.docs +++ libiksemel-1.2/debian/libiksemel-utils.docs @@ -0,0 +1,2 @@ +AUTHORS +README --- libiksemel-1.2.orig/debian/compat +++ libiksemel-1.2/debian/compat @@ -0,0 +1 @@ +4 --- libiksemel-1.2.orig/debian/libiksemel-dev.docs +++ libiksemel-1.2/debian/libiksemel-dev.docs @@ -0,0 +1,4 @@ +TODO +HACKING +AUTHORS +README --- libiksemel-1.2.orig/debian/libiksemel3.install +++ libiksemel-1.2/debian/libiksemel3.install @@ -0,0 +1 @@ +debian/tmp/usr/lib/lib*.so.* --- libiksemel-1.2.orig/debian/libiksemel-dev.info +++ libiksemel-1.2/debian/libiksemel-dev.info @@ -0,0 +1 @@ +debian/tmp/usr/share/info/iksemel.info --- libiksemel-1.2.orig/debian/copyright +++ libiksemel-1.2/debian/copyright @@ -0,0 +1,36 @@ +This package was debianized by Adam Byrtek on +Tue, 6 May 2003 00:08:01 +0200 + +It was downloaded from http://iksemel.jabberstudio.org/ + +Upstream Authors: Gurer Ozen + Fabien Ninoles + +Copyright (C) 2000-2004 Gurer Ozen + +License: + +/* iksemel (XML parser for Jabber) +** Copyright (C) 2000-2004 Gurer Ozen +** This code is free software; you can redistribute it and/or +** modify it under the terms of GNU Lesser General Public License. +*/ + + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + + +For the entire LGPL license - see the /usr/share/common-licenses/LGPL +file. --- libiksemel-1.2.orig/debian/libiksemel-dev.dirs +++ libiksemel-1.2/debian/libiksemel-dev.dirs @@ -0,0 +1,2 @@ +usr/lib +usr/include --- libiksemel-1.2.orig/debian/libiksemel-utils.install +++ libiksemel-1.2/debian/libiksemel-utils.install @@ -0,0 +1 @@ +debian/tmp/usr/bin/*