BrentD has asked for the wisdom of the Perl Monks concerning the following question:

Trying to install Tk through CPAN with StrawberryPerl 5.32.0.1 and getting an error at the end. Tried both 32 & 64 bit versions and get the same error with both. Here's the output of the relevant lines:
"C:\Strawberry\perl\bin\perl.exe" -MExtUtils::Mksymlists \ -e "Mksymlists('NAME'=>\"Tk\", 'DLBASE' => 'Tk', 'DL_FUNCS' => { }, ' +FUNCLIST' => [], 'IMPORTS' => { }, 'DL_VARS' => []);" g++ Tk.def -o blib\arch\auto\Tk\Tk.xs.dll -mdll -s -L"C:\STRAWB~1\perl +\lib\CORE" -L"C:\STRAWB~1\c\lib" Tk.o chnGlue.o encGlue.o evtGlue.o o +bjGlue.o pTk\tkres.o tixGlue.o tkGlue.o tkGlue_f.o tkWin32Dll.o pTk/ +libpTk.a "C:\STRAWB~1\perl\lib\CORE\libperl532.a" "C:\STRAWB~1\c\i686 +-w64-mingw32\lib\libimm32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libc +omctl32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libcomdlg32.a" "C:\STR +AWB~1\c\i686-w64-mingw32\lib\libgdi32.a" "C:\STRAWB~1\c\i686-w64-ming +w32\lib\libcomctl32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libimm32.a +" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libmoldname.a" "C:\STRAWB~1\c\i +686-w64-mingw32\lib\libkernel32.a" "C:\STRAWB~1\c\i686-w64-mingw32\li +b\libuser32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libgdi32.a" "C:\ST +RAWB~1\c\i686-w64-mingw32\lib\libwinspool.a" "C:\STRAWB~1\c\i686-w64- +mingw32\lib\libcomdlg32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libadv +api32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libshell32.a" "C:\STRAWB +~1\c\i686-w64-mingw32\lib\libole32.a" "C:\STRAWB~1\c\i686-w64-mingw32 +\lib\liboleaut32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libnetapi32.a +" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libuuid.a" "C:\STRAWB~1\c\i686- +w64-mingw32\lib\libws2_32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libm +pr.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libwinmm.a" "C:\STRAWB~1\c\ +i686-w64-mingw32\lib\libversion.a" "C:\STRAWB~1\c\i686-w64-mingw32\li +b\libodbc32.a" "C:\STRAWB~1\c\i686-w64-mingw32\lib\libodbccp32.a" "C: +\STRAWB~1\c\i686-w64-mingw32\lib\libcomctl32.a" -Wl,--enable-auto-ima +ge-base C:/Strawberry/c/bin/../lib/gcc/i686-w64-mingw32/8.3.0/../../../../i686 +-w64-mingw32/bin/ld.exe: encGlue.o:encGlue.c:(.text+0x3f): undefined +reference to `MAX' C:/Strawberry/c/bin/../lib/gcc/i686-w64-mingw32/8.3.0/../../../../i686 +-w64-mingw32/bin/ld.exe: encGlue.o:encGlue.c:(.text+0x9f): undefined +reference to `MAX' C:/Strawberry/c/bin/../lib/gcc/i686-w64-mingw32/8.3.0/../../../../i686 +-w64-mingw32/bin/ld.exe: encGlue.o:encGlue.c:(.text+0x798): undefined + reference to `MAX' collect2.exe: error: ld returned 1 exit status gmake: *** [Makefile:619: blib\arch\auto\Tk\Tk.xs.dll] Error 1 SREZIC/Tk-804.035.tar.gz C:\STRAWB~1\c\bin\gmake.exe -- NOT OK Stopping: 'install' failed for 'Tk'. Failed during this command: SREZIC/Tk-804.035.tar.gz : make NO
  • Comment on StrawberryPerl 5.32.0.1 & Tk CPAN error: Undefined reference to MAX
  • Download Code

Replies are listed 'Best First'.
Re: StrawberryPerl 5.32.0.1 & Tk CPAN error: Undefined reference to MAX
by marto (Cardinal) on Sep 01, 2020 at 19:04 UTC

    Look at the most recent question before you posted this one. Super Search + reading for the win.

    Update: before installing a module, take the time to read open tickets/issues.

Re: StrawberryPerl 5.32.0.1 & Tk CPAN error: Undefined reference to MAX
by choroba (Cardinal) on Sep 15, 2020 at 09:15 UTC
    Crossposted to StackOverflow.

    It's considered polite to inform about crossposting, so that people not visiting both sites don't waste their time hacking a problem already solved at the other end of the internets.

    map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]