I am trying to setup LaTeX Workshop Extension for Visual Studio Code. I have The MacTeX-2018 Distribution that I installed using Homebrew cask. I cannot setup formatting. Errors lead me to the answer for the GitHub LaTeX-Workshop issue. First three commands worked just well for me:

sudo cpan Unicode::GCString
sudo cpan App::cpanminus
sudo cpan YAML::Tiny

Unfortunately, trying to execute the last one (I also tried sudo perl -MCPAN -e 'install "File::HomeDir"' gives and error and one unsatisfied dependency:

Vitaliis-MacBook-Pro:~ vitalii$ sudo cpan File::HomeDir
Reading '/Users/vitalii/.cpan/Metadata'
  Database was generated on Thu, 01 Nov 2018 08:29:03 GMT
Running install for module 'File::HomeDir'
Running make for R/RE/REHSACK/File-HomeDir-1.004.tar.gz
Checksum for /Users/vitalii/.cpan/sources/authors/id/R/RE/REHSACK/File-HomeDir-1.004.tar.gz ok

  CPAN.pm: Building R/RE/REHSACK/File-HomeDir-1.004.tar.gz

Checking if your kit is complete...
Looks good
Warning: prerequisite Mac::SystemDirectory 0.04 not found.
Writing Makefile for File::HomeDir
Writing MYMETA.yml and MYMETA.json
---- Unsatisfied dependencies detected during ----
----     REHSACK/File-HomeDir-1.004.tar.gz    ----
    Mac::SystemDirectory [requires]
Running make test
  Delayed until after prerequisites
Running make install
  Delayed until after prerequisites
Running install for module 'Mac::SystemDirectory'
Running make for E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz
Checksum for /Users/vitalii/.cpan/sources/authors/id/E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz ok

  CPAN.pm: Building E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz

HASCOMPILERuX_i/TEST5U_g.c:2:10: fatal error: 'EXTERN.h' file not found
#include "EXTERN.h"
         ^~~~~~~~~~
1 error generated.
Couldn't execute cc  -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -fstack-protector -Os "-I/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE"   -c HASCOMPILERuX_i/TEST5U_g.c -o HASCOMPILERuX_i/TEST5U_g.o: Inappropriate ioctl for device at Makefile.PL line 14.
Requires a compiler
Warning: No success on command[/usr/bin/perl Makefile.PL]
'YAML' not installed, will not store persistent state
  ETHER/Mac-SystemDirectory-0.10.tar.gz
  /usr/bin/perl Makefile.PL -- NOT OK
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install
Running make for R/RE/REHSACK/File-HomeDir-1.004.tar.gz
  Has already been unwrapped into directory /Users/vitalii/.cpan/build/File-HomeDir-1.004-KoTD4b

  CPAN.pm: Building R/RE/REHSACK/File-HomeDir-1.004.tar.gz

Warning: Prerequisite 'Mac::SystemDirectory => 0.04' for 'REHSACK/File-HomeDir-1.004.tar.gz' failed when processing 'ETHER/Mac-SystemDirectory-0.10.tar.gz' with 'writemakefile => NO '/usr/bin/perl Makefile.PL' returned status 6400'. Continuing, but chances to succeed are limited.
cp lib/File/HomeDir/FreeDesktop.pm blib/lib/File/HomeDir/FreeDesktop.pm
cp lib/File/HomeDir/Driver.pm blib/lib/File/HomeDir/Driver.pm
cp lib/File/HomeDir/Unix.pm blib/lib/File/HomeDir/Unix.pm
cp lib/File/HomeDir/Windows.pm blib/lib/File/HomeDir/Windows.pm
cp lib/File/HomeDir/MacOS9.pm blib/lib/File/HomeDir/MacOS9.pm
cp lib/File/HomeDir/Test.pm blib/lib/File/HomeDir/Test.pm
cp lib/File/HomeDir/Darwin.pm blib/lib/File/HomeDir/Darwin.pm
cp lib/File/HomeDir/Darwin/Carbon.pm blib/lib/File/HomeDir/Darwin/Carbon.pm
cp lib/File/HomeDir/Darwin/Cocoa.pm blib/lib/File/HomeDir/Darwin/Cocoa.pm
cp lib/File/HomeDir.pm blib/lib/File/HomeDir.pm
Manifying blib/man3/File::HomeDir::Darwin::Cocoa.3pm
Manifying blib/man3/File::HomeDir::MacOS9.3pm
Manifying blib/man3/File::HomeDir::Darwin.3pm
Manifying blib/man3/File::HomeDir.3pm
Manifying blib/man3/File::HomeDir::FreeDesktop.3pm
Manifying blib/man3/File::HomeDir::Unix.3pm
Manifying blib/man3/File::HomeDir::Darwin::Carbon.3pm
Manifying blib/man3/File::HomeDir::Test.3pm
Manifying blib/man3/File::HomeDir::Driver.3pm
Manifying blib/man3/File::HomeDir::Windows.3pm
  REHSACK/File-HomeDir-1.004.tar.gz
  /usr/bin/make -- OK
Running make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t xt/*.t
t/01_compile.t ........ 1/11 # Implemented by: File::HomeDir::Darwin
t/01_compile.t ........ ok     
t/02_main.t ........... # $<: 0 -- $(: 0 0 1 2 3 4 5 8 9 12 20 29 61 80 33 98 100 204 250 395 398 399 701
t/02_main.t ........... ok     
t/10_test.t ........... ok     
t/11_darwin.t ......... ok   
t/12_darwin_carbon.t .. skipped: Not running on 32-bit Darwin
t/13_darwin_cocoa.t ... skipped: Not running on Darwin with Cocoa API using Mac::SystemDirectory
t/20_empty_home.t ..... ok   
All tests successful.
Files=7, Tests=90,  0 wallclock secs ( 0.03 usr  0.01 sys +  0.40 cusr  0.08 csys =  0.52 CPU)
Result: PASS
  REHSACK/File-HomeDir-1.004.tar.gz
Tests succeeded but one dependency not OK (Mac::SystemDirectory)
  REHSACK/File-HomeDir-1.004.tar.gz
  [dependencies] -- NA
Running make install
  make test had returned bad status, won't install without force

I also tried to install the mentioned unsatisfied dependency. Again, I faced the following error trying to install Mac::SystemDirectory module using cpan:

Vitaliis-MacBook-Pro:~ vitalii$ sudo cpan Mac::SystemDirectory
Password:
Reading '/Users/vitalii/.cpan/Metadata'
  Database was generated on Thu, 01 Nov 2018 08:29:03 GMT
Running install for module 'Mac::SystemDirectory'
Running make for E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz
Checksum for /Users/vitalii/.cpan/sources/authors/id/E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz ok

  CPAN.pm: Building E/ET/ETHER/Mac-SystemDirectory-0.10.tar.gz

HASCOMPILERRgwh/TESTb9zf.c:2:10: fatal error: 'EXTERN.h' file not found
#include "EXTERN.h"
         ^~~~~~~~~~
1 error generated.
Couldn't execute cc  -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -fstack-protector -Os "-I/System/Library/Perl/5.18/darwin-thread-multi-2level/CORE"   -c HASCOMPILERRgwh/TESTb9zf.c -o HASCOMPILERRgwh/TESTb9zf.o: Inappropriate ioctl for device at Makefile.PL line 14.
Requires a compiler
Warning: No success on command[/usr/bin/perl Makefile.PL]
'YAML' not installed, will not store persistent state
  ETHER/Mac-SystemDirectory-0.10.tar.gz
  /usr/bin/perl Makefile.PL -- NOT OK
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install

My OS is MacOS Mojave 10.14.
I have xCode version 10.1 installed.
I have make installed:

Vitaliis-MacBook-Pro:~ vitalii$ make -v
GNU Make 3.81
Copyright (C) 2006  Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.

This program built for i386-apple-darwin11.3.0

I also have clang compiler

Vitaliis-MacBook-Pro:~ vitalii$ cc -v
Apple LLVM version 10.0.0 (clang-1000.10.44.2)
Target: x86_64-apple-darwin18.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

As I head some problems after updating to Mojave (could not use git), I already followed instructions in the answer for this post.
Could you help me with that?
Related Links:
https://rt.cpan.org/Public/Bug/Display.html?id=127028
https://github.com/James-Yu/LaTeX-Workshop/issues/376

migrated from stackoverflow.com Nov 9 at 5:28

This question came from our site for professional and enthusiast programmers.

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.