New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 9987 for branches/UKMO/dev_r5518_obs_oper_update_icethick/NEMOGCM/EXTERNAL/AGRIF/LIB/dependfile.c – NEMO

Ignore:
Timestamp:
2018-07-23T11:33:03+02:00 (6 years ago)
Author:
emmafiedler
Message:

Merge with GO6 FOAMv14 package branch r9288

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r5518_obs_oper_update_icethick/NEMOGCM/EXTERNAL/AGRIF/LIB/dependfile.c

    r7960 r9987  
    7474  int out; 
    7575 
    76   /* We are looking for all the variable of the current filetoparse file      */ 
    77   /*    in the List_Global_Var                                                */ 
    78   parcours =List_Global_Var; 
     76  // We look in 'List_Global_Var' for all the variables of the current file to parse 
     77  parcours = List_Global_Var; 
    7978  out = 0; 
    8079  while (parcours && out == 0 ) 
     
    9695  { 
    9796     NbMailleXDefined = 1; 
    98      dependfileoutput = fopen(".dependnbxnby","w"); 
     97     sprintf(dependfilename, "%s/.dependnbxnby", work_dir); 
     98     dependfileoutput = fopen(dependfilename, "w"); 
     99 
    99100     fprintf(dependfileoutput,"%d\n",parcours->var->v_indicetabvars); 
    100101     IndicenbmaillesX = parcours->var->v_indicetabvars; 
     
    169170void Readthedependnbxnbyfile() 
    170171{ 
    171   FILE *dependfileoutput; 
    172  
    173   if ((dependfileoutput = fopen(".dependnbxnby","r"))!=NULL) 
    174   { 
    175      fscanf(dependfileoutput,"%d\n",&IndicenbmaillesX); 
    176      if ( dimprob > 1 ) fscanf(dependfileoutput,"%d\n",&IndicenbmaillesY); 
    177      if ( dimprob > 2 ) fscanf(dependfileoutput,"%d\n",&IndicenbmaillesZ); 
    178      fclose(dependfileoutput); 
    179   } 
     172    FILE *dependfileoutput; 
     173 
     174    sprintf(dependfilename, "%s/.dependnbxnby", work_dir); 
     175    if ((dependfileoutput = fopen(dependfilename, "r"))!=NULL) 
     176    { 
     177        fscanf(dependfileoutput,"%d\n",&IndicenbmaillesX); 
     178        if ( dimprob > 1 ) fscanf(dependfileoutput,"%d\n",&IndicenbmaillesY); 
     179        if ( dimprob > 2 ) fscanf(dependfileoutput,"%d\n",&IndicenbmaillesZ); 
     180        fclose(dependfileoutput); 
     181    } 
    180182} 
    181183 
     
    192194/*                                                                            */ 
    193195/******************************************************************************/ 
    194 void Writethedependlistofmoduleused(char *NameTampon ) 
     196void Writethedependlistofmoduleused(const char *NameTampon ) 
     197{ 
     198    FILE *dependfileoutput; 
     199    listusemodule *parcours; 
     200    char lowername[LONG_VNAME]; 
     201 
     202    if ( ! List_NameOfModuleUsed ) return; 
     203 
     204    convert2lower(lowername, NameTampon); 
     205    sprintf(dependfilename, "%s/.depend_use%s", work_dir, lowername); 
     206    dependfileoutput = fopen(dependfilename, "w"); 
     207 
     208    parcours = List_NameOfModuleUsed; 
     209    while (parcours) 
     210    { 
     211    if ( !strcasecmp(lowername,parcours->u_modulename) && 
     212         !strcasecmp(parcours->u_cursubroutine,"") ) 
     213    { 
     214        // We look in 'List_NameOfModuleUsed' for all the variables of the current file to parse 
     215        fprintf(dependfileoutput,"%s\n",parcours->u_usemodule); 
     216    } 
     217    parcours = parcours->suiv; 
     218    } 
     219    fclose(dependfileoutput); 
     220} 
     221 
     222/******************************************************************************/ 
     223/*                    Readthedependlistofmoduleused                           */ 
     224/******************************************************************************/ 
     225/* This subroutine is used to create the .dependuse<module>                   */ 
     226/******************************************************************************/ 
     227/*                                                                            */ 
     228/*               .dependuse<name>                                             */ 
     229/*                                                                            */ 
     230/*               mod1                                                         */ 
     231/*               mod2                                                         */ 
     232/*                                                                            */ 
     233/******************************************************************************/ 
     234void Readthedependlistofmoduleused(const char *NameTampon) 
    195235{ 
    196236  FILE *dependfileoutput; 
    197237  listusemodule *parcours; 
    198   char ligne[LONG_C]; 
    199  
    200  
    201   if ( List_NameOfModuleUsed ) 
    202   { 
    203      convert2lower(NameTampon); 
    204      sprintf(ligne,".dependuse%s",NameTampon); 
    205      dependfileoutput = fopen(ligne,"w"); 
    206      /*                                                                       */ 
    207      parcours = List_NameOfModuleUsed; 
     238  char lowername[LONG_VNAME]; 
     239 
     240  tmpuselocallist = (listusemodule *)NULL; 
     241 
     242  convert2lower(lowername, NameTampon); 
     243  sprintf(dependfilename, "%s/.depend_use%s", work_dir, lowername); 
     244 
     245  if ((dependfileoutput = fopen(dependfilename, "r"))!=NULL) 
     246  { 
     247    /* if the file exist we should verify that this file has changed          */ 
     248      while (!feof(dependfileoutput)) 
     249      { 
     250         parcours=(listusemodule *)calloc(1,sizeof(listusemodule)); 
     251         fscanf(dependfileoutput,"%s\n",parcours->u_usemodule); 
     252 
     253         parcours->suiv = tmpuselocallist; 
     254         tmpuselocallist = parcours; 
     255 
     256         parcours = NULL; 
     257      } 
     258      fclose(dependfileoutput); 
     259  } 
     260} 
     261 
     262 
     263/******************************************************************************/ 
     264/*                        WritedependParameterList                            */ 
     265/******************************************************************************/ 
     266/* This subroutine is used to create the .dependparameter<name>               */ 
     267/******************************************************************************/ 
     268/*                                                                            */ 
     269/*               .dependparameter<name>                                       */ 
     270/*                                                                            */ 
     271/*               mod1                                                         */ 
     272/*               mod2                                                         */ 
     273/*                                                                            */ 
     274/******************************************************************************/ 
     275void WritedependParameterList(const char *NameTampon ) 
     276{ 
     277  FILE *dependfileoutput; 
     278  listvar *parcours; 
     279  char lowername[LONG_VNAME]; 
     280 
     281  if ( List_GlobalParameter_Var ) 
     282  { 
     283     convert2lower(lowername, NameTampon); 
     284     sprintf(dependfilename, "%s/.depend_paramater_%s", work_dir, lowername); 
     285 
     286     dependfileoutput = fopen(dependfilename, "w"); 
     287     parcours = List_GlobalParameter_Var; 
    208288     while (parcours) 
    209289     { 
    210         if ( !strcasecmp(NameTampon,parcours->u_modulename) && 
    211              !strcasecmp(parcours->u_cursubroutine,"") 
    212            ) 
    213         { 
    214            /* We are looking for all the variable of the current              */ 
    215            /*    filetoparse file in the List_Global_Var                      */ 
    216            fprintf(dependfileoutput,"%s\n",parcours->u_usemodule); 
     290        if ( !strcasecmp(lowername, parcours->var->v_modulename) ) 
     291        { 
     292           fprintf(dependfileoutput,"%s\n",parcours->var->v_nomvar); 
     293           fprintf(dependfileoutput,"%s\n",parcours->var->v_modulename); 
    217294        } 
    218295        parcours = parcours->suiv; 
     
    222299} 
    223300 
    224 /******************************************************************************/ 
    225 /*                    Readthedependlistofmoduleused                           */ 
    226 /******************************************************************************/ 
    227 /* This subroutine is used to create the .dependuse<module>                   */ 
    228 /******************************************************************************/ 
    229 /*                                                                            */ 
    230 /*               .dependuse<name>                                             */ 
     301 
     302/******************************************************************************/ 
     303/*                         ReaddependParameterList                            */ 
     304/******************************************************************************/ 
     305/* This subroutine is used to create the .dependparameter<name>               */ 
     306/******************************************************************************/ 
     307/*                                                                            */ 
     308/*               .dependparameter<name>                                       */ 
    231309/*                                                                            */ 
    232310/*               mod1                                                         */ 
     
    234312/*                                                                            */ 
    235313/******************************************************************************/ 
    236 void Readthedependlistofmoduleused(char *NameTampon) 
     314listparameter *ReaddependParameterList(const char *NameTampon,listparameter *listout) 
    237315{ 
    238316  FILE *dependfileoutput; 
    239   listusemodule *parcours; 
    240   char ligne[LONG_C]; 
    241  
    242   convert2lower(NameTampon); 
    243   sprintf(ligne,".dependuse%s",NameTampon); 
    244  
    245   tmpuselocallist = (listusemodule *)NULL; 
    246   if ((dependfileoutput = fopen(ligne,"r"))==NULL) 
    247   { 
    248   } 
    249   else 
     317  listparameter *parcours; 
     318  char lowername[LONG_VNAME]; 
     319 
     320  convert2lower(lowername, NameTampon); 
     321  sprintf(dependfilename, "%s/.depend_paramater_%s", work_dir, lowername); 
     322 
     323  if ((dependfileoutput = fopen(dependfilename,"r"))!=NULL) 
    250324  { 
    251325    /* if the file exist we should verify that this file has changed          */ 
    252326      while (!feof(dependfileoutput)) 
    253327      { 
    254          parcours=(listusemodule *)malloc(sizeof(listusemodule)); 
    255          fscanf(dependfileoutput,"%s\n",parcours->u_usemodule); 
    256  
    257          parcours->suiv = tmpuselocallist; 
    258          tmpuselocallist = parcours; 
    259  
    260          parcours = NULL; 
    261       } 
    262       fclose(dependfileoutput); 
    263   } 
    264 } 
    265  
    266  
    267 /******************************************************************************/ 
    268 /*                        WritedependParameterList                            */ 
    269 /******************************************************************************/ 
    270 /* This subroutine is used to create the .dependparameter<name>               */ 
    271 /******************************************************************************/ 
    272 /*                                                                            */ 
    273 /*               .dependparameter<name>                                       */ 
    274 /*                                                                            */ 
    275 /*               mod1                                                         */ 
    276 /*               mod2                                                         */ 
    277 /*                                                                            */ 
    278 /******************************************************************************/ 
    279 void WritedependParameterList(char *NameTampon ) 
    280 { 
    281   FILE *dependfileoutput; 
    282   listvar *parcours; 
    283   char ligne[LONG_C]; 
    284  
    285   if ( List_GlobalParameter_Var ) 
    286   { 
    287      convert2lower(NameTampon); 
    288      sprintf(ligne,".dependparameter%s",NameTampon); 
    289      dependfileoutput = fopen(ligne,"w"); 
    290      /*                                                                       */ 
    291      parcours = List_GlobalParameter_Var; 
    292      while (parcours) 
    293      { 
    294         if ( !strcasecmp(NameTampon,parcours->var->v_modulename) ) 
    295         { 
    296            fprintf(dependfileoutput,"%s\n",parcours->var->v_nomvar); 
    297            fprintf(dependfileoutput,"%s\n",parcours->var->v_modulename); 
    298         } 
    299         parcours = parcours->suiv; 
    300      } 
    301      fclose(dependfileoutput); 
    302   } 
    303 } 
    304  
    305  
    306 /******************************************************************************/ 
    307 /*                         ReaddependParameterList                            */ 
    308 /******************************************************************************/ 
    309 /* This subroutine is used to create the .dependparameter<name>               */ 
    310 /******************************************************************************/ 
    311 /*                                                                            */ 
    312 /*               .dependparameter<name>                                       */ 
    313 /*                                                                            */ 
    314 /*               mod1                                                         */ 
    315 /*               mod2                                                         */ 
    316 /*                                                                            */ 
    317 /******************************************************************************/ 
    318 listparameter *ReaddependParameterList(char *NameTampon,listparameter *listout) 
    319 { 
    320   FILE *dependfileoutput; 
    321   listparameter *parcours; 
    322   char ligne[LONG_C]; 
    323  
    324   convert2lower(NameTampon); 
    325   sprintf(ligne,".dependparameter%s",NameTampon); 
    326  
    327   if ((dependfileoutput = fopen(ligne,"r"))==NULL) 
    328   { 
    329   } 
    330   else 
    331   { 
    332     /* if the file exist we should verify that this file has changed          */ 
    333       while (!feof(dependfileoutput)) 
    334       { 
    335          parcours=(listparameter *)malloc(sizeof(listparameter)); 
     328         parcours=(listparameter *)calloc(1,sizeof(listparameter)); 
    336329         fscanf(dependfileoutput,"%s\n",parcours->p_name); 
    337330         fscanf(dependfileoutput,"%s\n",parcours->p_modulename); 
     
    367360/*                                                                            */ 
    368361/******************************************************************************/ 
    369 void Writethedependfile(char *NameTampon, listvar *input ) 
     362void Writethedependfile(const char *NameTampon, listvar *input ) 
    370363{ 
    371364  FILE *dependfileoutput; 
    372365  listvar *parcours; 
    373366  listdim *dims; 
    374   char ligne[LONG_C]; 
    375   char listdimension[LONG_C]; 
    376   char curname[LONG_C]; 
     367  char ligne[LONG_M]; 
     368  char listdimension[LONG_M]; 
     369  char curname[LONG_M]; 
     370  char lowername[LONG_VNAME]; 
    377371  int out; 
    378372 
    379373  if ( input ) 
    380374  { 
    381   convert2lower(NameTampon); 
    382  
    383   sprintf(ligne,".depend%s",NameTampon); 
    384   dependfileoutput = fopen(ligne,"w"); 
    385   /* We are looking for all the variable of the current filetoparse file      */ 
    386   /*    in the input                                                          */ 
     375    convert2lower(lowername, NameTampon); 
     376    sprintf(dependfilename, "%s/.depend_%s", work_dir, lowername); 
     377 
     378  dependfileoutput = fopen(dependfilename,"w"); 
     379  // We look in 'input' for all the variables of the current file to parse 
    387380  parcours =input; 
    388381  out = 0; 
     
    390383  while (parcours && out == 0 ) 
    391384  { 
    392      if ( !strcasecmp(parcours->var->v_modulename,NameTampon) || 
    393           !strcasecmp(parcours->var->v_commonname,NameTampon) ) 
     385     if ( !strcasecmp(parcours->var->v_modulename, lowername) || 
     386          !strcasecmp(parcours->var->v_commonname, lowername) ) 
    394387     { 
    395388        /*                                                                    */ 
     
    402395           /********** TYPEVAR ************************************************/ 
    403396           fprintf(dependfileoutput,"%s\n",parcours->var->v_typevar); 
     397           /********** CATVAR ************************************************/ 
     398           fprintf(dependfileoutput,"%d\n",parcours->var->v_catvar); 
    404399           /********** NOMVAR *************************************************/ 
    405400           fprintf(dependfileoutput,"%s\n",parcours->var->v_nomvar); 
    406401           /********** DIMCHAR ************************************************/ 
    407            if ( strcasecmp(parcours->var->v_dimchar,"") ) 
     402           if ( strcasecmp(parcours->var->v_dimchar, "") ) 
    408403           { 
    409404              fprintf(dependfileoutput,"%s\n",parcours->var->v_dimchar); 
     
    479474           /********** PRIVATE *****************************************/ 
    480475           fprintf(dependfileoutput,"%d\n",parcours->var->v_PrivateDeclare); 
    481                
     476 
    482477           /********** INDICETABVARS ******************************************/ 
    483478           fprintf(dependfileoutput,"%d\n",parcours->var->v_indicetabvars); 
     
    497492                 dims = dims->suiv; 
    498493              } 
     494              Save_Length(listdimension,15); 
    499495              fprintf(dependfileoutput,"%s\n",listdimension); 
    500496           } 
     
    525521/*                                                                            */ 
    526522/******************************************************************************/ 
    527 listvar *Readthedependfile( char *NameTampon , listvar *listout) 
    528 { 
    529   char ligne[LONG_C]; 
     523listvar *Readthedependfile(const char *NameTampon , listvar *listout) 
     524{ 
    530525  FILE *dependfileoutput; 
    531526  listvar *parcours0; 
    532527  listvar *parcours; 
    533528  listvar *parcoursprec; 
    534   char nothing[LONG_C]; 
    535   int i; 
     529  char nothing[LONG_M]; 
     530  char lowername[LONG_VNAME]; 
     531  size_t i; 
    536532 
    537533  parcoursprec = (listvar *)NULL; 
    538534 
    539   convert2lower(NameTampon); 
    540   sprintf(ligne,".depend%s",NameTampon); 
    541   if ((dependfileoutput = fopen(ligne,"r"))==NULL) 
     535  convert2lower(lowername, NameTampon); 
     536  sprintf(dependfilename, "%s/.depend_%s", work_dir, lowername); 
     537 
     538  if ((dependfileoutput = fopen(dependfilename, "r"))==NULL) 
    542539  { 
    543540    /* if the file doesn't exist it means that it is the first time           */ 
     
    549546      while (!feof(dependfileoutput)) 
    550547      { 
    551          parcours=(listvar *)malloc(sizeof(listvar)); 
    552          parcours->var=(variable *)malloc(sizeof(variable)); 
     548         parcours=(listvar *)calloc(1,sizeof(listvar)); 
     549         parcours->var=(variable *)calloc(1,sizeof(variable)); 
    553550         /*                                                                   */ 
    554551         Init_Variable(parcours->var); 
     
    556553           /********** TYPEVAR ************************************************/ 
    557554         fscanf(dependfileoutput,"%s\n",parcours->var->v_typevar); 
     555           /********** CATVAR ************************************************/ 
     556         fscanf(dependfileoutput,"%d\n",&parcours->var->v_catvar); 
    558557           /********** NOMVAR *************************************************/ 
    559558         fscanf(dependfileoutput,"%s\n",parcours->var->v_nomvar); 
     
    578577           /********** MODULENAME *********************************************/ 
    579578         fscanf(dependfileoutput,"%s\n",parcours->var->v_modulename); 
    580           
    581          printf("MODULENAME = %s %s\n",parcours->var->v_nomvar,parcours->var->v_modulename); 
    582           
     579 
    583580         if ( !strcasecmp(parcours->var->v_modulename,"T") ) 
    584581         { 
    585582            strcpy(parcours->var->v_modulename,""); 
    586583         } 
    587           
     584 
    588585 
    589586           /********** NBDIM **************************************************/ 
     
    595592         if ( parcours->var->v_allocatable == 1 ) 
    596593         { 
    597             Add_Allocate_Var_1(parcours->var->v_nomvar, 
    598                                parcours->var->v_commonname); 
     594            Add_Allocate_Var_1(parcours->var->v_nomvar, parcours->var->v_commonname); 
    599595         } 
    600596           /********** TARGET ********************************************/ 
    601597         fscanf(dependfileoutput,"%d\n",&parcours->var->v_target); 
    602           
     598 
    603599           /********** POINTERDECLARE *****************************************/ 
    604600         fscanf(dependfileoutput,"%d\n",&parcours->var->v_pointerdeclare); 
     
    627623           /********** PRIVATE *****************************************/ 
    628624         fscanf(dependfileoutput,"%d\n",&parcours->var->v_PrivateDeclare); 
    629           
     625 
    630626           /********** INDICETABVARS ******************************************/ 
    631627         fscanf(dependfileoutput,"%d\n",&parcours->var->v_indicetabvars); 
     
    692688   if ( List_Subroutine_For_Alloc ) 
    693689   { 
    694       if ((dependfileoutput=fopen(".dependAllocAgrif","w"))!=NULL) 
     690      sprintf(dependfilename, "%s/.dependAllocAgrif", work_dir); 
     691 
     692      if ((dependfileoutput=fopen(dependfilename, "w"))!=NULL) 
    695693      { 
    696694         parcours = List_Subroutine_For_Alloc; 
     
    707705void Read_Subroutine_For_Alloc() 
    708706{ 
    709   FILE *dependfileoutput; 
    710   listnom *parcours; 
    711   listnom *ref; 
    712  
    713   ref = (listnom *)NULL; 
    714   if ((dependfileoutput=fopen(".dependAllocAgrif","r"))!=NULL) 
    715   { 
    716      List_Subroutine_For_Alloc = (listnom *)NULL; 
    717      while (!feof(dependfileoutput)) 
    718      { 
    719         parcours=(listnom *)malloc(sizeof(listnom)); 
    720         strcpy(parcours->o_nom,""); 
    721  
    722         fscanf(dependfileoutput,"%s\n",&parcours->o_nom); 
    723         parcours->suiv = NULL; 
    724  
    725         if ( !List_Subroutine_For_Alloc ) 
    726         { 
    727            List_Subroutine_For_Alloc = parcours; 
    728            ref = parcours; 
    729         } 
    730         else 
    731         { 
    732             ref->suiv = parcours; 
     707    FILE *dependfileoutput; 
     708    listnom *parcours; 
     709    listnom *ref; 
     710 
     711    ref = (listnom*) NULL; 
     712    sprintf(dependfilename, "%s/.dependAllocAgrif", work_dir); 
     713 
     714    if ( (dependfileoutput=fopen(dependfilename, "r")) != NULL ) 
     715    { 
     716        List_Subroutine_For_Alloc = (listnom*) NULL; 
     717        while ( !feof(dependfileoutput) ) 
     718        { 
     719            parcours = (listnom*) calloc(1,sizeof(listnom)); 
     720            strcpy(parcours->o_nom,""); 
     721 
     722            fscanf(dependfileoutput,"%s\n",parcours->o_nom); 
     723            parcours->suiv = NULL; 
     724 
     725            if ( !List_Subroutine_For_Alloc ) 
     726            { 
     727                List_Subroutine_For_Alloc = parcours; 
     728            } 
     729            else 
     730            { 
     731                ref->suiv = parcours; 
     732            } 
    733733            ref = parcours; 
    734734        } 
    735      } 
    736      fclose(dependfileoutput); 
    737   } 
     735        fclose(dependfileoutput); 
     736    } 
    738737} 
    739738 
     
    756755void Writethedependavailablefile() 
    757756{ 
    758   FILE *dependfileoutput; 
    759   listindice *parcours; 
    760  
    761   if ((dependfileoutput=fopen(".dependavailable","w"))!=NULL) 
    762   { 
    763      /* We are looking for all the indices of the Listofavailableindices      */ 
    764      parcours = Listofavailableindices; 
    765      while (parcours) 
    766      { 
    767         if ( parcours->i_indice != 0 ) 
    768         { 
    769            fprintf(dependfileoutput,"%d\n",parcours->i_indice); 
    770         } 
    771         parcours = parcours->suiv; 
    772      } 
    773      fclose(dependfileoutput); 
    774   } 
     757    FILE *dependfileoutput; 
     758    listindice *parcours; 
     759    int i; 
     760 
     761    sprintf(dependfilename, "%s/.dependavailable", work_dir); 
     762 
     763    if ((dependfileoutput=fopen(dependfilename, "w"))!=NULL) 
     764    { 
     765        /* We are looking for all the indices of the Listofavailableindices      */ 
     766        for (i=0;i<NB_CAT_VARIABLES;i++) 
     767        { 
     768            parcours = Listofavailableindices_glob[i]; 
     769            while (parcours) 
     770            { 
     771                if ( parcours->i_indice != 0 ) 
     772                { 
     773                    fprintf(dependfileoutput,"%d %d\n",i,parcours->i_indice); 
     774                } 
     775                parcours = parcours->suiv; 
     776            } 
     777        } 
     778        fclose(dependfileoutput); 
     779    } 
    775780} 
    776781 
     
    795800  FILE *dependfileoutput; 
    796801  listindice *parcours; 
    797  
    798   if ((dependfileoutput=fopen(".dependavailable","r"))!=NULL) 
     802  int current_cat; 
     803 
     804  sprintf(dependfilename, "%s/.dependavailable", work_dir); 
     805 
     806  if ((dependfileoutput=fopen(dependfilename, "r"))!=NULL) 
    799807  { 
    800808     /* We are looking for all the indices of the Listofavailableindices      */ 
    801      Listofavailableindices = (listindice *)NULL; 
     809     Listofavailableindices_glob = (listindice **) calloc(NB_CAT_VARIABLES,sizeof(listindice *)); 
    802810     while (!feof(dependfileoutput)) 
    803811     { 
    804         parcours=(listindice *)malloc(sizeof(listindice)); 
    805         fscanf(dependfileoutput,"%d\n",&parcours->i_indice); 
     812        parcours=(listindice *)calloc(1,sizeof(listindice)); 
     813        fscanf(dependfileoutput,"%d %d\n",&current_cat,&parcours->i_indice); 
    806814        if ( parcours->i_indice != 0 && parcours->i_indice < 10000000 ) 
    807815        { 
    808            parcours -> suiv = Listofavailableindices; 
    809            Listofavailableindices = parcours; 
     816           parcours -> suiv = Listofavailableindices_glob[current_cat]; 
     817           Listofavailableindices_glob[current_cat] = parcours; 
    810818        } 
    811819        else 
     
    820828 
    821829/******************************************************************************/ 
    822 /*                      Did_filetoparse_readed                                */ 
     830/*                       is_dependfile_created                                */ 
    823831/******************************************************************************/ 
    824832/* This subroutine is used to know if the .depend<NameTampon> exist           */ 
     
    827835/*                                                                            */ 
    828836/******************************************************************************/ 
    829 int Did_filetoparse_readed(char *NameTampon) 
     837int is_dependfile_created(const char *NameTampon) 
    830838{ 
    831839  FILE *dependfileoutput; 
    832   char ligne[LONG_C]; 
    833   int out; 
    834  
    835   convert2lower(NameTampon); 
    836   sprintf(ligne,".depend%s",NameTampon); 
    837   if ((dependfileoutput = fopen(ligne,"r"))==NULL) 
    838   { 
    839       out = 0; 
     840  char lowername[LONG_VNAME]; 
     841 
     842  convert2lower(lowername, NameTampon); 
     843  sprintf(dependfilename, "%s/.depend_%s", work_dir, lowername); 
     844 
     845  dependfileoutput = fopen(dependfilename, "r"); 
     846 
     847  if ( (dependfileoutput = fopen(dependfilename, "r")) != NULL ) 
     848  { 
     849    fclose(dependfileoutput); 
     850    return 1; 
    840851  } 
    841852  else 
    842   { 
    843       out = 1; 
    844       fclose(dependfileoutput); 
    845   } 
    846   return out; 
    847 } 
    848  
    849  
    850 /******************************************************************************/ 
    851 /*                      Did_module_common_treaded                             */ 
    852 /******************************************************************************/ 
    853 /* This subroutine is used to know if the .depend<NameTampon> exist           */ 
    854 /*    it means if the file has been ever parsed                               */ 
    855 /******************************************************************************/ 
    856 /*                                                                            */ 
    857 /******************************************************************************/ 
    858 int Did_module_common_treaded(char *NameTampon) 
    859 { 
    860   FILE *dependfileoutput; 
    861   char ligne[LONG_C]; 
    862   int out; 
    863  
    864   convert2lower(NameTampon); 
    865   sprintf(ligne,".depend%s",NameTampon); 
    866   if ((dependfileoutput = fopen(ligne,"r"))==NULL) 
    867   { 
    868       out = 0; 
    869   } 
    870   else 
    871   { 
    872       out = 1; 
    873       fclose(dependfileoutput); 
    874   } 
    875   return out; 
    876 } 
    877  
    878  
     853    return 0; 
     854} 
    879855 
    880856void Write_val_max() 
    881857{ 
    882   FILE *dependfileoutput; 
    883  
    884   if ((dependfileoutput=fopen(".dependvalmax","w"))!=NULL) 
    885   { 
    886      fprintf(dependfileoutput,"length_last\n"); 
    887      fprintf(dependfileoutput,"%d\n",length_last); 
    888      fprintf(dependfileoutput,"length_first\n"); 
    889      fprintf(dependfileoutput,"%d\n",length_first); 
    890      fprintf(dependfileoutput,"length_v_typevar\n"); 
    891      fprintf(dependfileoutput,"%d\n",length_v_typevar); 
    892      fprintf(dependfileoutput,"length_v_nomvar\n"); 
    893      fprintf(dependfileoutput,"%d\n",length_v_nomvar); 
    894      fprintf(dependfileoutput,"length_v_dimchar\n"); 
    895      fprintf(dependfileoutput,"%d\n",length_v_dimchar); 
    896      fprintf(dependfileoutput,"length_v_modulename\n"); 
    897      fprintf(dependfileoutput,"%d\n",length_v_modulename); 
    898      fprintf(dependfileoutput,"length_v_commonname\n"); 
    899      fprintf(dependfileoutput,"%d\n",length_v_commonname); 
    900      fprintf(dependfileoutput,"length_v_vallengspec\n"); 
    901      fprintf(dependfileoutput,"%d\n",length_v_vallengspec); 
    902      fprintf(dependfileoutput,"length_v_nameinttypename\n"); 
    903      fprintf(dependfileoutput,"%d\n",length_v_nameinttypename); 
    904      fprintf(dependfileoutput,"length_v_commoninfile\n"); 
    905      fprintf(dependfileoutput,"%d\n",length_v_commoninfile); 
    906      fprintf(dependfileoutput,"length_v_subroutinename\n"); 
    907      fprintf(dependfileoutput,"%d\n",length_v_subroutinename); 
    908      fprintf(dependfileoutput,"length_v_precision\n"); 
    909      fprintf(dependfileoutput,"%d\n",length_v_precision); 
    910      fprintf(dependfileoutput,"length_v_IntentSpec\n"); 
    911      fprintf(dependfileoutput,"%d\n",length_v_IntentSpec); 
    912      fprintf(dependfileoutput,"length_v_initialvalue\n"); 
    913      fprintf(dependfileoutput,"%d\n",length_v_initialvalue); 
    914      fprintf(dependfileoutput,"length_v_readedlistdimension\n"); 
    915      fprintf(dependfileoutput,"%d\n",length_v_readedlistdimension); 
    916      fprintf(dependfileoutput,"length_u_usemodule\n"); 
    917      fprintf(dependfileoutput,"%d\n",length_u_usemodule); 
    918      fprintf(dependfileoutput,"length_u_charusemodule\n"); 
    919      fprintf(dependfileoutput,"%d\n",length_u_charusemodule); 
    920      fprintf(dependfileoutput,"length_u_cursubroutine\n"); 
    921      fprintf(dependfileoutput,"%d\n",length_u_cursubroutine); 
    922      fprintf(dependfileoutput,"length_u_modulename\n"); 
    923      fprintf(dependfileoutput,"%d\n",length_u_modulename); 
    924      fprintf(dependfileoutput,"length_n_name\n"); 
    925      fprintf(dependfileoutput,"%d\n",length_n_name); 
    926      fprintf(dependfileoutput,"length_c_namevar\n"); 
    927      fprintf(dependfileoutput,"%d\n",length_c_namevar); 
    928      fprintf(dependfileoutput,"length_c_namepointedvar\n"); 
    929      fprintf(dependfileoutput,"%d\n",length_c_namepointedvar); 
    930      fprintf(dependfileoutput,"length_o_nom\n"); 
    931      fprintf(dependfileoutput,"%d\n",length_o_nom); 
    932      fprintf(dependfileoutput,"length_o_module\n"); 
    933      fprintf(dependfileoutput,"%d\n",length_o_module); 
    934      fprintf(dependfileoutput,"length_a_nomvar\n"); 
    935      fprintf(dependfileoutput,"%d\n",length_a_nomvar); 
    936      fprintf(dependfileoutput,"length_a_subroutine\n"); 
    937      fprintf(dependfileoutput,"%d\n",length_a_subroutine); 
    938      fprintf(dependfileoutput,"length_a_module\n"); 
    939      fprintf(dependfileoutput,"%d\n",length_a_module); 
    940      fprintf(dependfileoutput,"length_usemodule\n"); 
    941      fprintf(dependfileoutput,"%d\n",length_t_usemodule); 
    942      fprintf(dependfileoutput,"length_cursubroutine\n"); 
    943      fprintf(dependfileoutput,"%d\n",length_t_cursubroutine); 
    944      fprintf(dependfileoutput,"length_curfilename\n"); 
    945      fprintf(dependfileoutput,"%d\n",length_curfilename); 
    946      fprintf(dependfileoutput,"length_nomfileoutput\n"); 
    947      fprintf(dependfileoutput,"%d\n",length_nomfileoutput); 
    948      fprintf(dependfileoutput,"length_motparse\n"); 
    949      fprintf(dependfileoutput,"%d\n",length_motparse); 
    950      fprintf(dependfileoutput,"length_mainfile\n"); 
    951      fprintf(dependfileoutput,"%d\n",length_mainfile); 
    952      fprintf(dependfileoutput,"length_nomdir\n"); 
    953      fprintf(dependfileoutput,"%d\n",length_nomdir); 
    954      fprintf(dependfileoutput,"length_commondirout\n"); 
    955      fprintf(dependfileoutput,"%d\n",length_commondirout); 
    956      fprintf(dependfileoutput,"length_commondirin\n"); 
    957      fprintf(dependfileoutput,"%d\n",length_commondirin); 
    958      fprintf(dependfileoutput,"length_filetoparse\n"); 
    959      fprintf(dependfileoutput,"%d\n",length_filetoparse); 
    960      fprintf(dependfileoutput,"length_curbuf\n"); 
    961      fprintf(dependfileoutput,"%d\n",length_curbuf); 
    962      fprintf(dependfileoutput,"length_toprintglob\n"); 
    963      fprintf(dependfileoutput,"%d\n",length_toprintglob); 
    964      fprintf(dependfileoutput,"Size_char0d\n"); 
    965      fprintf(dependfileoutput,"%d\n",value_char_size); 
    966      fprintf(dependfileoutput,"Size_char1d\n"); 
    967      fprintf(dependfileoutput,"%d\n",value_char_size1); 
    968      fprintf(dependfileoutput,"Size_char2d\n"); 
    969      fprintf(dependfileoutput,"%d\n",value_char_size2); 
    970      fprintf(dependfileoutput,"Size_char3d\n"); 
    971      fprintf(dependfileoutput,"%d\n",value_char_size3); 
    972      fprintf(dependfileoutput,"length_tmpvargridname\n"); 
    973      fprintf(dependfileoutput,"%d\n",length_tmpvargridname); 
    974      fprintf(dependfileoutput,"length_ligne_Subloop\n"); 
    975      fprintf(dependfileoutput,"%d\n",length_ligne_Subloop); 
    976      fprintf(dependfileoutput,"length_lvargridname_toamr\n"); 
    977      fprintf(dependfileoutput,"%d\n",length_lvargridname_toamr); 
    978      fprintf(dependfileoutput,"length_toprint_toamr\n"); 
    979      fprintf(dependfileoutput,"%d\n",length_toprint_utilagrif); 
    980      fprintf(dependfileoutput,"length_toprinttmp_utilchar\n"); 
    981      fprintf(dependfileoutput,"%d\n",length_toprinttmp_utilchar); 
    982      fprintf(dependfileoutput,"length_ligne_writedecl\n"); 
    983      fprintf(dependfileoutput,"%d\n",length_ligne_writedecl); 
    984      fprintf(dependfileoutput,"length_newname_toamr\n"); 
    985      fprintf(dependfileoutput,"%d\n",length_newname_toamr); 
    986      fprintf(dependfileoutput,"length_newname_writedecl\n"); 
    987      fprintf(dependfileoutput,"%d\n",length_newname_writedecl); 
    988      fprintf(dependfileoutput,"length_ligne_toamr\n"); 
    989      fprintf(dependfileoutput,"%d\n",length_ligne_toamr); 
    990      fprintf(dependfileoutput,"length_tmpligne_writedecl\n"); 
    991      fprintf(dependfileoutput,"%d\n",length_tmpligne_writedecl); 
    992 /*     fprintf(dependfileoutput,"\n"); 
    993      fprintf(dependfileoutput,"%d\n",); 
    994      fprintf(dependfileoutput,"\n"); 
    995      fprintf(dependfileoutput,"%d\n",); 
    996      fprintf(dependfileoutput,"\n"); 
    997      fprintf(dependfileoutput,"%d\n",); 
    998      fprintf(dependfileoutput,"\n"); 
    999      fprintf(dependfileoutput,"%d\n",); 
    1000      fprintf(dependfileoutput,"\n"); 
    1001      fprintf(dependfileoutput,"%d\n",); 
    1002      fprintf(dependfileoutput,"\n"); 
    1003      fprintf(dependfileoutput,"%d\n",); 
    1004      fprintf(dependfileoutput,"\n"); 
    1005      fprintf(dependfileoutput,"%d\n",); 
    1006      fprintf(dependfileoutput,"\n"); 
    1007      fprintf(dependfileoutput,"%d\n",); 
    1008      fprintf(dependfileoutput,"\n"); 
    1009      fprintf(dependfileoutput,"%d\n",);*/ 
    1010  
    1011      fclose(dependfileoutput); 
    1012   } 
     858    FILE *dependfileoutput; 
     859 
     860    sprintf(dependfilename, "%s/.dependvalmax", work_dir); 
     861 
     862    if ((dependfileoutput=fopen(dependfilename, "w"))!=NULL) 
     863    { 
     864        fprintf(dependfileoutput,"length_last\n"); 
     865        fprintf(dependfileoutput,"%lu\n", length_last); 
     866        fprintf(dependfileoutput,"length_first\n"); 
     867        fprintf(dependfileoutput,"%lu\n", length_first); 
     868        fprintf(dependfileoutput,"length_v_vallengspec\n"); 
     869        fprintf(dependfileoutput,"%lu\n", length_v_vallengspec); 
     870        fprintf(dependfileoutput,"length_v_commoninfile\n"); 
     871        fprintf(dependfileoutput,"%lu\n", length_v_commoninfile); 
     872        fprintf(dependfileoutput,"length_v_precision\n"); 
     873        fprintf(dependfileoutput,"%lu\n", length_v_precision); 
     874        fprintf(dependfileoutput,"length_v_IntentSpec\n"); 
     875        fprintf(dependfileoutput,"%lu\n", length_v_IntentSpec); 
     876        fprintf(dependfileoutput,"length_v_initialvalue\n"); 
     877        fprintf(dependfileoutput,"%lu\n", length_v_initialvalue); 
     878        fprintf(dependfileoutput,"length_v_readedlistdimension\n"); 
     879        fprintf(dependfileoutput,"%lu\n", length_v_readedlistdimension); 
     880        fprintf(dependfileoutput,"length_a_nomvar\n"); 
     881        fprintf(dependfileoutput,"%lu\n", length_a_nomvar); 
     882        fprintf(dependfileoutput,"length_toprintglob\n"); 
     883        fprintf(dependfileoutput,"%lu\n", length_toprintglob); 
     884        fprintf(dependfileoutput,"Size_char0d\n"); 
     885        fprintf(dependfileoutput,"%d\n",value_char_size); 
     886        fprintf(dependfileoutput,"Size_char1d\n"); 
     887        fprintf(dependfileoutput,"%d\n",value_char_size1); 
     888        fprintf(dependfileoutput,"Size_char2d\n"); 
     889        fprintf(dependfileoutput,"%d\n",value_char_size2); 
     890        fprintf(dependfileoutput,"Size_char3d\n"); 
     891        fprintf(dependfileoutput,"%d\n",value_char_size3); 
     892        fprintf(dependfileoutput,"length_tmpvargridname\n"); 
     893        fprintf(dependfileoutput,"%lu\n", length_tmpvargridname); 
     894        fprintf(dependfileoutput,"length_ligne_Subloop\n"); 
     895        fprintf(dependfileoutput,"%lu\n", length_ligne_Subloop); 
     896        fprintf(dependfileoutput,"length_toprint_toamr\n"); 
     897        fprintf(dependfileoutput,"%lu\n", length_toprint_utilagrif); 
     898        fprintf(dependfileoutput,"length_toprinttmp_utilchar\n"); 
     899        fprintf(dependfileoutput,"%lu\n", length_toprinttmp_utilchar); 
     900        fprintf(dependfileoutput,"length_ligne_writedecl\n"); 
     901        fprintf(dependfileoutput,"%lu\n", length_ligne_writedecl); 
     902        fprintf(dependfileoutput,"length_newname_toamr\n"); 
     903        fprintf(dependfileoutput,"%lu\n", length_newname_toamr); 
     904        fprintf(dependfileoutput,"length_newname_writedecl\n"); 
     905        fprintf(dependfileoutput,"%lu\n", length_newname_writedecl); 
     906        fprintf(dependfileoutput,"length_ligne_toamr\n"); 
     907        fprintf(dependfileoutput,"%lu\n", length_ligne_toamr); 
     908        fprintf(dependfileoutput,"length_tmpligne_writedecl\n"); 
     909        fprintf(dependfileoutput,"%lu\n", length_tmpligne_writedecl); 
     910 
     911        fclose(dependfileoutput); 
     912    } 
    1013913} 
    1014914 
     
    1016916void Read_val_max() 
    1017917{ 
    1018   char nothing[LONG_C]; 
    1019   FILE *dependfileoutput; 
    1020  
    1021   if ((dependfileoutput=fopen(".dependvalmax","r"))!=NULL) 
    1022   { 
    1023      fscanf(dependfileoutput,"%s\n",nothing); 
    1024      fscanf(dependfileoutput,"%d\n",&length_last); 
    1025      fscanf(dependfileoutput,"%s\n",nothing); 
    1026      fscanf(dependfileoutput,"%d\n",&length_first); 
    1027      fscanf(dependfileoutput,"%s\n",nothing); 
    1028      fscanf(dependfileoutput,"%d\n",&length_v_typevar); 
    1029      fscanf(dependfileoutput,"%s\n",nothing); 
    1030      fscanf(dependfileoutput,"%d\n",&length_v_nomvar); 
    1031      fscanf(dependfileoutput,"%s\n",nothing); 
    1032      fscanf(dependfileoutput,"%d\n",&length_v_dimchar); 
    1033      fscanf(dependfileoutput,"%s\n",nothing); 
    1034      fscanf(dependfileoutput,"%d\n",&length_v_modulename); 
    1035      fscanf(dependfileoutput,"%s\n",nothing); 
    1036      fscanf(dependfileoutput,"%d\n",&length_v_commonname); 
    1037      fscanf(dependfileoutput,"%s\n",nothing); 
    1038      fscanf(dependfileoutput,"%d\n",&length_v_vallengspec); 
    1039      fscanf(dependfileoutput,"%s\n",nothing); 
    1040      fscanf(dependfileoutput,"%d\n",&length_v_nameinttypename); 
    1041      fscanf(dependfileoutput,"%s\n",nothing); 
    1042      fscanf(dependfileoutput,"%d\n",&length_v_commoninfile); 
    1043      fscanf(dependfileoutput,"%s\n",nothing); 
    1044      fscanf(dependfileoutput,"%d\n",&length_v_subroutinename); 
    1045      fscanf(dependfileoutput,"%s\n",nothing); 
    1046      fscanf(dependfileoutput,"%d\n",&length_v_precision); 
    1047      fscanf(dependfileoutput,"%s\n",nothing); 
    1048      fscanf(dependfileoutput,"%d\n",&length_v_IntentSpec); 
    1049      fscanf(dependfileoutput,"%s\n",nothing); 
    1050      fscanf(dependfileoutput,"%d\n",&length_v_initialvalue); 
    1051      fscanf(dependfileoutput,"%s\n",nothing); 
    1052      fscanf(dependfileoutput,"%d\n",&length_v_readedlistdimension); 
    1053      fscanf(dependfileoutput,"%s\n",nothing); 
    1054      fscanf(dependfileoutput,"%d\n",&length_u_usemodule); 
    1055      fscanf(dependfileoutput,"%s\n",nothing); 
    1056      fscanf(dependfileoutput,"%d\n",&length_u_charusemodule); 
    1057      fscanf(dependfileoutput,"%s\n",nothing); 
    1058      fscanf(dependfileoutput,"%d\n",&length_u_cursubroutine); 
    1059      fscanf(dependfileoutput,"%s\n",nothing); 
    1060      fscanf(dependfileoutput,"%d\n",&length_u_modulename); 
    1061      fscanf(dependfileoutput,"%s\n",nothing); 
    1062      fscanf(dependfileoutput,"%d\n",&length_n_name); 
    1063      fscanf(dependfileoutput,"%s\n",nothing); 
    1064      fscanf(dependfileoutput,"%d\n",&length_c_namevar); 
    1065      fscanf(dependfileoutput,"%s\n",nothing); 
    1066      fscanf(dependfileoutput,"%d\n",&length_c_namepointedvar); 
    1067      fscanf(dependfileoutput,"%s\n",nothing); 
    1068      fscanf(dependfileoutput,"%d\n",&length_o_nom); 
    1069      fscanf(dependfileoutput,"%s\n",nothing); 
    1070      fscanf(dependfileoutput,"%d\n",&length_o_module); 
    1071      fscanf(dependfileoutput,"%s\n",nothing); 
    1072      fscanf(dependfileoutput,"%d\n",&length_a_nomvar); 
    1073      fscanf(dependfileoutput,"%s\n",nothing); 
    1074      fscanf(dependfileoutput,"%d\n",&length_a_subroutine); 
    1075      fscanf(dependfileoutput,"%s\n",nothing); 
    1076      fscanf(dependfileoutput,"%d\n",&length_a_module); 
    1077      fscanf(dependfileoutput,"%s\n",nothing); 
    1078      fscanf(dependfileoutput,"%d\n",&length_t_usemodule); 
    1079      fscanf(dependfileoutput,"%s\n",nothing); 
    1080      fscanf(dependfileoutput,"%d\n",&length_t_cursubroutine); 
    1081      fscanf(dependfileoutput,"%s\n",nothing); 
    1082      fscanf(dependfileoutput,"%d\n",&length_curfilename); 
    1083      fscanf(dependfileoutput,"%s\n",nothing); 
    1084      fscanf(dependfileoutput,"%d\n",&length_nomfileoutput); 
    1085      fscanf(dependfileoutput,"%s\n",nothing); 
    1086      fscanf(dependfileoutput,"%d\n",&length_motparse); 
    1087      fscanf(dependfileoutput,"%s\n",nothing); 
    1088      fscanf(dependfileoutput,"%d\n",&length_mainfile); 
    1089      fscanf(dependfileoutput,"%s\n",nothing); 
    1090      fscanf(dependfileoutput,"%d\n",&length_nomdir); 
    1091      fscanf(dependfileoutput,"%s\n",nothing); 
    1092      fscanf(dependfileoutput,"%d\n",&length_commondirout); 
    1093      fscanf(dependfileoutput,"%s\n",nothing); 
    1094      fscanf(dependfileoutput,"%d\n",&length_commondirin); 
    1095      fscanf(dependfileoutput,"%s\n",nothing); 
    1096      fscanf(dependfileoutput,"%d\n",&length_filetoparse); 
    1097      fscanf(dependfileoutput,"%s\n",nothing); 
    1098      fscanf(dependfileoutput,"%d\n",&length_curbuf); 
    1099      fscanf(dependfileoutput,"%s\n",nothing); 
    1100      fscanf(dependfileoutput,"%d\n",&length_toprintglob); 
    1101      fscanf(dependfileoutput,"%s\n",nothing); 
    1102      fscanf(dependfileoutput,"%d\n",&value_char_size); 
    1103      fscanf(dependfileoutput,"%s\n",nothing); 
    1104      fscanf(dependfileoutput,"%d\n",&value_char_size1); 
    1105      fscanf(dependfileoutput,"%s\n",nothing); 
    1106      fscanf(dependfileoutput,"%d\n",&value_char_size2); 
    1107      fscanf(dependfileoutput,"%s\n",nothing); 
    1108      fscanf(dependfileoutput,"%d\n",&value_char_size3); 
    1109      fscanf(dependfileoutput,"%s\n",nothing); 
    1110      fscanf(dependfileoutput,"%d\n",&length_tmpvargridname); 
    1111      fscanf(dependfileoutput,"%s\n",nothing); 
    1112      fscanf(dependfileoutput,"%d\n",&length_ligne_Subloop); 
    1113      fscanf(dependfileoutput,"%s\n",nothing); 
    1114      fscanf(dependfileoutput,"%d\n",&length_lvargridname_toamr); 
    1115      fscanf(dependfileoutput,"%s\n",nothing); 
    1116      fscanf(dependfileoutput,"%d\n",&length_toprint_utilagrif); 
    1117      fscanf(dependfileoutput,"%s\n",nothing); 
    1118      fscanf(dependfileoutput,"%d\n",&length_toprinttmp_utilchar); 
    1119      fscanf(dependfileoutput,"%s\n",nothing); 
    1120      fscanf(dependfileoutput,"%d\n",&length_ligne_writedecl); 
    1121      fscanf(dependfileoutput,"%s\n",nothing); 
    1122      fscanf(dependfileoutput,"%d\n",&length_newname_toamr); 
    1123      fscanf(dependfileoutput,"%s\n",nothing); 
    1124      fscanf(dependfileoutput,"%d\n",&length_newname_writedecl); 
    1125      fscanf(dependfileoutput,"%s\n",nothing); 
    1126      fscanf(dependfileoutput,"%d\n",&length_ligne_toamr); 
    1127      fscanf(dependfileoutput,"%s\n",nothing); 
    1128      fscanf(dependfileoutput,"%d\n",&length_tmpligne_writedecl); 
    1129 /*     fscanf(dependfileoutput,"%s\n",nothing); 
    1130      fscanf(dependfileoutput,"%d\n",&); 
    1131      fscanf(dependfileoutput,"%s\n",nothing); 
    1132      fscanf(dependfileoutput,"%d\n",&); 
    1133      fscanf(dependfileoutput,"%s\n",nothing); 
    1134      fscanf(dependfileoutput,"%d\n",&); 
    1135      fscanf(dependfileoutput,"%s\n",nothing); 
    1136      fscanf(dependfileoutput,"%d\n",&); 
    1137      fscanf(dependfileoutput,"%s\n",nothing); 
    1138      fscanf(dependfileoutput,"%d\n",&); 
    1139      fscanf(dependfileoutput,"%s\n",nothing); 
    1140      fscanf(dependfileoutput,"%d\n",&); 
    1141      fscanf(dependfileoutput,"%s\n",nothing); 
    1142      fscanf(dependfileoutput,"%d\n",&); 
    1143      fscanf(dependfileoutput,"%s\n",nothing); 
    1144      fscanf(dependfileoutput,"%d\n",&); 
    1145      fscanf(dependfileoutput,"%s\n",nothing); 
    1146      fscanf(dependfileoutput,"%d\n",&);*/ 
    1147  
    1148      fclose(dependfileoutput); 
    1149   } 
    1150 } 
     918    char nothing[LONG_M]; 
     919    FILE *dependfileoutput; 
     920 
     921    sprintf(dependfilename, "%s/.dependvalmax", work_dir); 
     922 
     923    if ((dependfileoutput=fopen(".dependvalmax","r"))!=NULL) 
     924    { 
     925       fscanf(dependfileoutput,"%s\n",nothing); 
     926       fscanf(dependfileoutput,"%lu\n", &length_last); 
     927       fscanf(dependfileoutput,"%s\n",nothing); 
     928       fscanf(dependfileoutput,"%lu\n", &length_first); 
     929       fscanf(dependfileoutput,"%s\n",nothing); 
     930       fscanf(dependfileoutput,"%lu\n", &length_v_vallengspec); 
     931       fscanf(dependfileoutput,"%s\n",nothing); 
     932       fscanf(dependfileoutput,"%lu\n", &length_v_commoninfile); 
     933       fscanf(dependfileoutput,"%s\n",nothing); 
     934       fscanf(dependfileoutput,"%lu\n", &length_v_precision); 
     935       fscanf(dependfileoutput,"%s\n",nothing); 
     936       fscanf(dependfileoutput,"%lu\n", &length_v_IntentSpec); 
     937       fscanf(dependfileoutput,"%s\n",nothing); 
     938       fscanf(dependfileoutput,"%lu\n", &length_v_initialvalue); 
     939       fscanf(dependfileoutput,"%s\n",nothing); 
     940       fscanf(dependfileoutput,"%lu\n", &length_v_readedlistdimension); 
     941       fscanf(dependfileoutput,"%s\n",nothing); 
     942       fscanf(dependfileoutput,"%lu\n", &length_a_nomvar); 
     943       fscanf(dependfileoutput,"%s\n",nothing); 
     944       fscanf(dependfileoutput,"%lu\n", &length_toprintglob); 
     945       fscanf(dependfileoutput,"%s\n",nothing); 
     946       fscanf(dependfileoutput,"%d\n", &value_char_size); 
     947       fscanf(dependfileoutput,"%s\n", nothing); 
     948       fscanf(dependfileoutput,"%d\n", &value_char_size1); 
     949       fscanf(dependfileoutput,"%s\n", nothing); 
     950       fscanf(dependfileoutput,"%d\n", &value_char_size2); 
     951       fscanf(dependfileoutput,"%s\n", nothing); 
     952       fscanf(dependfileoutput,"%d\n", &value_char_size3); 
     953       fscanf(dependfileoutput,"%s\n",nothing); 
     954       fscanf(dependfileoutput,"%lu\n", &length_tmpvargridname); 
     955       fscanf(dependfileoutput,"%s\n",nothing); 
     956       fscanf(dependfileoutput,"%lu\n", &length_ligne_Subloop); 
     957       fscanf(dependfileoutput,"%s\n",nothing); 
     958       fscanf(dependfileoutput,"%lu\n", &length_toprint_utilagrif); 
     959       fscanf(dependfileoutput,"%s\n",nothing); 
     960       fscanf(dependfileoutput,"%lu\n", &length_toprinttmp_utilchar); 
     961       fscanf(dependfileoutput,"%s\n",nothing); 
     962       fscanf(dependfileoutput,"%lu\n", &length_ligne_writedecl); 
     963       fscanf(dependfileoutput,"%s\n",nothing); 
     964       fscanf(dependfileoutput,"%lu\n", &length_newname_toamr); 
     965       fscanf(dependfileoutput,"%s\n",nothing); 
     966       fscanf(dependfileoutput,"%lu\n", &length_newname_writedecl); 
     967       fscanf(dependfileoutput,"%s\n",nothing); 
     968       fscanf(dependfileoutput,"%lu\n", &length_ligne_toamr); 
     969       fscanf(dependfileoutput,"%s\n",nothing); 
     970       fscanf(dependfileoutput,"%lu\n", &length_tmpligne_writedecl); 
     971 
     972       fclose(dependfileoutput); 
     973    } 
     974} 
Note: See TracChangeset for help on using the changeset viewer.