6

I am trying to compile VRip in Ubuntu 10.04, using the site http://graphics.stanford.edu/software/vrip/guide/ as a guide. It relies on installation of Tcl and Tk -- I have acquired the latest versions of these from the synaptic package manager.

When I write "make depend", I get the error:

In file included from vripInit.cc:30: vripInit.h:22:17: error: tcl.h: No such file or directory vripMain.cc:22:16: error: tk.h: No such file or directory In file included from vripMain.cc:28: vripInit.h:22:17: error: tcl.h: No such file or directory In file included from vripMiscCmds.cc:29: vripMiscCmds.h:22:17: error: tcl.h: No such file or directory In file included from vripFillCmds.cc:29: vripFillCmds.h:22:17: error: tcl.h: No such file or directory In file included from vripFileCmds.cc:29: vripFileCmds.h:22:17: error: tcl.h: No such file or directory In file included from vripGridCmds.cc:29: vripGridCmds.h:22:17: error: tcl.h: No such file or directory In file included from vripRangeCmds.cc:36: vripRangeCmds.h:21:17: error: tcl.h: No such file or directory In file included from vripGUICmds.cc:37: vripGUICmds.h:22:17: error: tcl.h: No such file or directory vripGUICmds.cc:43:16: error: tk.h: No such file or directory In file included from vripPlyCmds.cc:32: vripPlyCmds.h:22:17: error: tcl.h: No such file or directory rm makedep.bak

It seems to be looking for header files and not finding them. But I'm not sure where to tell it to look. Could anyone with more experience help out? I've spent a good couple of hours trying to figure this out without any success... :S

Thanks, LPlates

guido
  • 18,864
  • 6
  • 70
  • 95
3lbom
  • 139
  • 1
  • 1
  • 11

1 Answers1

7

Install tcl-dev package using apt or synaptic; tcl contains the runtime, while tcl-devel contains header and development files. Do the same with tk-dev

guido
  • 18,864
  • 6
  • 70
  • 95
  • Hi Guido, thanks for your help. I should've mentioned, I've already installed the dev packages for tcl and tk using synaptic but it still doesn't work... is there something else I'm forgetting to do? – 3lbom Mar 10 '12 at 19:32
  • did you set the environment variables as said some lines below in the guide you linked in your question? _VRIP_TCL_LIBRARY_ and _VRIP_TK_LIBRARY_ ? and, as you probably are using bash and not csh, you have to set those with export, not setenv – guido Mar 10 '12 at 19:37
  • yep - I did, and I changed the directories they were pointing to to /vrippack-0.31/lib/linux/tk8.4 and VRip/vrippack-0.31/lib/linux/tcl8.4 -- i.e. lib/linux rather than linux/lib as documented (I assume this was a mistake in the documentation) – 3lbom Mar 10 '12 at 19:45
  • did you also install _tcl8.4-dev_ and _tk8.4-dev_ ? there's no tcl.h in tcl-dev (i think because they want to support multiple tcl/tk versions) – guido Mar 10 '12 at 19:49
  • 2
    ok the problem is that tcl.h header is installed in /usr/include/tcl8.4 while vrip only expects it to be in /usr/include. (on fedora it compiles with no extra fuzzes.. :) ). I'm sorry you have to edit build files to build vrip yourself. Go into _src_ subdirectory, then edit file _compile-flags_ . Search for the line _INCL= -I. ...._ and add _-I/usr/include/tcl8.4 -I/usr/include/tk8.4_ Then in the line _LIBPATHS=_ add _-L/usr/lib/yourtcllibrariespath_ (same for tk). Beware you need to edit the lines in the else branch (lines 63-65) – guido Mar 10 '12 at 20:05
  • awesome! thanks very much - it's fixed and compiles. really appreciate your effort! hopefully i can do something useful with this library now :) – 3lbom Mar 10 '12 at 21:13
  • 1
    @LPlates This is the sort of thing that is handled when a package is adapted for a distribution. Building from the original source means doing without that sort of thing; you have to deal with (some) of the adaptation process yourself. (Other parts, like the actual packaging, you can skip.) – Donal Fellows Mar 10 '12 at 21:33