aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2020-01-03 11:58:49 +0100
committerSergey Poznyakoff <gray@gnu.org.ua>2020-01-03 14:26:49 +0100
commit9f9564bdb882d38a35d164336cb8f0d0da7eb251 (patch)
treeeaba1afcd3647f1e7f4901fcfc791a80d144ce6c
parentc59e5b99ae6c4f3e75284e1549ae72fcee0e2790 (diff)
downloadacmeman-9f9564bdb882d38a35d164336cb8f0d0da7eb251.tar.gz
acmeman-9f9564bdb882d38a35d164336cb8f0d0da7eb251.tar.bz2
Minor changes
* lib/App/Acmeman/Apache/Layout.pm: Add debugging * lib/App/Acmeman/Apache/Layout/debian.pm (post_setup): Enable mod_macro
-rw-r--r--lib/App/Acmeman/Apache/Layout.pm19
-rw-r--r--lib/App/Acmeman/Apache/Layout/debian.pm1
2 files changed, 13 insertions, 7 deletions
diff --git a/lib/App/Acmeman/Apache/Layout.pm b/lib/App/Acmeman/Apache/Layout.pm
index 39e40d5..7b9ec9d 100644
--- a/lib/App/Acmeman/Apache/Layout.pm
+++ b/lib/App/Acmeman/Apache/Layout.pm
@@ -30,11 +30,12 @@ sub modules {
eval {
no strict 'refs';
if (scalar %{ $modname.'::' }) {
- die "INCLUDED $modname";
- };
- require $_;
- my $prio = ${$modname.'::PRIORITY'} // 0;
- [ $prio, $modname ]
+ ()
+ } else {
+ require $_;
+ my $prio = ${$modname.'::PRIORITY'} // 0;
+ [ $prio, $modname ]
+ }
};
}
map { glob File::Spec->catfile($_, '*.pm') }
@@ -49,7 +50,8 @@ sub new {
my $class = shift;
if (@_ == 0) {
- # Autodetect
+ # Autodetect
+ debug(3, "detecting Apache configuration layout");
my $ap = new Apache::Defaults(server => $class->_find_httpd,
on_error => 'return');
if ($ap->status) {
@@ -57,6 +59,7 @@ sub new {
}
foreach my $mod ($class->modules) {
+ debug(3, "trying layout module $mod");
my $obj;
eval {
$obj = $mod->new($ap);
@@ -64,7 +67,9 @@ sub new {
if ($obj) {
return $obj;
}
-# print "A $mod: $@\n";
+ if ($@) {
+ debug(3, "layout module failed: $@");
+ }
}
if ($ap) {
diff --git a/lib/App/Acmeman/Apache/Layout/debian.pm b/lib/App/Acmeman/Apache/Layout/debian.pm
index 663883e..f123892 100644
--- a/lib/App/Acmeman/Apache/Layout/debian.pm
+++ b/lib/App/Acmeman/Apache/Layout/debian.pm
@@ -34,6 +34,7 @@ sub post_setup {
if ($dir eq '/etc/apache2/conf-available') {
chdir('/etc/apache2/conf-enabled');
symlink "../conf-available/$name", $name;
+ system("a2enmod macro");
}
}

Return to:

Send suggestions and report system problems to the System administrator.