Displaying 1 result from an estimated 1 matches for "hello_cmd".
2011 Feb 08
1
Compiling a Tcl extension for an R package
...h/TclHelloWorld.zip
Can somebody help me to get this package to compile correctly under
Linux, Windows and OSX? (i.e. writing a configure script with the
correct compile commands).
Thanks,
Adrian Waddell
###########################
C Code (save as hello.c):
#include <tcl.h>
static int Hello_Cmd(ClientData cdata, Tcl_Interp *interp, int objc,
Tcl_Obj *const objv[]) {
Tcl_SetObjResult(interp, Tcl_NewStringObj("Hello, World!", -1));
return TCL_OK;
}
int DLLEXPORT Hello_Init(Tcl_Interp *interp) {
Tcl_CreateObjCommand(interp, "hello", Hello_Cmd, NULL, NULL);
return...