我需要在Ubuntu发行版17.10上安装并使用WordNet(当前版本3.0)。我已经安装了所有依赖项(tcl/tk),并按照开发人员的指示进行操作,./configure
make
make install
处理。
我解压了软件包,然后在目录中键入./configure.sh
时,它没有错误:WordNet is now configured
Installation directory: /usr/local/WordNet-3.0
等等
当我现在运行make
时,我得到:
compilation terminated.
Makefile:267: recipe for target 'libWN_a-binsrch.o' failed
make[3]: *** [libWN_a-binsrch.o] Error 1
make[3]: Leaving directory '/home/user/WordNet/WordNet-3.0/lib'
Makefile:372: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/user/WordNet/WordNet-3.0/lib'
Makefile:218: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/user/WordNet/WordNet-3.0'
Makefile:156: recipe for target 'all' failed
make: *** [all] Error 2
如果我运行
sudo make
我得到:compilation terminated.
Makefile:273: recipe for target 'wishwn-tkAppInit.o' failed
make[2]: *** [wishwn-tkAppInit.o] Error 1
make[2]: Leaving directory '/home/user/WordNet/WordNet-3.0/src'
Makefile:218: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/user/WordNet/WordNet-3.0'
Makefile:156: recipe for target 'all' failed
make: *** [all] Error 2
(如果在
make
之后和之后再次输入sudo make
,则会出现相同的错误)。在该程序的分布式README和INSTALL文本中,我没有找到任何相关信息。
有见识吗?
谢谢!
最佳答案
WordNet 3.0似乎以不推荐使用的方式(interp->result
)访问Tcl内部。
尝试使用CFLAGS=-DUSE_INTERP_RESULT make
进行编译-这样可以对interp->result
进行旧式访问。
从man page:
For legacy programs and extensions no longer being maintained, compiles against the Tcl 8.6 header files are only possible with the compiler directives
#define USE_INTERP_RESULT
and/or
#define USE_INTERP_ERRORLINE
depending on which fields of the Tcl_Interp struct are accessed. These directives may be embedded in code or supplied via compiler options.
关于compiler-errors - 如何在Ubuntu 17.10上编译WordNet-3.0?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50164044/