updates.
authorPekka Riikonen <priikone@silcnet.org>
Sun, 12 Aug 2001 12:58:33 +0000 (12:58 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Sun, 12 Aug 2001 12:58:33 +0000 (12:58 +0000)
lib/silcclient/DIRECTORY
lib/silccore/DIRECTORY
lib/silccrypt/DIRECTORY
lib/silcmath/DIRECTORY
lib/silcmath/silcmath.h
lib/silcmath/silcprimegen.c
lib/silcske/DIRECTORY
lib/silcutil/DIRECTORY
scripts/silcdoc/index.php
scripts/silcdoc/silcdoc

index f59700b904db2fb761631cacf19de35d20f10776..67fdac4f0d96121742830ee938c630ca14853687 100644 (file)
@@ -1,6 +1,7 @@
 <!--
 @LIBRARY=SILC Client Library
 @FILENAME=silcclientlib.html
+@LINK=silcapi.html:SILC Client API
 -->
 
 <OL>
@@ -26,5 +27,6 @@ the library.
 </FONT>
 </PRE>
 
-<LI><A HREF="silcapi.html">SILC Client API</A>
+@LINKS@
+
 </OL>
index 4ff09dec5e880dd634faa19a3cdab95c67ce196a..b9c23d6dbf005771d840afc78635648a408d5f12 100644 (file)
@@ -1,6 +1,17 @@
 <!--
 @LIBRARY=SILC Core Library
 @FILENAME=silccorelib.html
+@LINK=silcauth.html:SILC Auth API
+@LINK=silcchannel.html:SILC Channel API
+@LINK=silccommand.html:SILC Command API
+@LINK=silcid.html:SILC ID API
+@LINK=silcidcache.html:SILC ID Cache API
+@LINK=silcmode.html:SILC Modes
+@LINK=silcnotify.html:SILC Notify API
+@LINK=silcpacket.html:SILC Packet API
+@LINK=silcpayload.html:SILC Payload API
+@LINK=silcprivate.html:SILC Private API
+@LINK=silcprotocol.html:SILC Protocol API
 -->
 
 <OL>
@@ -14,15 +25,6 @@ routines, and routines for sending private message and channel messages.
 </FONT>
 </PRE>
 
-<LI><A HREF="silcauth.html">SILC Auth API</A>
-<LI><A HREF="silcchannel.html">SILC Channel API</A>
-<LI><A HREF="silccommand.html">SILC Command API</A>
-<LI><A HREF="silcid.html">SILC ID API</A>
-<LI><A HREF="silcidcache.html">SILC ID Cache API</A>
-<LI><A HREF="silcmode.html">SILC Modes</A>
-<LI><A HREF="silcnotify.html">SILC Notify API</A>
-<LI><A HREF="silcpacket.html">SILC Packet API</A>
-<LI><A HREF="silcpayload.html">SILC Payload API</A>
-<LI><A HREF="silcprivate.html">SILC Private API</A>
-<LI><A HREF="silcprotocol.html">SILC Protocol API</A>
+@LINKS@
+
 </OL>
index be242967605973e42cf0650d3626a9f95e026116..b3ce891dd8aea0ea3d63a3346b21e7b684825291 100644 (file)
@@ -1,6 +1,11 @@
 <!--
 @LIBRARY=SILC Crypto Library
 @FILENAME=silccryptlib.html
+@LINK=silccipher.html:SILC Cipher API
+@LINK=silchash.html:SILC Hash API
+@LINK=silchmac.html:SILC HMAC API
+@LINK=silcpkcs.html:SILC PKCS API
+@LINK=silcrng.html:SILC RNG API
 -->
 
 <OL>
@@ -14,9 +19,6 @@ strong random number generator.
 </FONT>
 </PRE>
 
-<LI><A HREF="silccipher.html">SILC Cipher API</A>
-<LI><A HREF="silchash.html">SILC Hash API</A>
-<LI><A HREF="silchmac.html">SILC HMAC API</A>
-<LI><A HREF="silcpkcs.html">SILC PKCS API</A>
-<LI><A HREF="silcrng.html">SILC RNG API</A>
+@LINKS@
+
 </OL>
index 87dba538b9fed126734c718dfc89ef9acab79d33..a4419f825f05abb5b7bbb911bbdafb9fde3ae661 100644 (file)
@@ -1,6 +1,8 @@
 <!--
 @LIBRARY=SILC Math Library
 @FILENAME=silcmathlib.html
+@LINK=silcmath.html:SILC Math API
+@LINK=silcmp.html:SILC MP API
 -->
 
 <OL>
@@ -13,6 +15,6 @@ math utility functions for applications.
 </FONT>
 </PRE>
 
-<LI><A HREF="silcmath.html">SILC Math API</A>
-<LI><A HREF="silcmp.html">SILC MP API</A>
+@LINKS@
+
 </OL>
index ef2241bf82eeeedef9d441794cca8f07da2daa31..6970b6528f636d6767cf7d74cbec0b7effe6f0b0 100644 (file)
@@ -1,24 +1,26 @@
+/*
+
+  silcmath.h
+  COPYRIGHT
+  Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
+  Copyright (C) 1997 - 2000 Pekka Riikonen
+  This program is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+  This program 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 General Public License for more details.
+
+*/
+
 /****h* silcmath/silcmath.h
- *
- * NAME
- *
- * silcmath.h
- *
- * COPYRIGHT
- *
- * Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
- *
- * Copyright (C) 1997 - 2000 Pekka Riikonen
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program 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 General Public License for more details.
  *
  * DESCRIPTION
  *
@@ -26,7 +28,7 @@
  * prime generation, and conversion routines. See the silcmp.h for the
  * SILC MP interface.
  *
- */
+ ***/
 
 #ifndef SILCMATH_H
 #define SILCMATH_H
@@ -35,7 +37,7 @@
  *
  * SYNOPSIS
  *
- *    int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, int verbose);
+ *    int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, bool verbose);
  *
  * DESCRIPTION
  *
