From: John Stone (johns_at_ks.uiuc.edu)
Date: Wed Aug 13 2014 - 12:28:32 CDT

Vlastimil,
  Just FYI, the Tcl 8.5.0 version listed in the dependencies below
is pretty archaic. The VMD builds we ship are based on at least
Tcl 8.5.6 / 8.5.9, and we are now transitioning to Tcl 8.6.x. I would suggest
not using the dependencies provided by debian if they are such old
versions of Tcl/Tk.

If we were to track down the source of your font problem
to be a bug in Tcl/Tk itself, there would be no point in submitting
a bug report on such an old version of Tcl/Tk, we would want to be using one
of the last versions of the 8.5.x series, or one of the current 8.6.x
releases in order to convince the Tcl/Tk developers to make/apply a fix.

If the problem isn't Tcl/Tk itself, but rather something to do with
the behavior of the X server of the font system on the affected machine,
then this may not be important, but I wanted to mention that 8.5.0 is
quite old and we began using later versions due to other known bugs
that were in 8.5.0.

Cheers,
  John Stone
  vmd_at_ks.uiuc.edu

On Wed, Aug 13, 2014 at 07:21:12PM +0200, Vlastimil Zíma wrote:
> Yet another build on debian wheezy, but on different machine. Not to build
> a package.
>
> === Build dependencies ===
> latex2html 2008-debian1-7
> libfltk1.3-dev 1.3.0-8
> libglu1-mesa-dev 8.0.5-4+deb7u2
> libnetcdf-dev 1:4.1.3-6+b1
> libxi-dev 2:1.6.1-1+deb7u1
> make 3.81-8.2
> python-dev 2.7.3-4+deb7u1
> python-numpy 1:1.6.2-1.2
> tcl-dev 8.5.0-2.1
> texlive-latex-base 2012.20120611-5
> tk-dev 8.5.0-2.1
>
> === Build process ===
> tar -xzf vmd_1.9.1.orig.tar.gz
> cd vmd-1.9.1
> mv ../plugins plugins_src
> export PLUGINDIR=$PWD/plugins
> export TCL_INCLUDE_DIR=/usr/include/tcl
> export TK_INCLUDE_DIR=/usr/include/tk
> export PYTHON_INCLUDE_DIR=/usr/include/python2.7
> export NUMPY_INCLUDE_DIR=/usr/include/python2.7/numpy
> export VMDINSTALLBINDIR=$PWD/root/bin
> export VMDINSTALLLIBRARYDIR=$PWD/root/lib
> # Compile plugins
> make -C plugins_src LINUXAMD64 TCLINC=-I${TCL_INCLUDE_DIR}
> TCLLIB=-I/usr/share/tcltk/tcl8.5
> make -C plugins_src distrib
> sed -i 's|python2.5|python2.7|' configure
> ./configure LINUXAMD64 OPENGL FLTK TK IMD XINPUT NETCDF CONTRIB TCL PYTHON
> PTHREADS NUMPY NOSTATICPLUGINS
> make -C src
> make -C src install
>
> And it's broken again.
>
> Vlastimil
>
> 2014-08-13 18:34 GMT+02:00 Vlastimil ZAma <[1]zima_at_karlov.mff.cuni.cz>:
>
> Hi Josh,
>
> thanks for the reply. I've tried to build VMD as is quite some time ago,
> but as far as I can remember I had the same issue. The paths doesn't
> seem to be an issue, as I've defined all Tcl related variables,
> otherwise the compilation would break. In my experience debian builds
> complain quite effectively. Anyway I checked (grep -i 'error\|fail') the
> output and haven't found any errors in there.
>
> I'll try to build VMD without packaging and provide further info.
>
> Vlastimil
>
> 2014-08-13 16:48 GMT+02:00 Josh Vermaas <[2]vermaas2_at_illinois.edu>:
>
> Hi Vlastimil,
>
> I've compiled VMD for Ubuntu and packaged it for myself as you've
> done, and that isn't something I've seen before. Others have noticed
> that depending on your linux installation, some characters are missing
> from the system defaults (Angstrom seems to be the most common one).
> Have you tried to build VMD in a non-packaged way first? Looking at
> the rules file, the set directories look plausible depending on your
> system setup, but I vaguely remember for instance needing to specify a
> version number to pick up the appropriate header files and shared
> libraries (so /usr/include/tcl8.5 instead of /usr/include/tcl, and
> actually specifying a TCL_LIBRARY_DIR since the shared object wasn't
> in /usr/lib). The debian package building process in my limited
> experience hides errors very effectively, so if something went wrong,
> it won't stop dpkg from building and making something that looks
> plausible as a package that is totally broken.
>
> I'm just spitballing here. There is nothing obviously wrong (to my
> eyes at least) with your configuration, and I've never seen the error
> that you report, so I'm sorry I can't be more helpful. :(
> -Josh Vermaas
>
> On 8/13/14, 5:12 AM, Vlastimil ZAma wrote:
>
> Hi everyone,
>
> continuing on this issue as there is indication I'm not the only one
> suffering by this problem, see
> [3]http://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/21361.html.
>
> Sum up the configuration:
> A * Debian wheezy (stable), using system libraries, so they're not
> likely to be broken.
> A * I run VMD from console on my machine.
> A * Doesn't look like problem with font installation. "font
> families" returns the same result for tcl shell and vmd tcl shell.
> A * I don't have SCIM installed which may cause troubles.
> A * All my machines run under English locales "en_US.UTF-8".
>
> Since first error is
>
> X_QueryColors: BadValue (integer parameter out of range for
> operation) 0xff000000
>
> I begin to suspect it may not be a problem related to fonts but
> rather to the graphics in more general manner, e.g. wrong order of
> layers.
>
> I tried to debug Tcl a bit and find out the errors appears after
> function `::timeline::startTimeline` is finished. But this may be of
> course caused by delay between window setup and its rendering.
>
> I've published debian packaging metadata at github
> [4]https://github.com/ziima/vmd-debian. I'd be glad if anyone cares
> to investigate or build the package using my metadata.
> Alternatively I'm looking for somebody who compiled VMD successfully
> on Debian or Ubuntu.
>
> Regards,
> Vlastimil
>
> 2013-12-04 10:11 GMT+01:00 Vlastimil ZAma
> <[5]zima_at_karlov.mff.cuni.cz>:
>
> Hi John,
>
> I haven't compiled Tk myself, I use system library. But all code
> which is based on Tk works to my knowledge.
>
> As noted in my first email, I created a simple script based on
> code I considered to cause problems in Timeline plugin:
>
> $ cat tk_test.tcl
> package require Tk
> font create tkFixedTimeline -family Courier -size -12
> ttk::label .l -text "Attention!" -font tkFixedTimeline
> grid .l -row 0
>
> This script works as expected. I also use a program Seaview, which
> uses libfltk1.3 as well, without any problems. For these reasons I
> expect that the system Tcl/Tk libraries work as they should.
>
> I was not able to find any other problematic code in Timeline
> plugin and I'm not able to run the Timeline plugin outside of VMD,
> so I don't have any other Tk GUI script to test. If you can
> recommend any tests I'd like to try them out.
> Vlastimil
> 2013/11/27 John Stone <[6]johns_at_ks.uiuc.edu>
>
> Vlastimil,
> A If your compilation of Tk is misbehaving, but our
> pre-compiled VMD
> binaries work okay, I would check what options were used when
> you
> compiled your Tk, and consider disabling antialiased fonts and
> see if
> that makes any difference. A Are you able to run an Tk scripts
> with
> just the Tcl/Tk builds you did on your machine? A In other
> words, is
> the problem isolated to Tcl/Tk on your machine, or do you have a
> Tk GUI script that works in 'wishx' but fails within VMD? A It
> would be
> useful to narrow down the problem and see if it is purely an
> issue
> with your Tcl/Tk, or if it is something unique to running within
> VMD.
>
> Cheers,
> A John Stone
> A [7]vmd_at_ks.uiuc.edu
> On Wed, Nov 27, 2013 at 05:11:34PM +0100, Vlastimil ZAma wrote:
> > A A Hi everybody,
> >
> > A A wheezy became stable, but I still experience this
> problem.
> >
> > A A Anyway, I now suggests this may not be a problem of
> fonts, but rather
> > A A colors. I tried to check the error output, see my
> previous post
> > A
> A [8]http://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/19942.html
> and I
> > A A have an impression that fonts might be properly rendered
> but they are over
> > A A painted by some other invalid entity (images or colored
> blocks).
> >
> > A A Is there any other Tk-related build/runtime dependency
> that is not mention
> > A A in documentation?
> >
> > A A Regards,
> > A A Vlastimil
> >
> > A A 2012/10/5 Vlastimil ZAma <[9]zima_at_karlov.mff.cuni.cz>
> >
> > A A A Hi,
> >
> > A A A when I compared my compiled VMD with precompiled
> binary some time ago,
> > A A A the fonts were present in the precompiled one. That is
> why I expect
> > A A A problems in compilation. I also did not noticed any
> lack of fonts in
> > A A A system paths, but I do not know which fonts to look
> for.
> >
> > A A A > tclsh
> > A A A % package require Tk
> > A A A 8.5.11
> > A A A % puts "$tcl_version"
> > A A A 8.5
> > A A A % puts "$tk_version"
> > A A A 8.5
> >
> > A A A All tcl and tk packages I have are for amd64 bit
> architecture (all
> > A A A libraries are in /usr/lib). Specifically
> >
> > A A A [10]http://packages.debian.org/wheezy/tcl8.5 version
> 8.5.11-2
> > A A A [11]http://packages.debian.org/wheezy/tk8.5 version
> 8.5.11-2
> >
> > A A A Regards,
> > A A A Vlastimil
> >
> > A A A On 10/05/2012 04:08 PM, John Stone wrote:
> >
> > A A A A Hi,
> > A A A A A A A Problems with Tk fonts are generally caused
> not by the
> > A A A A compilation of
> > A A A A VMD (or FLTK) but are usually the result of a lack
> of fonts installed
> > A A A A with the X11 Windowing system. A Tk obtains its
> fonts by querying the
> > A A A A host windowing system for fonts that match the
> characteristics of a
> > A A A A request.
> > A A A A If the host windowing system has no match, then Tk
> tries to fallback
> > A A A A to
> > A A A A some font that is available.
> >
> > A A A A A From the description below, it sounds to me like
> there might be
> > A A A A something
> > A A A A amiss the X11 window system fonts or one of the X11
> libraries on the
> > A A A A machine
> > A A A A you're using, and that this is preventing the Tk
> library embedded in
> > A A A A VMD from getting anything other than the default
> font.
> >
> > A A A A Since you're able to get a simple test to work in a
> standalone
> > A A A A interpreter,
> > A A A A one thing that may be worth checking is whether
> there might be some
> > A A A A problem with the 64-bit libs on your machine. A Is
> the "tclsh" that
> > A A A A you
> > A A A A run in your example below a 32-bit or 64-bit
> library? A What do you
> > A A A A get
> > A A A A from this command, when you run it in your tclsh:
> > A A A A A A A puts "$tcl_version"
> > A A A A A A A puts "$tk_version"
> >
> > A A A A Cheers,
> > A A A A A A A John Stone
> > A A A A A A A [12]vmd_at_ks.uiuc.edu
> >
> > A A A A On Thu, Oct 04, 2012 at 11:07:03AM +0200, Vlastimil
> ZAma wrote:
> >
> > A A A A A A A A A Hi,
> >
> > A A A A A A A A A after several attempts I still can not
> resolve troubles with
> > A A A A A tk fonts when
> > A A A A A A A A A I compile VMD.
> >
> > A A A A A A A A A I am using 64bit Debian with following
> vmd configuration:
> >
> > A A A A A A A A A ./configure LINUXAMD64 OPENGL FLTK TK
> IMD XINPUT NETCDF
> > A A A A A CONTRIB TCL PYTHON
> > A A A A A A A A A PTHREADS NUMPY NOSTATICPLUGINS
> >
> > A A A A A A A A A and tk packages:
> > A A A A A A A A A libfltk1.3-dev 1.3.0-8 (I also tried
> fltk1.1)
> > A A A A A A A A A tcl-dev 8.5.0-2
> > A A A A A A A A A tk-dev 8.5.0-2
> >
> > A A A A A A A A A Still timeline, sequence viewer and
> other plugins which uses
> > A A A A A customized
> > A A A A A A A A A fonts has invisible texts. I tried
> anything I found on this
> > A A A A A mailing list,
> > A A A A A A A A A including LC_ALL=C in environment and
> $HOME/.tkconrc file. I
> > A A A A A also tried a
> > A A A A A A A A A simple script with uses custom font
> based on code of timeline
> > A A A A A which works:
> >
> > A A A A A A A A A > A tclsh
> > A A A A A A A A A package require Tk
> > A A A A A A A A A font create tkFixedTimeline -family
> Courier -size -12
> > A A A A A A A A A ttk::label .l -text "Attention!" -font
> tkFixedTimeline
> > A A A A A A A A A grid .l -row 0
> >
> > A A A A A A A A A This shows nice small box with monofont
> "Attention!" in it.
> >
> > A A A A A A A A A I will be glad for any help which would
> help to resolve this
> > A A A A A problem.
> > A A A A A A A A A Vlastimil
> --
> NIH Center for Macromolecular Modeling and Bioinformatics
> Beckman Institute for Advanced Science and Technology
> University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
> [13]http://www.ks.uiuc.edu/~johns/ A A A A A Phone:
> 217-244-3349
> [14]http://www.ks.uiuc.edu/Research/vmd/
>
> References
>
> Visible links
> 1. mailto:zima_at_karlov.mff.cuni.cz
> 2. mailto:vermaas2_at_illinois.edu
> 3. http://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/21361.html
> 4. https://github.com/ziima/vmd-debian
> 5. mailto:zima_at_karlov.mff.cuni.cz
> 6. mailto:johns_at_ks.uiuc.edu
> 7. mailto:vmd_at_ks.uiuc.edu
> 8. http://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/19942.html
> 9. mailto:zima_at_karlov.mff.cuni.cz
> 10. http://packages.debian.org/wheezy/tcl8.5
> 11. http://packages.debian.org/wheezy/tk8.5
> 12. mailto:vmd_at_ks.uiuc.edu
> 13. http://www.ks.uiuc.edu/%7Ejohns/
> 14. http://www.ks.uiuc.edu/Research/vmd/

-- 
NIH Center for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
http://www.ks.uiuc.edu/~johns/           Phone: 217-244-3349
http://www.ks.uiuc.edu/Research/vmd/