File:  [local] / rpl / src / conversion.awk
Revision 1.8: download - view: text, annotated - select for diffs - revision graph
Tue Feb 26 19:56:11 2013 UTC (11 years, 2 months ago) by bertrand
Branches: MAIN
CVS tags: rpl-4_1_35, rpl-4_1_34, rpl-4_1_33, rpl-4_1_32, rpl-4_1_31, rpl-4_1_30, rpl-4_1_29, rpl-4_1_28, rpl-4_1_27, rpl-4_1_26, rpl-4_1_25, rpl-4_1_24, rpl-4_1_23, rpl-4_1_22, rpl-4_1_21, rpl-4_1_20, rpl-4_1_19, rpl-4_1_18, rpl-4_1_17, rpl-4_1_16, rpl-4_1_15, rpl-4_1_14, rpl-4_1_13, rpl-4_1_12, HEAD
Mise à jour des copyrights.

    1: BEGIN {
    2:     indicateur = 0;
    3: }
    4: 
    5: /^\/\/ BEGIN C PROTOTYPES/ {
    6:     indicateur = 1;
    7: }
    8: 
    9: /^\/\/ END C PROTOTYPES/ {
   10:     indicateur = 0;
   11: }
   12: 
   13: /^([abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_]+[ ]+)+/ {
   14:     if (indicateur == 1)
   15:     {
   16:         if ($1 == "unsigned" || $1 == "signed" || $1 == "inline")
   17:             LIGNE = $3;
   18:         else
   19:             LIGNE = $2;
   20:         LIGNE = substr(LIGNE, 1, index(LIGNE, "(") - 1);
   21:         while(substr(LIGNE, 1, 1) == "*")
   22:             LIGNE = substr(LIGNE, 2, length(LIGNE) - 1);
   23:         printf("#define %s librpl_%s\n", LIGNE, LIGNE);
   24:     }
   25: }

CVSweb interface <joel.bertrand@systella.fr>