@@ -48,7 +50,7 @@
  *    about the progress of generation.
  *
  ***/
-int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, int verbose);
+bool silc_math_gen_prime(SilcMPInt *prime, uint32 bits, bool verbose);
 
 /****f* silcmath/SilcMathAPI/silc_math_prime_test
  *
@@ -62,6 +64,6 @@ int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, int verbose);
  *    number is probably a prime.
  *
  ***/
-int silc_math_prime_test(SilcMPInt *p);
+bool silc_math_prime_test(SilcMPInt *p);
 
 #endif
index e868637c66fbb99df9d0ced69a24b72564e4c5dd..bc5edf29a298052e1428bc6a9cb17305dee38f48 100644 (file)
@@ -195,7 +195,7 @@ static uint32 primetable[] =
    If argument verbose is TRUE this will display some status information
    about the progress of generation. */
 
-int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, int verbose)
+bool silc_math_gen_prime(SilcMPInt *prime, uint32 bits, bool verbose)
 {
   unsigned char *numbuf;
   uint32 i, b, k;
@@ -303,7 +303,7 @@ int silc_math_gen_prime(SilcMPInt *prime, uint32 bits, int verbose)
 /* Performs primality testings for given number. Returns TRUE if the 
    number is probably a prime. */
 
-int silc_math_prime_test(SilcMPInt *p)
+bool silc_math_prime_test(SilcMPInt *p)
 {
   SilcMPInt r, base, tmp;
   int i, ret = 0;
index ac21924a72caf50f329f7efec6dbb774455089f7..b84ba327ba7f43ce46e95aea4bc6cce719f5a470 100644 (file)
@@ -1,6 +1,8 @@
 <!--
 @LIBRARY=SILC Key Exchange Library
 @FILENAME=silcskelib.html
+@LINK=silcske.html:SILC SKE API
+@LINK=silcske_status.html:SILC SKE Status
 -->
 
 <OL>
@@ -12,6 +14,6 @@ It provides the key exchange protocol for all SILC applications.
 </FONT>
 </PRE>
 
-<LI><A HREF="silcske.html">SILC SKE API</A>
-<LI><A HREF="silcske_status.html">SILC SKE Status</A>
+@LINKS@
+
 </OL>
index f77eee6a190bb9a8a79420163b4c36788475ea21..f95ddcc7ca10befb71fc43b7d8bc328d35af9888 100644 (file)
@@ -1,6 +1,21 @@
 <!--
 @LIBRARY=SILC Utility Library
 @FILENAME=silcutillib.html
+@LINK=silcbuffer.html:SILC Buffer API
+@LINK=silcbuffmt.html:SILC Buffer Format API
+@LINK=silcbufutil.html:SILC Buffer Utility API
+@LINK=silchashtable.html:SILC Hash Table API
+@LINK=silclog.html:SILC Log and Debug API
+@LINK=silcmemory.html:SILC Memory API
+@LINK=silcmutex.html:SILC Mutex API
+@LINK=silcthread.html:SILC Thread API
+@LINK=silcnet.html:SILC Net API
+@LINK=silcschedule.html:SILC Schedule API
+@LINK=silcsockconn.html:SILC Socket Connection API
+@LINK=silcutil.html:SILC Util API
+@LINK=silczip.html:SILC Zip API
+@LINK=silclist.html:SILC List API
+@LINK=silcdlist.html:SILC Dynamic List API
 -->
 
 <OL>
@@ -16,19 +31,6 @@ such as Unix and WIN32.
 </FONT>
 </PRE>
 
-<LI><A HREF="silcbuffer.html">SILC Buffer API</A>
-<LI><A HREF="silcbuffmt.html">SILC Buffer Format API</A>
-<LI><A HREF="silcbufutil.html">SILC Buffer Utility API</A>
-<LI><A HREF="silchashtable.html">SILC Hash Table API</A>
-<LI><A HREF="silclog.html">SILC Log and Debug API</A>
-<LI><A HREF="silcmemory.html">SILC Memory API</A>
-<LI><A HREF="silcmutex.html">SILC Mutex API</A>
-<LI><A HREF="silcthread.html">SILC Thread API</A>
-<LI><A HREF="silcnet.html">SILC Net API</A>
-<LI><A HREF="silcschedule.html">SILC Schedule API</A>
-<LI><A HREF="silcsockconn.html">SILC Socket Connection API</A>
-<LI><A HREF="silcutil.html">SILC Util API</A>
-<LI><A HREF="silczip.html">SILC Zip API</A>
-<LI><A HREF="silclist.html">SILC List API</A>
-<LI><A HREF="silcdlist.html">SILC Dynamic List API</A>
+@LINKS@
+
 </OL>
index b05487acd10a480b80e0e363066b4fd4dae26ac2..6626c46365b5590850e970508815effc47147448 100644 (file)
 
 <br />
 <div align="center">
-<table width="800" bgcolor="#000000" cellpadding="1" cellspacing="0" border="0">
+<table width="900" bgcolor="#000000" cellpadding="1" cellspacing="0" border="0">
  <tr>
   <td>
     <table width="100%" bgcolor="#ffffff" cellpadding="0" cellspacing="0" border="0">
      <tr>
       <td>
         <table width="100%" bgcolor="#e2e2e2" cellpadding="10" cellspacing="0" border="0">
-        <tr><td><font face="Helvetica,Arial,Sans-serif">
+        <tr>
+       <td valign="top"><font face="Helvetica,Arial,Sans-serif">
+       <table width="100%" bgcolor="#e2e2e2" cellpadding="1" cellspacing="0" border="0" align="left">
+       <tr><td valign="top"><font face="Helvetica,Arial,Sans-serif">
+<?php
+require index.tmpl
+?>
+       </td></tr>
+       </table>
+       </td>
+       <td valign="top"><font face="Helvetica,Arial,Sans-serif">
 <?php
 require "$page";
 ?>
index 75136813db79e31bbf0532838c2765282c9bd272..dd0fe385cfcc381a05a95553b3a01061f661b762 100755 (executable)
@@ -42,6 +42,26 @@ if [ "$TYPE" = "HTML" ]; then
   mkdir /tmp/silcdoc.html
   cp $headers /tmp/silcdoc.html
 
+  # Generate indes template from the DIRECTORY files
+  files=`find $SRC -name "DIRECTORY"`
+  for i in $files
+  do
+    # Get library name
+    name=`grep "@LIBRARY=" $i |cut -d=  -f2`
+    fname=`grep "@FILENAME=" $i |cut -d=  -f2`
+    links=`grep "@LINK=" $i |cut -d=  -f2 |cut -d:  -f1`
+
+    # Generate links to template file that can be included into various
+    # places on the webpage.
+    echo "<A HREF="$fname">$name</A><BR>" >>$DST/index.tmpl
+    for k in $links
+    do
+      n=`grep $k $i |cut -d=  -f2 |cut -d:  -f2`
+      echo "<LI><A HREF="$k">$n</A>" >>$DST/$fname.links
+      echo "&nbsp;&nbsp;&nbsp; <A HREF="$k">$n</A><BR>" >>$DST/index.tmpl
+    done
+  done
+
   # Generate the actual detailed documentation
   path=`pwd`
   cd /tmp/silcdoc.html
@@ -52,15 +72,15 @@ if [ "$TYPE" = "HTML" ]; then
     $ROBO /tmp/silcdoc.html/$i.h $DST/$i.html $TYPE
 
     # Generate the TOC file
-    sh gen.sh gen_toc.php $DST/$i.html $DST/$i.html
-    sh gen.sh index.php $DST/$i.html $DST/$i.html
+    sh gen.sh $DST gen_toc.php $DST/$i.html $DST/$i.html
+    sh gen.sh $DST index.php $DST/$i.html $DST/$i.html
 
     # Generate the details and the layour
     files=`find $DST -name ""$i"_*.html"`
     for k in $files
     do
-      sh gen.sh gen_detail.php $k $k
-      sh gen.sh index.php $k $k
+      sh gen.sh $DST gen_detail.php $k $k
+      sh gen.sh $DST index.php $k $k
     done
 
     rm -f $DST/$i_index.tmpl
@@ -68,27 +88,30 @@ if [ "$TYPE" = "HTML" ]; then
 
   # Generate the index and TOC files from the DIRECTORY files
   files=`find $SRC -name "DIRECTORY"`
-  touch $DST/index.html.tmp
   for i in $files
   do
     # Get library name
     name=`grep "@LIBRARY=" $i |cut -d=  -f2`
-    fname=`grep "@FILENAME" $i |cut -d=  -f2`
+    fname=`grep "@FILENAME=" $i |cut -d=  -f2`
+
+    # Generate links for this library
+    sed -e "/@LINKS@/ r $DST/$fname.links" -e s/@LINKS@//g $i >$DST/$fname
 
     # Generate the TOC file for the library
-    sh gen.sh gen_toc.php $i $DST/$fname
-    sh gen.sh index.php $DST/$fname $DST/$fname
+    sh gen.sh $DST gen_toc.php $DST/$fname $DST/$fname
+    sh gen.sh $DST index.php $DST/$fname $DST/$fname
 
     # Generate the link for the top index.html for this library
     echo "<LI><A HREF="$fname">$name</A>" >>$DST/index.html.tmp
+    rm -f $DST/$fname.links
   done
 
   # Generate the top index.html file
   index=`find $SRC -name "LIBINDEX"`
   curdate=`date`
   sed -e "/@DATE@/s//$curdate/" -e "/@BODY@/ r $DST/index.html.tmp" -e s/@BODY@//g $index >$DST/index.html
-  sh gen.sh gen_toc.php $DST/index.html $DST/index.html
-  sh gen.sh index.php $DST/index.html $DST/index.html
+  sh gen.sh $DST gen_toc.php $DST/index.html $DST/index.html
+  sh gen.sh $DST index.php $DST/index.html $DST/index.html
 
   rm -rf $DST/index.html.tmp
   rm -rf /tmp/silcdoc.html