Segmentation violation opening TBrowser

Hello,

I had some problems with root, i.e. when using the TBrowser I get a segmentation violation.
The output I get is this:

[code]Error in TGVScrollBar::TGVScrollBar: arrow_*.xpm not found

*** Break *** segmentation violation
[/code]

After having searched the forum I found some suggestions how to solve this problem, but none worked.
I tried installing root with the $ROOTSYS variable, as well as with the “prefix” option.
Both did result in the same segmentation violation.
Using TBrowser t; or TBrowser() or any other way to use a TBrowser ended with a segmentation violation.

Currently i have installed root with the $ROOTSYS option. The root version is the current cvs head from monday the 26 (before I had the official 5.14/00 version with the same problem) .
The system I am running here is a debian etch with a gcc version 4.1.2.

I checked that the icons are at the place where they should be $ROOTSYS/icons/ .
Also in $ROOTSYS/etc/system.rootrc is setup correctly:

Then I compiled with build=debug option and got from gdb this:

Program received signal SIGSEGV, Segmentation fault.
0xb5f7d2d7 in TGVScrollBar::SetPosition (this=0x839e820, pos=0)
    at gui/src/TGScrollBar.cxx:778
778        fSlider->MoveResize(0, fY0, fgScrollBarWidth, fSliderSize);

I didn’t understand what is wrong with this: fSlider->MoveResize(0, fY0, fgScrollBarWidth, fSliderSize);

Backtracing with gdb gave that output:

(gdb) bt
#0  0xb5f7d2d7 in TGVScrollBar::SetPosition (this=0x839e820, pos=0)
    at gui/src/TGScrollBar.cxx:778
#1  0xb5f2db0e in TGListBox::Layout (this=0x839e540)
    at gui/src/TGListBox.cxx:1448
#2  0xb5f0ea0c in TGFrame::Resize (this=0x839e540, w=100, h=100)
    at gui/src/TGFrame.cxx:533
#3  0xb5f2e765 in TGListBox::Resize (this=0x839e540, w=100, h=100)
    at gui/src/TGListBox.cxx:1372
#4  0xb5ee28fc in TGComboBox::Init (this=0x8376708)
    at gui/src/TGComboBox.cxx:219
#5  0xb5ee3711 in TGComboBox (this=0x8376708, p=0x83764f8, id=33,
    options=1068, back=16777215) at gui/src/TGComboBox.cxx:153
#6  0xb5f145cd in TGFSComboBox (this=0x8376708, parent=0x83764f8, id=33,
    options=44, back=16777215) at gui/src/TGFSComboBox.cxx:221
#7  0xb5fdce55 in TRootBrowser::CreateBrowser (this=0x8371570,
    name=0xb7d5bcb1 "ROOT Object Browser") at gui/src/TRootBrowser.cxx:994
#8  0xb5fdee55 in TRootBrowser (this=0x8371570, b=0x821a8d8,
    name=0xb7d5bcb1 "ROOT Object Browser", width=703, height=439)
    at gui/src/TRootBrowser.cxx:816
#9  0xb5ff2211 in TRootGuiFactory::CreateBrowserImp (this=0x82d63a0,
    b=0x821a8d8, title=0xb7d5bcb1 "ROOT Object Browser", width=703, height=439)
    at gui/src/TRootGuiFactory.cxx:76
#10 0xb792a408 in TBrowser (this=0x821a8d8, name=0xb7d5bcc5 "Browser",
    title=0xb7d5bcb1 "ROOT Object Browser") at base/src/TBrowser.cxx:103
#11 0xb7ac2565 in G__G__Base1_63_0_3 () from /usr/local/root/lib/libCore.so
#12 0xb72aea72 in Cint::G__ExceptionWrapper (
    funcp=0xb7ac2074 <G__G__Base1_63_0_3(G__value*, char const*, G__param*, int) >, result7=0xbfe0a354, funcname=0x82187f8 "\001", libp=0xbfe068b0, hash=0)
    at cint/src/Api.cxx:355
#13 0xb73982e2 in G__call_cppfunc (result7=0xbfe0a354, libp=0xbfe068b0,
    ifunc=0x82187f8, ifn=0) at cint/src/v6_newlink.cxx:465
#14 0xb736671e in G__interpret_func (result7=0xbfe0a354,
    funcname=0xbfe09e54 "TBrowser", libp=0xbfe068b0, hash=824,
    p_ifunc=0x82187f8, funcmatch=1, memfunc_flag=4)
    at cint/src/v6_ifunc.cxx:5174
#15 0xb7358a01 in G__getfunction (item=0xbfe0ab94 "TBrowser()",
    known3=0xbfe0b7c8, memfunc_flag=4) at cint/src/v6_func.cxx:2600
#16 0xb7329364 in G__define_var (tagnum=61, typenum=-1)
    at cint/src/v6_decl.cxx:2072
#17 0xb73edfa3 in G__defined_type (type_name=0xbfe0c44c "TBrowser", len=8)
    at cint/src/v6_typedef.cxx:1533
#18 0xb73a885a in G__exec_statement () at cint/src/v6_parse.cxx:3872
#19 0xb73211dc in G__exec_tempfile_core (
    file=0xbfe1548c "/home/lenz/./test.C", fp=0x0) at cint/src/v6_debug.cxx:358
