我正在尝试按照这些说明构建sail_align
程序。到目前为止一切顺利,我已经完成了最后的第四步,没有出现错误:
4) sudo ./Build install
This command will install the module.
The following perl scripts will be added to your path: sail_align, sail_align_parallel
但是,当我运行以下命令来测试安装时:
sail_align -i support/data/timit_5.wav -t support/data/timit_5.txt \
-w support/test/local -e timit_sample_test -c config/timit_alignment.cfg
我收到消息说找不到 sail_align 命令。我究竟做错了什么?这是Build
文件的脚本:
$progname = basename($0);
$orig_dir = Cwd::cwd();
my $base_dir = '/home/maximus/sail_align-master';
if (!magic_number_matches()) {
unless (chdir($base_dir)) {
die ("Couldn't chdir($base_dir), aborting\n");
}
unless (magic_number_matches()) {
die ("Configuration seems to be out of date, please re-run 'perl Build.PL' again.\n");
}
}
unshift @INC,
(
);
}
close(*DATA) unless eof(*DATA); # ensure no open handles to this script
use Module::Build;
Module::Build->VERSION(q{0});
# Some platforms have problems setting $^X in shebang contexts, fix it up here
$^X = Module::Build->find_perl_interpreter;
if (-e 'Build.PL' and not Module::Build->up_to_date('Build.PL', $progname)) {
warn "Warning: Build.PL has been altered. You may need to run 'perl Build.PL' again.\n";
}
# This should have just enough arguments to be able to bootstrap the rest.
my $build = Module::Build->resume (
properties => {
config_dir => '_build',
orig_dir => $orig_dir,
},
);
$build->dispatch;
编辑
echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
locate sail_align
什么都不输出
编辑2
运行find / 'sail_align'
输出如下
/home/maximus/perl5/bin/sail_align
/home/maximus/perl5/bin/sail_align_parallel
/home/maximus/sail_align-master
/home/maximus/sail_align-master/blib/script/sail_align
/home/maximus/sail_align-master/blib/script/sail_align_parallel
/home/maximus/sail_align-master/docs/sail_align_tutorial_vlsrp2011.pdf
/home/maximus/sail_align-master/docs/sail_align_tutorial_vlsrp2011.ppt
/home/maximus/sail_align-master/scripts/sail_align
/home/maximus/sail_align-master/scripts/sail_align_parallel
如您所见,程序sail_align和sail_parallel位于:
并且此路径不存在于
$PATH
bash 用于解析命令位置的变量中。您可以将路径添加到环境变量:编辑您的路径
/home/maximus/.bashrc
并在末尾添加:比:
并重做你的命令