Perl-скрипту не хватает пути для компилятора — какой компилятор?

Следуя руководству по установке openDDS, я пытаюсь запустить configure из командной строки, но получаю следующий вывод:

C:\Users\Supervisor\Desktop\opendds>C:\Users\Supervisor\Desktop\opendds\configure.cmd

Can't find a compiler, set PATH or run this script with the --compiler option.
For Microsoft Visual C++, run this script from the Visual Studio Command Prompt.
Stopped at configure line 336.

Эта ошибка относится к этому разделу кода в Perl-скрипте (как видно из номера строки):

if ($opts{'compiler'}) {
    my $standard = 0;
    for my $stdcomp (@{$platforminfo{$opts{'host'}}->{'compilers'}}) {
        $standard = 1 if $opts{'compiler'} eq $stdcomp;
    }
    $opts{'nonstdcompiler'} = 1 unless $standard;
}
else {
    print "Auto-detecting compiler\n" if $opts{'verbose'};
    for my $stdcomp (@{$platforminfo{$opts{'host'}}->{'compilers'}}) {
        my $path = which($stdcomp);
        if ($path) {
            print "Found $stdcomp at: $path\n" if $opts{'verbose'};
            $opts{'compiler'} = $stdcomp;
            last;
        }
    }
    if (!defined $opts{'compiler'}) {
        die "Can't find a compiler, set PATH or run this script with the ".
        "--compiler option.\n" . ($slash eq '\\' ? "  For Microsoft Visual C++, ".
        "run this script from the Visual Studio ".
        "Command Prompt.\n" : '') . "Stopped";
    }
}

Какой компилятор он хочет? У меня gcc и make работают - они по системному пути.


person user3235290    schedule 09.08.2016    source источник
comment
просто добавьте --compiler=gcc, должно работать   -  person Jean-François Fabre    schedule 09.08.2016
comment
Бинго, спасибо. Не стесняйтесь публиковать в качестве ответа, и я приму, если нет, я отвечу себе, чтобы закрыть вопрос через ~ 1 день.   -  person user3235290    schedule 09.08.2016
comment
Первая инструкция: Убедитесь, что в вашей среде есть: Visual Studio, Perl   -  person ikegami    schedule 09.08.2016


Ответы (1)


Я предполагаю, что Windows не указывает gcc как естественно установленный компилятор.

В линуксе заработало бы сразу.

Так что просто добавьте --compiler=gcc, если gcc есть в пути, это должно работать.

person Jean-François Fabre    schedule 09.08.2016