#20 0xb7321427 in G__exec_tempfile (file=0xbfe1548c "/home/lenz/./test.C")
    at cint/src/v6_debug.cxx:433
---Type <return> to continue, or q <return> to quit---
#21 0xb73b7b9a in G__process_cmd (line=0xb7eafd38 ".x /home/lenz/./test.C",
    prompt=0x80c4d6c "", more=0x80c4d64, err=0xbfe1611c, rslt=0xbfe160f8)
    at cint/src/v6_pause.cxx:3218
#22 0xb79c61c2 in TCint::ProcessLine (this=0x80c4d48,
    line=0xb7eafd38 ".x /home/lenz/./test.C", error=0x0)
    at meta/src/TCint.cxx:318
#23 0xb79c15a4 in TCint::ProcessLineSynch (this=0x80c4d48,
    line=0xb7eafd38 ".x /home/lenz/./test.C", error=0x0)
    at meta/src/TCint.cxx:351
#24 0xb791c606 in TApplication::ProcessFile (this=0x80f22f8,
    name=0x82194eb "test.C", error=0x0) at base/src/TApplication.cxx:830
#25 0xb791d008 in TApplication::ProcessLine (this=0x80f22f8,
    line=0x82194e8 ".x test.C", sync=false, err=0x0)
    at base/src/TApplication.cxx:701
#26 0xb72348f8 in TRint::HandleTermInput (this=0x80f22f8)
    at rint/src/TRint.cxx:509
#27 0xb723433e in TTermInputHandler::Notify (this=0x81ea290)
    at rint/src/TRint.cxx:121
#28 0xb7236d8a in TTermInputHandler::ReadNotify (this=0x81ea290)
    at rint/src/TRint.cxx:113
#29 0xb79fc8f3 in TUnixSystem::CheckDescriptors (this=0x80c1578)
    at unix/src/TUnixSystem.cxx:1054
#30 0xb79fd074 in TUnixSystem::DispatchOneEvent (this=0x80c1578,
    pendingOnly=false) at unix/src/TUnixSystem.cxx:753
#31 0xb797da57 in TSystem::InnerLoop (this=0x80c1578)
    at base/src/TSystem.cxx:346
#32 0xb79894d9 in TSystem::Run (this=0x80c1578) at base/src/TSystem.cxx:314
#33 0xb791b54e in TApplication::Run (this=0x80f22f8, retrn=false)
    at base/src/TApplication.cxx:849
#34 0xb72357b1 in TRint::Run (this=0x80f22f8, retrn=false)
    at rint/src/TRint.cxx:368
#35 0x08048d4d in main (argc=1, argv=0xbfe16e24) at main/src/rmain.cxx:29

I hope someone can help me now, because I am stuck.
All help is highly appreciated.

Thanks,
Daniel

Hi Daniel,

Do you have enabled asimage plugin? Also make sure that all environment settings are correct after you had tried to install ROOT with $ROOTSYS and with -prefix.

Cheers, Ilka
++ I will copy below the advice given by Fons several times:[quote]for personal usage of ROOT I advice to install it in ~. Just do:

cd root
./configure
make
make install

Before running do:

. bin/thisroot.sh
[/quote]

Hi Ilka,

the asimage plugin is enabled, also all environment variables are ok.
As far as I understand the script bin/thisroot.csh does only check the environment variables and set them correctly.
Anyways, I tried that and still the same error.

I also aready tried installing root into my homedirectory, although I don’t see any difference in the way root should work depending on the installation directory.

Do you have any other ideas?

Cheers,
Daniel

Hi Daniel,

Only one left - try to install root in your home directory. If it is already there, clean and rebuild it again by:make distclean make

Cheers, Ilka

Hi Ilka,

thanks for your fast help, but unfortunatly installing root into ~/ didn’t help. The

make distclean 
make

didn’t change anything either.
I still have the same error.

:frowning:

Nothing else I could try?

Cheers,
Daniel

Hi Daniel,

I will point this post to Christian Holm Christensen who knows best the build system and the debian port of root.

Cheers, Ilka

Ok, thanks.

I forgot to say that ‘TBrowser b’ and ‘new TBrowser()’ work fine for me on linux.

Cheers, Ilka

Hi,

First off, let me suggest that you take the pre-built packages at

to see if you get the same problem. These packages are or ROOT 5.13/07 (close to 5.14/00), and they should work with etch (assuming it’s fairly up to date).

Secondly, check that you do not have some older ROOT libraries lying around that is accedently picked up (check with ldd root.exe). If you do, remove those.

Thirdly, check that have the right settings in your system.rootrc, ~/.rootrc, and/or ./.rootrc file.

Note, that if you build with –prefix set, then you should not set the environment variable ROOTSYS.

Also check, that the contents of include/config.h is correct.

Yours,

Christian

Hi Christian,

using

worked if I install the root-plugin-asimage, otherwise I get the same segmentation violation.
Thanks for that, now I have a working enironment. (btw. there was a typo in the “adress” just in case someone else tries that.)

The other things you suggested where all ok. I mean root was linked correctly, the settings in rootrc were ok as well and include/config.h is obsolete, but in include/RConfigure.h everything is set properly.

Also I didn’t set the $ROOTSYS when compiling with the prefix option.

So I’m still confused where this segmentation violation actually came from and I think this shouldn’t happen. So what is the main difference to the binary packages? I would still like to install it properly from sources.

Cheers,
Daniel