[BACK]Return to init.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / make

Annotation of src/usr.bin/make/init.c, Revision 1.4

1.1       espie       1: /*     $OpenPackages$ */
1.4     ! espie       2: /*     $OpenBSD: init.c,v 1.3 2006/05/06 10:52:34 espie Exp $ */
1.1       espie       3:
                      4: /*
                      5:  * Copyright (c) 2001 Marc Espie.
                      6:  *
                      7:  * Redistribution and use in source and binary forms, with or without
                      8:  * modification, are permitted provided that the following conditions
                      9:  * are met:
                     10:  * 1. Redistributions of source code must retain the above copyright
                     11:  *    notice, this list of conditions and the following disclaimer.
                     12:  * 2. Redistributions in binary form must reproduce the above copyright
                     13:  *    notice, this list of conditions and the following disclaimer in the
                     14:  *    documentation and/or other materials provided with the distribution.
                     15:  *
                     16:  * THIS SOFTWARE IS PROVIDED BY THE OPENBSD PROJECT AND CONTRIBUTORS
                     17:  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
                     18:  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
                     19:  * A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE OPENBSD
                     20:  * PROJECT OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
                     21:  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
                     22:  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
                     23:  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
                     24:  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
                     25:  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
                     26:  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
                     27:  */
                     28: #include <stdio.h>
                     29: #include "defines.h"
                     30: #include "config.h"
                     31: #include "init.h"
                     32: #include "timestamp.h"
                     33: #include "stats.h"
                     34: #include "dir.h"
                     35: #include "parse.h"
                     36: #include "var.h"
                     37: #include "arch.h"
                     38: #include "targ.h"
                     39: #include "suff.h"
                     40: #include "job.h"
                     41:
                     42: void
1.2       espie      43: Init(void)
1.1       espie      44: {
                     45:        Init_Timestamp();
                     46:        Init_Stats();
1.4     ! espie      47:        Targ_Init();
1.1       espie      48:        Dir_Init();             /* Initialize directory structures so -I flags
                     49:                                 * can be processed correctly */
                     50:        Parse_Init();           /* Need to initialize the paths of #include
                     51:                                 * directories */
                     52:        Var_Init();             /* As well as the lists of variables for
                     53:                                 * parsing arguments */
                     54:        Arch_Init();
                     55:        Suff_Init();
                     56: }
                     57:
1.3       espie      58: #ifdef CLEANUP
1.1       espie      59: void
1.2       espie      60: End(void)
1.1       espie      61: {
                     62:        Suff_End();
                     63:        Targ_End();
                     64:        Arch_End();
                     65:        Var_End();
                     66:        Parse_End();
                     67:        Dir_End();
                     68:        Job_End();
                     69: }
1.3       espie      70: #endif