X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;ds=sidebyside;f=make%2Futilities.pm;h=fdc4c4c7bdc1932e2bfc2452ab4854fb5e092be2;hb=3de8d7eee411e1164faa2a95015746304715bb18;hp=8b74b7e84d97bf4d1417a8f28cd0d24669f45aae;hpb=6a64a69fbc56b97f6285fbaad9f30fe58f211a88;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/make/utilities.pm b/make/utilities.pm index 8b74b7e84..fdc4c4c7b 100644 --- a/make/utilities.pm +++ b/make/utilities.pm @@ -358,6 +358,27 @@ sub translate_functions($$) $line =~ s/if\("(.+?)"\)//; } + if ($line =~ /if\(\!"(\w+)"\)/) + { + if (!exists $main::config{$1}) + { + $line = ""; + return ""; + } + else + { + if (defined $1) + { + if (exists ($main::config{$1}) and (($main::config{$1} =~ /y/i) or ($main::config{$1} eq "1"))) + { + $line = ""; + return ""; + } + } + } + + $line =~ s/if\(\!"(.+?)"\)//; + } while ($line =~ /exec\("(.+?)"\)/) { print "Executing program for module \e[1;32m$module\e[0m ... \e[1;32m$1\e[0m\n";