I am trying to run the Pythia example from the tutorial page. I use the following commands at the ROOT command line:

root [0] .L pythiaExample.C
root [1] makeEventSample(1000)

I getan error that says

"Error in TUnixSystem::DynamicPathName: libPythia6[.so |.sl | .dl | .a| .dll] does not exist in .:/home/root/lib
dlopen error: No such file or directory
Load Error: Failed to load Dynamic link library /home/root/lib/libEGPythia6.dll (int) (-1)
*** Interpreter error recovered ***

However, if I go to C:\cygwin\home\root\lib, I do indeed have a file called libEGPythia6.dll and another called libEGPythia6.dll.a . These files are both 469 bytes and appear non-empty when opened in notepad.

I downloaded the pythiaExample.C code from the Internet and saved it into C:\cygwin\home\root\macros as a .C file.

I have ROOT 4.04 on Cygwin-NT-5.1 on Windows XP Pro. At the beginning when I first start Cygwin, I set the paths to

export ROOTSYS=/home/root
export PATH=$PATH:$ROOTSYS/bin

I have tried reparing it using chmod a+x %ROOTSYS/lib/*.dll from the command line in Cygwin. I’ve also tried

cd $ROOTSYS/lib
for f in …/bin/*.dll; do ln -fs $f; ln -fs $f $(basename $f).a; done

but this doesn’t work either.

Please help? Thank you!


do you have the file /home/root/bin/libPhythia6.dll (that’s where /home/root/lib/libPhythia6.dll points to)? Where did you get it from?

If you build it yourself you should use
(used to be ftp; I have updated link on 2016-04-12)


I have /home/root/bin/libEGPythia6.dll but not /home/root/bin/libPythia6.dll

Where do I get this latter file?

I have gotten the .tar.gz file off of the ftp server. Now how do I install it properly?


I did something like this on Linux, so I’m not sure it will work on Cygwin.

cd /usr/local
mkdir pythia6
cd pythia6
tar zxvf pythia6.tar.gz
source Makefile.linux
export PYTHIA6=/usr/local/pythia6

Also, recompile Root after letting Root’s configure script know where it is installed. If possible, do a ldconfig also (works on Windows?). I think there’s a README in the tarball; have a look.

Note that Root 4.03 doesn’t work well with the Pythia 6.2. I strongly recommend you download the latest versions (Pythia 6.3 from the ftp place above, and Root 4.04/02b).

Hope this helps.

I did this, and got to the command


however, this command fails. I get the following warnings:

f771warning: -fPIC ignored for target (all code is position independent)
pythia6319.f: In bock-data unit ‘pydata’"
COMMON/(^)PYDAT3/MDCY(500,3), MDME(8000,2), BRAT(8000), KFDP(8000,5)
Initialization of large (294000-unit) aggregate area pydat3 at (^) slow and takes lots of memory during g77 complie

(that thing two more times for different locations)
g77: Installation problem, cannot exec 'as": no such file or directory
g77:Installation problem, cannot exec ‘cc1’ : no such file or directory
bash: gcc: command not found
bash: gcc: command not found
g77: main.o: no such file or directory
g77: tpythia6_called_from_cc.o: no such file or directory
g77: pythia*.o : no such file or directory

then it dies.

I have g77 and I’m pretty sure that I also pulled down g++ when I got cigwin. I checked earlier today and it said I had it. Now what?

run ./makePythia6.wingcc

Okay, so I tried run ./makePythia6.wingcc and got the following error:

In a Windows Popup Window: Error: Could not start C:\cygwin\home\pythia6\pythia6\makePythia6.wingcc

Then I tried just typing makePythia6.wingcc and got the same errors as before, where it takes too much memory and then gives the same g77 and gcc errors.

Now what?

Thanks for your help. I apologize for my delayed response but I was in Berlin visiting family.

You must start ./makePythia6.wingcc from a bash shell or an xterm. I cannot reproduce what you see - do you have cygwin’s g77 and gcc (non-mingw) installed? You can ignore g77’s warnings about mem usage.

I went to Cygwin and downloaded anything having anythign to do with gcc-g77. Then I tried again. This time I get an error that says

./makePythia6.wingcc: line 4: /home/root/build/unix/ No such file or directory.

ln: creating symbolic link ‘libPythia6.dll.a’ to ‘libPythia6.dll’: File exists.

Then it exits. But when I try running the example according to the webpage, it gives the same error as before.

you can use the attached file; just save it to /home/root/build/unix/ You can ignore ln’s “file exists” warning.
Axel. (624 Bytes)

I put that file in that directory, though I had to create all of the directories starting with /build/. There was no build directory.

Then the makePythia6.wingcc ran successfully.

However, when I started root and tried the two commands from the beginning of the tutorial (.L pythiaExample.C and makeEventSample(1000)), it still said that the pythia6 library did not exist.


as far as I know you need libPythia6.dll (the lib you just built) to build root’s own libEGPythia6.dll. You need the root source distrib, and you need to ./configure --enable-pythia6 --with-pythia6-libdir=/wherever/you/built/the/pythia6-dll

Or you can just use the attached libEGPythia6.dll. Run

cd $ROOTSYS mv some_dir/root_pythia6_win32gcc.tar.txt some_dir/root_pythia6_win32gcc.tar.bz2 tar xjf some_dir/root_pythia6_win32gcc.tar.bz2 where some_dir is the dir you’ve downloaded the attached root_pythia6_win32gcc.tar.bz2 to.

I’m using root 5.03/01 from June 29; as you are using a different version the attached dlls might or might not work. If they don’t work, you’ll have to build root from sources.

Cheers, Axel.

I downloaded the file and saved it in /home/pythia6.

Then I changed the file name to .tar.bz2.

Then I changed directory to $ROOTSYS and ran
tar xjf /home/pythia6/root_pythia6_win32gcc.tar.bz2

and it said:

bzip2 (stdin) is not a bzip2 file
tar: Child returned status 2
tar: Error exit delayed from previous errors.

My guess is this means it didn’t work.

here’s a tar.gz, which you extract using tar xzf, instead of tar xjf. Probably renaming it to .txt (to get around the phpBB2 attachment filter) wasn’t such a good idea…
root_pythia6_win32gcc.tar.gz (441 KB)

Downloaded the new file. Saved it in the home directory. Used gunzip and tar to extract it. It created a new directory bin which contains libEG.dll and libEGPythia6.dll. Then I opened root and tried to run the commands again. The error returned is

dlopen error: No such process
Load Error: Failed to load Dynamic link library /home/bin/./libEG.dll
(int) (-1)

Please cd into $ROOTSYS before unpacking the tar.gz (as I said in my post). The files should be created in the bin and lib subdirs of ROOTSYS.

Okay, I untar-ed the file in $ROOTSYS. The end result is that it’s still broken, but the error it returns this time is

dlopen error: no such process
Load Error: Failed to load dynamic link library /home/root/lib/libEG.dll

Argh. This is getting frustrating.


well - cygwin is for testing, not for production. I’m doing my best here… Anyway:

copy the libPythia6.dll you’ve built into $ROOTSYS/bin/

start root

works for me.

I have a libEG.dll, and a libEGPythia6.dll. Where is this libPythia6.dll?

I checked /home/root/bin and home/root/lib and both libEG.dll and libEGPythia6.dll are there. However when i try the gSystem->Load(“libEG.dll”) it says

dlopen error: no such process
Load Error: Failed to load dynamic link library /home/root/lib/libEG.dll

Thanks for helping with this, Axel.