This PR fixes an error in installing mecab-ipadic-NEologd into a missing directory.
This PR includes
A modified version of libexec/install-mecab-ipadic-neologd.sh
What type of PR is it?
Bugfix
What is the issue?
The following error sometimes occurs:
ls: cannot access '/usr/lib/x86_64-linux-gnu/mecab/dic': No such file or directory
/mecab-ipadic-neologd/bin/../libexec/install-mecab-ipadic-neologd.sh: line 56: [: 0: unary operator expected
This happens when a user install mecab and mecab-ipadic-utf8 on Ubuntu by apt.
The package manager installs the dictionaries into /var/lib/mecab/dic.
However, the default location for dictionaries, indicated by mecab-config --dicdir, is set to /usr/lib/x86_64-linux-gnu/mecab/dic, which has not been created.
Thus, installation script fails in running ls.
This error is not critical because the following processes run successfully even when it happens.
Possibly, this is a bug of MeCab or the package manager, but it is safer to check if the directory exist.
How should this be tested?
Create a new Ubuntu machine and install mecab and mecab-ipadic-utf8.
Then, install mecab-ipadic-NEologd without editing mecabrc.
What is this PR for?
This PR fixes an error in installing mecab-ipadic-NEologd into a missing directory.
This PR includes
libexec/install-mecab-ipadic-neologd.sh
What type of PR is it?
Bugfix
What is the issue?
The following error sometimes occurs:
This happens when a user install
mecab
andmecab-ipadic-utf8
on Ubuntu by apt. The package manager installs the dictionaries into/var/lib/mecab/dic
. However, the default location for dictionaries, indicated bymecab-config --dicdir
, is set to/usr/lib/x86_64-linux-gnu/mecab/dic
, which has not been created. Thus, installation script fails in runningls
. This error is not critical because the following processes run successfully even when it happens. Possibly, this is a bug of MeCab or the package manager, but it is safer to check if the directory exist.How should this be tested?
Create a new Ubuntu machine and install
mecab
andmecab-ipadic-utf8
. Then, installmecab-ipadic-NEologd
without editingmecabrc
.