source: trunk/lang/tcl/src/Rappture_Init.c @ 1578

Last change on this file since 1578 was 1578, checked in by mmc, 15 years ago

Changed the new Rappture::split command to Rappture::slice. George found
problems in other Rappture:: routines that were accidentally using the
Rappture version of split, which does a slightly different thing.

File size: 2.2 KB
Line 
1/*
2 * ----------------------------------------------------------------------
3 *  Rappture_Init
4 *
5 *  This file contains the function that initializes all of the various
6 *  extensions in this package.
7 * ======================================================================
8 *  AUTHOR:  Derrick Kearney, Purdue University
9 *  Copyright (c) 2004-2006  Purdue Research Foundation
10 *
11 *  See the file "license.terms" for information on usage and
12 *  redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
13 * ======================================================================
14 */
15
16#include <tcl.h>
17
18#ifdef BUILD_rappture
19#undef TCL_STORAGE_CLASS
20#define TCL_STORAGE_CLASS DLLEXPORT
21#endif
22
23extern Tcl_AppInitProc Rappture_Init;
24extern Tcl_AppInitProc RpRlimit_Init;
25extern Tcl_AppInitProc RpRusage_Init;
26extern Tcl_AppInitProc RpSignal_Init;
27extern Tcl_AppInitProc RpSplit_Init;
28extern Tcl_AppInitProc RpSysinfo_Init;
29extern Tcl_AppInitProc RpDaemon_Init;
30
31#ifdef notdef
32extern Tcl_AppInitProc RpLibrary_Init;
33#endif
34extern Tcl_AppInitProc RpUnits_Init;
35extern Tcl_AppInitProc RpEncoding_Init;
36extern Tcl_AppInitProc RpUtils_Init;
37
38#ifdef BUILD_Rappture
39__declspec( dllexport )
40#endif
41int
42Rappture_Init( Tcl_Interp * interp)
43{
44#ifdef _WIN32
45    rpWinInitJob();
46#endif
47    if (Tcl_InitStubs(interp, "8.4", 0) == NULL) {
48        return TCL_ERROR;
49    }
50    if (Tcl_PkgProvide(interp, "Rappture", PACKAGE_VERSION) != TCL_OK) {
51        return TCL_ERROR;
52    }
53#ifdef notdef
54    if (RpLibrary_Init(interp) != TCL_OK) {
55        return TCL_ERROR;
56    }
57#endif
58    if (RpUnits_Init(interp) != TCL_OK) {
59        return TCL_ERROR;
60    }
61    if (RpEncoding_Init(interp) != TCL_OK) {
62        return TCL_ERROR;
63    }
64    if (RpUtils_Init(interp) != TCL_OK) {
65        return TCL_ERROR;
66    }
67    if (RpRlimit_Init(interp) != TCL_OK) {
68        return TCL_ERROR;
69    }
70    if (RpRusage_Init(interp) != TCL_OK) {
71        return TCL_ERROR;
72    }
73    if (RpSignal_Init(interp) != TCL_OK) {
74        return TCL_ERROR;
75    }
76    if (RpSlice_Init(interp) != TCL_OK) {
77        return TCL_ERROR;
78    }
79    if (RpSysinfo_Init(interp) != TCL_OK) {
80        return TCL_ERROR;
81    }
82    if (RpDaemon_Init(interp) != TCL_OK) {
83        return TCL_ERROR;
84    }
85    return TCL_OK;
86}
87
Note: See TracBrowser for help on using the repository browser.