egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Error 127

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help
View previous topic :: View next topic  
Author Message
kris0089
Voice


Joined: 26 Jan 2008
Posts: 1

PostPosted: Sat Jan 26, 2008 6:52 pm    Post subject: Error 127 Reply with quote

Hello, im installing eggdrop (Current version), and on installation i have recieved a error, a tad annoying as i have installed eggdrops before.

My Os is: Knoppix v5.1.17, HDD installation (So basicly debian)

my error:

Quote:


All modules compiled.
make[1]: Leaving directory `/home/NoMansLand/eggdrop/eggdrop1.6.18/eggdrop1.6.18/src/mod'

Test run of ./eggdrop -v:
./eggdrop: error while loading shared libraries: libtcl8.5.so: cannot open shared object file: No such file or directory
make: *** [modules] Error 127


TCL is installed at /local/lib/tcl8 and local/lib/tcl8.5

Thank you

kris0089
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sat Jan 26, 2008 8:47 pm    Post subject: Reply with quote

Seems your /etc/ld.so.conf needs to be set up properly and/or you need to run ldconfig.

Make sure there's a line reading /local/lib/tcl8.5 within your /etc/ld.so.conf file, and run ldconfig to update the database of loadable modules (must be run with root privs).
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
YooHoo
Owner


Joined: 13 Feb 2003
Posts: 939
Location: Redwood Coast

PostPosted: Sat Jan 26, 2008 8:52 pm    Post subject: Reply with quote

solution courtesy of johoho:

'./configure' is looking in the wrong place for Tcl; it looks like it compiled with one version of Tcl and tries to load another. Maybe your sysadmin upgraded Tcl and didn't tell you. In that case, you should just need to recompile your bot.

Or maybe when upgrading he didn't clean the old version of Tcl, and './configure' is looking for the files in the wrong places, or trying to use different versions of tcl.h and libtcl*. Smack your admin and have him install Tcl properly Wink Or try to:

./configure --with-tcllib=<path-to-tcl-lib> --with-tclinc=<path-to-tcl-inc>

Tell configure where to look for the Tcl files.

Try looking for libtcl by:
ls /usr/lib/libtcl*
ls /usr/local/lib/libtcl*

Try looking for tcl.h by:
ls /usr/include/*/tcl.h
ls /usr/local/include/*/tcl.h

If everything else fails, try to install Tcl to your home dir Wink
_________________
Mr. Green
Johoho's TCL for beginners
Mr. Green
Back to top
View user's profile Send private message Send e-mail
StarLion
Voice


Joined: 20 Dec 2005
Posts: 16

PostPosted: Thu Feb 14, 2008 3:01 pm    Post subject: Reply with quote

I had this issue also... but found a resolution;

I assume most people have done the default install of TCL.
Copy your libtcl8.5.so file from /usr/local/lib/ to /lib/
Run ldconfig (mine was /sbin/ldconfig)
Retry the configure/make config/make process. Eggdrop should find the file.

(if this doesnt work for you, notice where your OS is pulling the other library files from when you do ldd eggdrop, and put the file there instead)
Back to top
View user's profile Send private message
coldair
Voice


Joined: 25 Feb 2008
Posts: 3

PostPosted: Mon Feb 25, 2008 6:20 pm    Post subject: Reply with quote

Quote:

Make sure there's a line reading /local/lib/tcl8.5 within your /etc/ld.so.conf file, and run ldconfig to update the database of loadable modules (must be run with root privs).


Great!
If I'll have root privs on that machine, there will be no problem.
Spent a lot of time trying to understand why linker/compiler ignores -I and -L params and --with-tcllib, --with-tclinc in configure.
strace ./eggdrop -v show us, that even if -I .... and -L.. was used correctly in compiling, eggdrop binary ignores that and wont search library in the defined path.

"
Linking eggdrop (standard build).

gcc -pipe -o ../eggdrop bg.o botcmd.o botmsg.o botnet.o chanprog.o cmds.o dcc.o dccutil.o dns.o flags.o language.o match.o main.o mem.o misc.o misc_file.o modules.o net.o rfc1459.o tcl.o tcldcc.o tclhash.o tclmisc.o tcluser.o userent.o userrec.o users.o -L/home/clients/websites/w_arsigr/opt/tcl/current/lib -ltcl8.5 -lm -ldl -lnsl md5/md5c.o compat/*.o `cat mod/mod.xlibs`
touch ../eggdrop

Successful compile: eggdrop
"

... but still 127:

"
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=13970, ...}) = 0
old_mmap(NULL, 13970, PROT_READ, MAP_PRIVATE, 3, 0) = 0x127000
close(3) = 0
open("/lib/tls/sse2/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/lib/tls/sse2", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/lib/tls/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/lib/tls", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/lib/sse2/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/lib/sse2", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/lib/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/lib", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open("/usr/lib/tls/sse2/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/tls/sse2", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/usr/lib/tls/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/tls", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/usr/lib/sse2/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/sse2", 0xbfffec64) = -1 ENOENT (No such file or directory)
open("/usr/lib/libtcl8.5.so", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/usr/lib", {st_mode=S_IFDIR|0755, st_size=8192, ...}) = 0
writev(2, [{"./eggdrop", 9}, {": ", 2}, {"error while loading shared libra"..., 36}, {": ", 2}, {"libtcl8.5.so", 12}, {": ", 2}, {"cannot open shared object file", 30}, {": ", 2}, {"No such file or directory", 25}, {"\n", 1}], 10./eggdrop: error while loading shared libraries: libtcl8.5.so: cannot open shared object file: No such file or directory
) = 121
exit_group(127) = ?
Process 22023 detached
"
Back to top
View user's profile Send private message
strikelight
Owner


Joined: 07 Oct 2002
Posts: 708

PostPosted: Mon Feb 25, 2008 7:28 pm    Post subject: Reply with quote

coldair: then either contact the admin to install tcl properly (ldconfig), or compile Tcl locally under your user account, making sure to configure it for static (disable-shared) build, and then rebuild your eggdrop as well, with configure pointing to where your Tcl library and header files reside, also configuring it to be a static build.
Back to top
View user's profile Send private message Visit poster's website
coldair
Voice


Joined: 25 Feb 2008
Posts: 3

PostPosted: Mon Feb 25, 2008 7:36 pm    Post subject: Reply with quote

strikelight wrote:
coldair: then either contact the admin to install tcl properly (ldconfig), or compile Tcl locally under your user account, making sure to configure it for static (disable-shared) build, and then rebuild your eggdrop as well, with configure pointing to where your Tcl library and header files reside, also configuring it to be a static build.


Heh. As i've told already, i did exactly what u say. We have no tcl globally installed on the server, so I've made locally.
eggdrop still return with error 127 (look at strace output).

Fix me if i'm wrong, but enable-shared build of tcl or eggdrop have nothing to do with a problem i'm talking about.
Back to top
View user's profile Send private message
strikelight
Owner


Joined: 07 Oct 2002
Posts: 708

PostPosted: Mon Feb 25, 2008 7:37 pm    Post subject: Reply with quote

coldair wrote:
strikelight wrote:
coldair: then either contact the admin to install tcl properly (ldconfig), or compile Tcl locally under your user account, making sure to configure it for static (disable-shared) build, and then rebuild your eggdrop as well, with configure pointing to where your Tcl library and header files reside, also configuring it to be a static build.


Heh. As i've told already, i did exactly what u say. We have no tcl globally installed on the server, so I've made locally.
eggdrop still return with error 127 (look at strace output).

Fix me if i'm wrong, but enable-shared build of tcl or eggdrop have nothing to do with a problem i'm talking about.


Ok... You're wrong.
Back to top
View user's profile Send private message Visit poster's website
coldair
Voice


Joined: 25 Feb 2008
Posts: 3

PostPosted: Mon Feb 25, 2008 7:48 pm    Post subject: Reply with quote

strikelight wrote:

Ok... You're wrong.


You've right Smile
Static build solved a problem. probably i've missed something during my tries. Sorry for wasting your time.
Thanks for your help.
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Mon Feb 25, 2008 11:48 pm    Post subject: Reply with quote

If you did a local install, you'll have to set LD_LIBRARY_PATH environment variable to point to the location of your tcl-libraries whenever starting your eggie - should you link tcl dynamically. Of course, linking statically is always an option if you can live with the larger binaries.
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
rosc2112
Revered One


Joined: 19 Feb 2006
Posts: 1454
Location: Northeast Pennsylvania

PostPosted: Tue Feb 26, 2008 2:29 am    Post subject: Reply with quote

Compiling statically linked binaries makes it include the lib in the binary.. Makes it much larger. I'd us the LD_LIBRARY_PATH var and compile it dynamically. Just FYI.
Back to top
View user's profile Send private message
strikelight
Owner


Joined: 07 Oct 2002
Posts: 708

PostPosted: Tue Feb 26, 2008 1:53 pm    Post subject: Reply with quote

From the previous two comments you'd think it was producing a 100mb file, which it clearly does not. And if you want to compare advantages to disadvantages, you won't have to worry about security issues such as a comprimised shared module by using a static link. You also will be able to use the default botchk script with cron without any code modification, as you won't have to specify the LD_LIBRARY_PATH environment variable prior to every launch of eggdrop. Also more about the size, if you need to compile Tcl locally anyway, you are not losing any extra space, since that space would be occupied by the shared libraries as well, lol. "Just FYI".
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber