Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 78385 - net-misc/tightvnc look for invalid, old RgbPath and get 'undefined color'
Summary: net-misc/tightvnc look for invalid, old RgbPath and get 'undefined color'
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords:
: 132358 143525 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-01-17 09:44 UTC by Bas van Dijk
Modified: 2006-10-05 11:45 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
new-rgbpath.patch (new-rgbpath.patch,474 bytes, patch)
2006-08-11 11:20 UTC, Colin Macdonald
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bas van Dijk 2005-01-17 09:44:01 UTC
After emerging xorg-x11-6.8.1.902 some applications give warnings and errors like:

$ emacs
Undefined color: "black"

$ xterm
Warning: Color name "black" is not defined

$ xfontsel
Warning: Color name "black" is not defined

When using xorg-x11-6.8.0-r3 this does not occur.

Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Comment 1 Bas van Dijk 2005-01-17 09:47:25 UTC
Forum topic:
http://forums.gentoo.org/viewtopic.php?t=281067
Comment 2 Bas van Dijk 2005-01-17 11:03:36 UTC
In the forum topic StinkingMonkey pointed me to the solution:


check this line of xorg.conf

RgbPath "/usr/X11R6/lib64/X11/rgb"

make sure its pointing to the rgb.txt file , dont add .txt to the line, im using amd64 so yours may differ...


Now it works again.
Comment 3 Alexander Skwar 2006-05-10 02:13:31 UTC
Please reopen.

I'm seeing the issues as well. In my /etc/X11/xorg.conf, I've set:

    RgbPath     "/usr/share/X11/rgb"

This file exists:

[10:18:07 vz6tml@dewup-ww02:~] $ ls -la /usr/share/X11/rgb*
-rw-r--r-- 1 root root 17371 10. Mai 10:07 /usr/share/X11/rgb.txt

[10:29:58 vz6tml@dewup-ww02:~] $ epm -qf /usr/share/X11/rgb.txt
rgb-1.0.0

But when I start xterm, I get:


[10:18:48 vz6tml@dewup-ww02:~] $ xterm
Warning: Color name "black" is not defined
xterm: Cannot allocate color red
xterm: Cannot allocate color magenta
xterm: Cannot allocate color cyan
xterm: Cannot allocate color green
xterm: Cannot allocate color green3


One (maybe) important note is, that I ALWAYS use VNC (namely the net-misc/vnc-4.0-r1 server) to connect to the system. Client is RealVNC 4.1.1 on Windows XP.

