blob: fed3745be8afe918a6025b98a4c9802a8746fd52 [file] [log] [blame]
Guido van Rossum87d5e701996-05-28 22:50:17 +00001/* -*- C -*- ***********************************************
2Copyright 1991-1995 by Stichting Mathematisch Centrum, Amsterdam,
3The Netherlands.
4
5 All Rights Reserved
6
7Permission to use, copy, modify, and distribute this software and its
8documentation for any purpose and without fee is hereby granted,
9provided that the above copyright notice appear in all copies and that
10both that copyright notice and this permission notice appear in
11supporting documentation, and that the names of Stichting Mathematisch
12Centrum or CWI not be used in advertising or publicity pertaining to
13distribution of the software without specific, written prior permission.
14
15STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO
16THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
17FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE
18FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
19WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
20ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
21OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
22
23******************************************************************/
24
25/* Module configuration */
26
27/* This file contains the table of built-in modules.
28 See init_builtin() in import.c. */
29
30#include "Python.h"
31
32extern void initarray();
33extern void initaudioop();
34extern void initbinascii();
35extern void initenvironment();
36extern void initimageop();
37extern void initmath();
38extern void initmd5();
39extern void initnew();
40extern void initnt();
41extern void initregex();
42extern void initrgbimg();
43extern void initrotor();
44extern void initsignal();
45extern void initsocket();
46extern void initsoundex();
47extern void initstrop();
48extern void initstruct();
49extern void inittime();
50
51/* -- ADDMODULE MARKER 1 -- */
52
53extern void PyMarshal_Init();
54extern void initimp();
55
56struct {
57 char *name;
58 void (*initfunc)();
59} inittab[] = {
60
61 {"array", initarray},
62#ifdef M_I386
63 {"audioop", initaudioop},
64#endif
65 {"binascii", initbinascii},
66 {"environment", initenvironment},
67 {"imageop", initimageop},
68 {"math", initmath},
69 {"md5", initmd5},
70 {"new", initnew},
71 {"nt", initnt}, /* Use the NT os functions, not posix */
72 {"regex", initregex},
73 {"rgbimg", initrgbimg},
74 {"rotor", initrotor},
75 {"signal", initsignal},
76#ifdef USE_SOCKET
77 {"socket", initsocket},
78#endif
79 {"soundex", initsoundex},
80 {"strop", initstrop},
81 {"struct", initstruct},
82 {"time", inittime},
83
84/* -- ADDMODULE MARKER 2 -- */
85
86 /* This module "lives in" with marshal.c */
87 {"marshal", PyMarshal_Init},
88
89 /* This lives it with import.c */
90 {"imp", initimp},
91
92 /* These entries are here for sys.builtin_module_names */
93 {"__main__", NULL},
94 {"__builtin__", NULL},
95 {"sys", NULL},
96
97 /* Sentinel */
98 {0, 0}
99};