OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [insight/] [gdb/] [gdbtcl/] [plugins/] [rhabout/] [rhabout.c] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 578 markom
/* Sample command procedure library for a plug-in. */
2
 
3
/* You have to include the Tcl headers, of course. */
4
#include <tcl.h>
5
 
6
/* Define the functions that implement your commands as required by Tcl */
7
 
8
int extra_text (ClientData clientData,
9
                Tcl_Interp *interp,
10
                int argc, char *argv[]);
11
 
12
/* Here you actually do whatever you want, like calling your target
13
   libraries etc.  Here we just return a string. */
14
 
15
int
16
extra_text (ClientData clientData,
17
                Tcl_Interp *interp,
18
                int argc, char *argv[])
19
{
20
  interp->result = "\nThis is a sample plug-in\n";
21
  return TCL_OK;
22
}
23
 
24
/* Initialization function required in Tcl libraries. */
25
 
26
int
27
Rhabout_Init (Tcl_Interp *interp)
28
{
29
  /* Register your command as a Tcl command with this interpreter. */
30
  Tcl_CreateCommand (interp, "rhabout_extra_text", extra_text,
31
                     (ClientData) NULL, (Tcl_CmdDeleteProc *) NULL);
32
 
33
  return TCL_OK;
34
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.