2

When trying to make WordNet 3.0, it exits with error 2. Scrolling up, the following error surfaces:

In file included from tkAppInit.c:16:
/usr/include/tk.h:78:23: error: X11/Xlib.h: No such file or directory

How do we install WordNet on OS X 10.8?

DK_
  • 2,648
  • 2
  • 21
  • 20

2 Answers2

5

The problem is caused by X11 no longer being bundled with OS X from 10.8 (maybe earlier?). The first step is to download and install xQuartz. After this is done, it will have placed X11 headers in:

/opt/X11/include/X11

But we need them in:

/usr/include

The easy solution is to just make a symbolic link:

 sudo ln -s /opt/X11/include/X11 /usr/include

(This was taken from an SO post on TCL X11 OS-X)

Now if you run the make/make install within the WordNet 3.0 distribution, it should install without problems.

Community
  • 1
  • 1
DK_
  • 2,648
  • 2
  • 21
  • 20
  • Does it need an X11 build? The Cocoa version of Tk is preferred on OSX these days (for obvious reasons) but not every extension package can cope with that… – Donal Fellows Feb 28 '13 at 07:36
  • Tk isn't actually being reinstalled. The WordNet-3.0 install has Tcl/Tk code that needs the X11 headers though, and those headers are no longer present in new versions of OS X by default. – DK_ Feb 28 '13 at 17:41
  • I'm running OS X Mavericks 10.9.2, I have installed xQuartz and made the symbolic link as instructed. However, when try to `make` I got 14 error as `stubs.c:43:17: error: no member named 'result' in 'struct Tcl_Interp' interp -> result = ~~~~~~ ^` all error seems to come from the same file `stubs.c`. Any idea how to solve this ... – user692704 May 14 '14 at 04:50
  • Just tried this on a new mac with 10.9.2 (Mavericks) and it completed without error (`./configure` followed by `make`). Are you installing WordNet 3.0 with xQuartz 2.7.5? – DK_ May 15 '14 at 05:42
1

I had the same issue. Best solution is to instal via Brew found here

  1. Press Command+F and type Terminal and press enter/return key.
  2. Run in Terminal app: ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null and press enter/return key. Wait for the command to finish.
  3. brew install wordnet
Whitecat
  • 3,882
  • 7
  • 48
  • 78