Does vnc use xorg.conf at all? 
Comment 4 Bas van Dijk 2006-05-10 16:45:15 UTC
OK reopened.
Comment 5 Joshua Baergen (RETIRED) gentoo-dev 2006-05-10 18:55:52 UTC
(In reply to comment #3)
> Please reopen.
> 
> I'm seeing the issues as well. In my /etc/X11/xorg.conf, I've set:
> 
>     RgbPath     "/usr/share/X11/rgb"
> 

Which version of X are you running?  If you're on modular (it looks like you are by that path) drop the RgbPath entirely.
Comment 6 Alexander Skwar 2006-05-11 00:15:38 UTC
(In reply to comment #5)

> Which version of X are you running?

modular x.

>  If you're on modular (it looks like you
> are by that path) drop the RgbPath entirely.

Actually, I sort of dropped that setting in the beginning. As I wrote, I use VNC and I actually had no /etc/X11/xorg.conf at all.

Although I don't think it'll make any difference at all, I'll now remove that setting in the dummy (?) xorg.conf file and report back.

BTW: According to the German user list, other people see this problem as well, even without vnc. See http://thread.gmane.org/gmane.linux.gentoo.user.german/26287/focus=26287 which is the thread 
 Warning: Color name "black" is not defined

Comment 7 Alexander Skwar 2006-05-11 00:36:23 UTC
(In reply to comment #6)
> (In reply to comment #5)

> >  If you're on modular (it looks like you
> > are by that path) drop the RgbPath entirely.
> 
> Actually, I sort of dropped that setting in the beginning. As I wrote, I use
> VNC and I actually had no /etc/X11/xorg.conf at all.
> 
> Although I don't think it'll make any difference at all, I'll now remove that
> setting in the dummy (?) xorg.conf file and report back.

It made no difference. I changed the xorg.conf and restarted the VNC server. I still get the error messages.



[09:35:42 vz6tml@dewup-ww02:~] $ grep -v '^ *#' /etc/X11/xorg.conf | grep -v '^$'
Section "Files"
    FontPath    "/usr/share/fonts/local/"
    FontPath    "/usr/share/fonts/misc/"
    FontPath    "/usr/share/fonts/75dpi/:unscaled"
    FontPath    "/usr/share/fonts/100dpi/:unscaled"
    FontPath    "/usr/share/fonts/Type1/"
    FontPath    "/usr/share/fonts/TTF/"
    FontPath    "/usr/share/fonts/CID/"
    FontPath    "/usr/share/fonts/Speedo/"
    FontPath    "/usr/share/fonts/75dpi/"
    FontPath    "/usr/share/fonts/100dpi/"
EndSection
Section "Module"
    Load        "dbe"
    SubSection  "extmod"
        Option  "omit xfree86-dga"
    EndSubSection
    Load        "type1"
    Load        "freetype"
EndSection
Section "ServerFlags"
    Option      "blank time"    "10"    # 10 minutes
    Option      "standby time"  "20"
    Option      "suspend time"  "30"
    Option      "off time"      "60"
EndSection
Section "InputDevice"
    Identifier  "Keyboard1"
    Driver      "keyboard"
    Option      "AutoRepeat"    "500 5"
EndSection
Section "InputDevice"
    Identifier  "Mouse1"
    Driver      "mouse"
    Option      "Protocol"      "Microsoft"
    Option      "Device"        "/dev/mouse"
EndSection
Section "InputDevice"
    Identifier  "Mouse2"
    Driver      "mouse"
    Option      "Protocol"      "MouseMan"
    Option      "Device"        "/dev/mouse2"
EndSection
Section "Monitor"
    Identifier  "Generic Monitor"
    Mode "640x480"
        DotClock        25.175
        HTimings        640 664 760 800
        VTimings        480 491 493 525
    EndMode
EndSection
Section "Device"
    Identifier  "Generic VGA"
    Driver      "vga"
EndSection
Section "Device"
    Identifier  "any supported Trident chip"
    Driver      "trident"
EndSection
Section "Device"
    Identifier  "MGA Millennium I"
    Driver      "mga"
    Option      "hw cursor" "off"
    BusID       "PCI:0:10:0"
EndSection
Section "Device"
    Identifier  "MGA G200 AGP"
    Driver      "mga"
    BusID       "PCI:1:0:0"
    Option      "pci retry"
EndSection
Section "Screen"
    Identifier  "Screen 1"
    Device      "Generic VGA"
    Monitor     "Generic Monitor"
    DefaultDepth 8
    SubSection "Display"
        Depth           8
        Modes           "640x480"
        ViewPort        0 0
        Virtual         800 600
    EndSubsection
    SubSection "Display"
        Depth           4
        Modes           "640x480"
    EndSubSection
    SubSection "Display"
        Depth           1
        Modes           "640x480"
    EndSubSection
EndSection
Section "Screen"
    Identifier          "Screen MGA1"
    Device              "MGA Millennium I"
    Monitor             "Generic Monitor"
    Option              "no accel"
    DefaultDepth        16
    SubSection "Display"
        Depth           8
        Modes           "1280x1024"
        Option          "rgb bits" "8"
        Visual          "StaticColor"
    EndSubSection
    SubSection "Display"
        Depth           16
        Modes           "1280x1024"
    EndSubSection
    SubSection "Display"
        Depth           24
        Modes           "1280x1024"
    EndSubSection
EndSection
Section "Screen"
    Identifier          "Screen MGA2"
    Device              "MGA G200 AGP"
    Monitor             "Generic Monitor"
    DefaultDepth        8
    SubSection "Display"
        Depth           8
        Modes           "1280x1024"
        Option          "rgb bits" "8"
        Visual          "StaticColor"
    EndSubSection
EndSection
Section "ServerLayout"
    Identifier  "Main Layout"
    Screen      "Screen MGA 1"  ""      ""      ""      "Screen MGA 2"
    Screen      "Screen MGA 2"  ""      ""      "Screen MGA 1"  ""
    InputDevice "Mouse1" "CorePointer"
    InputDevice "Mouse2" "SendCoreEvents"
    InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Section "ServerLayout"
    Identifier  "another layout"
    Screen      "Screen 1"
    Screen      "Screen MGA 1"
    InputDevice "Mouse1" "CorePointer"
    InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Section "ServerLayout"
    Identifier  "simple layout"
    Screen      "Screen 1"
    InputDevice "Mouse1" "CorePointer"
    InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Comment 8 Alexander Skwar 2006-05-14 03:51:33 UTC
Any ideas?

I've got these errors now on 2 systems. And I'm not alone, other people also suffer from this bug. On the User list, somebody suggested to setup a symlink from /usr/lib/X11/rgb.txt -> /usr/share/X11/rgb.txt; see http://article.gmane.org/gmane.linux.gentoo.user/160591 - but this doesn't work for me.

What has been changed, which caused systems to break? Could this please be reverted?
Comment 9 Hiel Van Campen 2006-05-14 12:33:19 UTC
Same prob here

tester ~ # emerge --info
Portage 2.1_rc1-r1 (default-linux/x86/2005.1, gcc-4.1.0, glibc-2.4-r2, 2.6.15.1 i686)
=================================================================
System uname: 2.6.15.1 i686 AMD Sempron(tm) Processor 2800+
Gentoo Base System version 1.12.0_pre19
dev-lang/python:     2.3.5-r2, 2.4.3-r1
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.92
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r5
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-xp -Os -pipe "
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/eselect/compiler /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/env.d"
CXXFLAGS="-march=athlon-xp -Os -pipe  "
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig buildpkg distlocks metadata-transfer sandbox sfperms strict userpriv"
GENTOO_MIRRORS="http://gentoo.mirrors.pair.com http://mirror.datapipe.net/pub/gentoo/ ftp://ftp.ucsb.edu/pub/mirrors/linux/gentoo/"
MAKEOPTS="-j2 "
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/include/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dnow 3dnowext X alsa apache2 async avi berkdb bitmap-fonts bzip2 cairo chroot cli cpdflib crypt cups dba dillo divx4linux doc dri eds emboss encode fbdev foomaticdb fpx freetype gd gdbm gif gnome gpm gstreamer gtk gtk2 imagemagick imlib ipv6 isdnlog java javascript jpeg kde libg++ libwww live lynxkeymap lzw lzw-tiff mad mikmod mmx mmxext mono motif mozilla mp3 mpeg mpeg4 ncurses network nptl nptlonly nsplugin ogg oggvorbis opengl openssh oss pam pango pcre pdflib perl php player png ppds pppd python qt quicktime readline real reflection rtc samba sdl session spell spl sse sse2 ssl tcpd truetype truetype-fonts type1 type1-fonts vim vorbis win32codecs xml2 xmms xorg xv zlib elibc_glibc kernel_linux userland_GNU video_cards_fbdev video_cards_nv video_cards_nvidia"
Unset:  ASFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_RSYNC_EXTRA_OPTS

thiengs Ive tried (from thread http://forums.gentoo.org/viewtopic-t-443193-start-0-postdays-0-postorder-asc-highlight-.html

Same problem here. Things Ive tried since changing to xorg-7 and getting this prob. In CL, consoles, ALT-F1 and such run fine.

INFO Portage 2.1_rc1 (default-linux/x86/2005.1, gcc-4.1.0, glibc-2.4-r2, 2.6.15.1 i686)
CFLAGS= "-march=athlon-xp -Os -pipe "

1 different kernel
2 removeing nvidia-kernel
3 removing .Xdefaaults
- 3A. Many edits of .Xdefaults includeing coping tvw/Xterm-color into Xdefaults and then wacking on it some.
4 Changineg Bg/Fg from Black/white to white/black
5 re-emerge ncurses and xterm
6 umpteen checks that " RgbPath "/usr/share/X11/rgb" " is real and in xorg.conf.

Any ncurses based prog like "mc" or kernel "make menuconfig" when run in xterm, becaome white screens with no decrenable text. I normally run with black background and white text.
vim does give me one color a mudy maude for keywords and white text for the rest
Comment 10 Hiel Van Campen 2006-05-14 16:27:59 UTC
I tried down gradeing to xterm-207,no joy. I was at xterm-212-r2. I emerged rxvt-2.7.10-r3 and it works fine. 
Comment 11 Venkat Manakkal 2006-05-29 06:34:34 UTC
I'm using tightvnc and it looks like the location of rgb.txt is important

I found http://www.ubuntuforums.org/showthread.php?t=90751&page=2

and added the symlinks one by one until it got fixed - 

cd /usr/X11R6/lib/X11
ln -s /usr/X11R6/share/X11/rgb.txt

fixed it for me on amd64 xorg-x11-7.0-r1 accessed via tightvnc

Now emacs starts fine and does not complain about black...
Comment 12 Joshua Baergen (RETIRED) gentoo-dev 2006-06-11 09:37:40 UTC
Alright, so this looks like the VNC servers are pointing to old rgb paths, then.  Which servers are everyone using?
Comment 13 Alexander Skwar 2006-06-11 11:58:20 UTC
I'm using net-misc/vnc-4.0-r1 - the symlink "trick" 

# ln -vs /usr/share/X11/rgb.txt /usr/lib/X11/rgb.txt

now works for me as well, despite what I wrote in comment #8.

When the file /usr/lib/X11/rgb.txt does not exist, I get the errors.
Comment 14 Donnie Berkholz (RETIRED) gentoo-dev 2006-06-20 22:25:39 UTC
This isn't really an x11@ bug, it should go to maintainers of the VNC servers.
Comment 15 Alexander Thomas 2006-07-10 16:29:36 UTC
If you're using tightVNC, there is an easy fix. The cause of the error is that the path to rgb.txt is hardcoded in the source, but there's no need to recompile. You can simply modify the 'vncserver' script, it has a setting "$colorPath" which can override the hardcoded value.
Just uncomment the "$colorPath = ..." line in the 'vncserver' script, and make it point to the correct location of rgb.txt, without the ".txt" (probably "/usr/share/X11/rgb").
Comment 16 Jakub Moc (RETIRED) gentoo-dev 2006-08-04 16:36:51 UTC
*** Bug 132358 has been marked as a duplicate of this bug. ***
Comment 17 Jakub Moc (RETIRED) gentoo-dev 2006-08-11 00:51:55 UTC
*** Bug 143525 has been marked as a duplicate of this bug. ***
Comment 18 Colin Macdonald 2006-08-11 11:15:42 UTC
Sorry for the dup, I searched for "vnc rgb.txt" but not rgbpath :-(

Would a patch that does comment #15 in the ebuild be accepted?  I'm worried that it would break things in a similar way for anyone still using xorg < 7.  The only safe thing I can think it to make vnc and tightvnc dep on Xorg >= 7 (or maybe >=6.9 if 6.9 uses the new rgbpath too).  Is that a good idea?
Comment 19 Colin Macdonald 2006-08-11 11:20:38 UTC
Created attachment 94008 [details, diff]
new-rgbpath.patch

If excepted, should probably be incorporated into tightvnc-1.3_alpha7-gentoo.diff
Comment 20 Raúl Porcel (RETIRED) gentoo-dev 2006-08-28 05:40:12 UTC
I think this is fixed with vnc-4.1.2. Try it.
Comment 21 Colin Macdonald 2006-08-28 21:09:12 UTC
Indeed vnc is fixed with vnc-4.1.2.  Tightvnc still has the problem.  There is a new devel version 3.8 available on their website but the changelog doesn't indicate that they've fixed the problem.
Comment 22 Raúl Porcel (RETIRED) gentoo-dev 2006-08-30 09:41:45 UTC
Well, in the case of tightvnc is something different. Tightvnc is supposed to work with X.org 6.3 and nothing else. You can't change the default paths without patching the source code. The vnc(4.1.2) package can do that through the configure script of the Xserver we want to use. Tightvnc ships a pre-configured and minimal Xserver, whilst vnc has to configure and compile a Xserver like if it was a real X server.

With both of the packages you need fonts and rgb installed in your system. And in the case of tightvnc, you need to patch the vncserver script, adding both the correct fontPath and rgbPath.

Btw, i'm reassigning bug to maintainer-needed since the x11 team has nothing to do with this bug. And changing the name also, because vnc does not have this bug.
Comment 23 Raúl Porcel (RETIRED) gentoo-dev 2006-10-05 11:45:59 UTC
Fixed on cvs, tightvnc-1.2.9-r3.