From 80c6f0fdec23e53daebfcd8d331f1a44004b234e Mon Sep 17 00:00:00 2001 From: Brad King Date: Fri, 20 Dec 2002 16:15:13 -0500 Subject: ERR: Tcl_PkgProvide takes char*, so we cannot pass a string literal to it. --- Source/cmVTKWrapTclCommand.cxx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Source/cmVTKWrapTclCommand.cxx b/Source/cmVTKWrapTclCommand.cxx index 5760a83..b204170 100644 --- a/Source/cmVTKWrapTclCommand.cxx +++ b/Source/cmVTKWrapTclCommand.cxx @@ -336,10 +336,11 @@ bool cmVTKWrapTclCommand::WriteInit(const char *kitName, fprintf(fout," %sCommand);\n",classes[i].c_str()); } - fprintf(fout," Tcl_PkgProvide(interp, \"%s\", " - "VTK_TCL_TO_STRING(VTK_MAJOR_VERSION) \".\" " - "VTK_TCL_TO_STRING(VTK_MINOR_VERSION));\n", - m_LibraryName.c_str()); + fprintf(fout," char pkgName[]=\"%s\";\n", m_LibraryName.c_str()); + fprintf(fout," char pkgVers[]=VTK_TCL_TO_STRING(VTK_MAJOR_VERSION)" + " \".\" " + "VTK_TCL_TO_STRING(VTK_MINOR_VERSION);\n"); + fprintf(fout," Tcl_PkgProvide(interp, pkgName, pkgVers);\n"); fprintf(fout," return TCL_OK;\n}\n"); fclose(fout); -- cgit v0.12