Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Syntactic Confectionery Delight
 
PerlMonks  

Re^2: "Tcl.xs:126: error: initializer element is not constant" while installing Tcl-1.02 in Strawberry Perl v5.10 on Windoze XP

by NateTut (Deacon)
on Jun 02, 2011 at 19:19 UTC ( #907868=note: print w/ replies, xml ) Need Help??


in reply to Re: "Tcl.xs:126: error: initializer element is not constant" while installing Tcl-1.02 in Strawberry Perl v5.10 on Windoze XP
in thread "Tcl.xs:126: error: initializer element is not constant" while installing Tcl-1.02 in Strawberry Perl v5.10 on Windoze XP

Yes, I have Tcl installed and tclsh is in the path. I am fiddling with Tcl.xs now to see if I can get it to compile (and hopefully not break the module too badly)


Comment on Re^2: "Tcl.xs:126: error: initializer element is not constant" while installing Tcl-1.02 in Strawberry Perl v5.10 on Windoze XP
Download Code
Re^3: "Tcl.xs:126: error: initializer element is not constant" while installing Tcl-1.02 in Strawberry Perl v5.10 on Windoze XP
by NateTut (Deacon) on Jun 02, 2011 at 20:00 UTC

    The offending line in Tcl.xs is:

    static int (* tclKit_AppInit)(Tcl_Interp *) = Tcl_Init;

    Tcl_Init is defined thusly:

    void Tcl_Init(interp) Tcl interp CODE: if (!initialized) { return; } if (tclKit_AppInit(interp) != TCL_OK) { croak(Tcl_GetStringResult(interp)); } Tcl_CreateObjCommand(interp, "::perl::Eval", Tcl_EvalInPerl, (ClientData) NULL, NULL);


    I'm not well versed in xs so I'm not sure what the issue is.

      The offending line in Tcl.xs is:

      Actuall, that line probably has nothing to do with it, really :)

      $ set path=%path%;C:\Tcl8.6\bin $ perl Makefile.PL tclsh=C:/Tcl8.6/bin/tclsh.exe tclConfig.sh=C:/Tcl8.6/lib/tclConfig.sh tcl_library=C:/Tcl8.6/lib/tcl8.6 tcl_version=8.6 LIBS = -LC:/Tcl8.6/lib -ltcl86 INC = -IC:/Tcl8.6/include DEFINE = Checking if your kit is complete... Looks good Note (probably harmless): No library found for -ltcl86 Writing Makefile for Tcl $ perl -pi.bak -e " s/\[.\$libpath/[\x22:nosearch \$libpath/ " Makef +ile.PL $ perl Makefile.PL tclsh=C:/Tcl8.6/bin/tclsh.exe tclConfig.sh=C:/Tcl8.6/lib/tclConfig.sh tcl_library=C:/Tcl8.6/lib/tcl8.6 tcl_version=8.6 LIBS = -LC:/Tcl8.6/lib -ltcl86 INC = -IC:/Tcl8.6/include DEFINE = Writing Makefile for Tcl $ dmake cp Tcl.pm blib\lib\Tcl.pm C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe C:\perl\5.12.2\li +b\ExtUtils\xsubpp -typemap C:\perl\5.12.2\lib\ExtUtils\typemap -type +map typemap Tcl.xs > Tcl.xsc && C:\perl\5.12.2\bin\MSWin32-x86-multi +-thread\perl.exe -MExtUtils::Command -e "mv" -- Tcl.xsc Tcl.c gcc -c -IC:/Tcl8.6/include -s -O2 -DWIN32 -DHAVE_DES_FCRYPT -DPER +L_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -fno-strict-aliasing -mms-bitf +ields -DPERL_MSVCRT_READFIX -s -O2 -DVERSION=\"1.02\" -DXS_ +VERSION=\"1.02\" "-IC:\perl\5.12.2\lib\MSWin32-x86-multi-thread\CORE +" Tcl.c Running Mkbootstrap for Tcl () C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe -MExtUtils::Comma +nd -e "chmod" -- 644 Tcl.bs C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe -MExtUtils::Mksym +lists \ -e "Mksymlists('NAME'=>\"Tcl\", 'DLBASE' => 'Tcl', 'DL_FUNCS' => +{ }, 'FUNCLIST' => [], 'IMPORTS' => { }, 'DL_VARS' => []);" dlltool --def Tcl.def --output-exp dll.exp g++ -o blib\arch\auto\Tcl\Tcl.dll -Wl,--base-file -Wl,dll.base -mdll - +s -L"c:\perl\5.12.2\lib\MSWin32-x86-multi-thread\CORE" -L"C:\MinGW\li +b" Tcl.o -Wl,--image-base,0x300f0000 C:\perl\5.12.2\lib\MSWin32-x86- +multi-thread\CORE\libperl512.a -LC:\Tcl8.6\lib -ltcl86 -lmoldname -lk +ernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 - +lole32 -loleaut32 -lnetapi32 -luuid -lws2_32 -lmpr -lwinmm -lversion +-lodbc32 -lodbccp32 -lcomctl32 dll.exp dlltool --def Tcl.def --base-file dll.base --output-exp dll.exp g++ -o blib\arch\auto\Tcl\Tcl.dll -mdll -s -L"c:\perl\5.12.2\lib\MSWin +32-x86-multi-thread\CORE" -L"C:\MinGW\lib" Tcl.o -Wl,--image-base,0x3 +00f0000 C:\perl\5.12.2\lib\MSWin32-x86-multi-thread\CORE\libperl512. +a -LC:\Tcl8.6\lib -ltcl86 -lmoldname -lkernel32 -luser32 -lgdi32 -lwi +nspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -lnetapi32 +-luuid -lws2_32 -lmpr -lwinmm -lversion -lodbc32 -lodbccp32 -lcomctl3 +2 dll.exp C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe -MExtUtils::Comma +nd -e "chmod" -- 755 blib\arch\auto\Tcl\Tcl.dll C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe -MExtUtils::Comma +nd -e "cp" -- Tcl.bs blib\arch\auto\Tcl\Tcl.bs C:\perl\5.12.2\bin\MSWin32-x86-multi-thread\perl.exe -MExtUtils::Comma +nd -e "chmod" -- 644 blib\arch\auto\Tcl\Tcl.bs
        I tried adding the ":nosearch" to the libpath, but I'm still getting the same error.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://907868]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (17)
As of 2014-04-24 09:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (565 votes), past polls