Skip Menu |

This queue is for tickets about the Tcl CPAN distribution.

Report information
The Basics
Id: 132373
Status: open
Priority: 0/
Queue: Tcl

Owner: Nobody in particular
Requestors: SREZIC [...]
Cc: CAC [...]

Bug Information
Severity: (no value)
Broken in: 1.27
Fixed in: (no value)

Subject: Mac Mojave: your tclconfig ... does not provide tcl.h
Download (untitled) / with headers
text/plain 1.5k
Building on a Mac Mojave system is not possible, regardless with the system perl or a self-compiled one: ... $ perl5.30.1 Makefile.PL tclsh=/usr/bin/tclsh tcl_library=/System/Library/Frameworks/Tcl.framework/Versions/8.5/Resources/Scripts tcl_version=8.5 Using config data in /System/Library/Frameworks/Tcl.framework/Versions/8.5/ incpath -iwithsysroot /System/Library/Frameworks/Tcl.framework/Versions/8.5/Headers from your tclconfig /System/Library/Frameworks/Tcl.framework/Versions/8.5/ does not provide tcl.h at Makefile.PL line 36. ... However, if I remove the following condition from Makefile.PL: diff --git i/Makefile.PL w/Makefile.PL index 481d3aa..5ed2d07 100755 --- i/Makefile.PL +++ w/Makefile.PL @@ -157,10 +157,10 @@ if (defined($libpath) && defined($incpath)) { # # Tcl.xs:32:10: fatal error: tcl.h: No such file or directory if ($incpath) { - my @tclh = grep {-f "$_/tcl.h"} $incpath=~/-I(\S+)/g; - if ($#tclh==-1) { - _die "incpath $incpath from your tclconfig $tclconfig does not provide tcl.h" - } + #my @tclh = grep {-f "$_/tcl.h"} $incpath=~/-I(\S+)/g; + #if ($#tclh==-1) { + # _die "incpath $incpath from your tclconfig $tclconfig does not provide tcl.h" + #} } else {_die "can not figure out incpath from your tclconfig $tclconfig"} if ($usestubs) { ... then building & testing works OK.
I can reproduce this on 10.15 Catalina, but only after specifying --tclconfig and the new full path to (tclsh8.5 doesn't seem to automatically report existence of, which like tcl.h and some other files, must now be retrieved using the full SDK path, i.e. /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tcl.framework/Versions/8.5/ . Doing perl5.18 Makefile.PL --nousestubs works for me on Catalina; trying to use stubs currently crashes.)
The problem is partly because the from binary Tcl/Tk distributions (including OS-provided ones) tends to have hardcoded paths from the system which compiled it, and not the paths used when installed on another machine. On macOS, its included says to look in /System/Library/Frameworks/Tcl.framework/Versions/8.5/Headers for tcl.h, but this directory isn't present (anymore). I would think the path to tcl.h must then be specified manually:
but will still complains that it can't find tcl.h using just; I haven't figured out how to get it to ignore once it's been picked up (supposedly --library also needs to be specified, but I haven't figured out how to use it on Mac).
I had encountered a similar issue with MagicSplat on Windows: . However because of these sorts of issues, some Tcl/Tk developers advised against relying on other than for informational purposes: . Maybe should not trust/rely on as easily as it currently does.

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to