I'm using Mac Os High Sierra 10.13.06. I followed this guide https://discussions.apple.com/docs/DOC-12034, but couldn't make my perl script work. The browser just offers to download it. I also tried loading mod_cgi, but that didn't help.
sudo apachectl -M
shows that perl_module and cgi_module are loaded. Here is the error_log file:
[Tue Dec 10 11:02:01.586530 2019] [mpm_prefork:notice] [pid 77] AH00169: caught SIGTERM, shutting down
AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using MacBook-Air-Nikita.local. Set the 'ServerName' directive globally to suppress this message
[Tue Dec 10 11:02:01.912225 2019] [mpm_prefork:notice] [pid 504] AH00163: Apache/2.4.33 (Unix) PHP/7.1.16 mod_perl/2.0.9 Perl/v5.18.2 configured -- resuming normal operations
[Tue Dec 10 11:02:01.912331 2019] [core:notice] [pid 504] AH00094: Command line: '/usr/sbin/httpd -D FOREGROUND'
it is my config file in /etc/apache2/users
<Directory "/Users/nikitakirenkov/Sites/">
AddLanguage en .en
AddHandler perl-script .pl
PerlHandler ModPerl::Registry
Options Indexes MultiViews FollowSymLinks ExecCGI
AllowOverride None
Require host localhost
</Directory>
php scripts work well