sunshine_august has asked for the wisdom of the Perl Monks concerning the following question:

Dear all monks:
I install Event::Lib on a 64-bit box, make test failed almost 100%:(:
t/80_processes.t 255 65280 ?? ?? % ?? t/90_leak.t 255 65280 ?? ?? % ?? t/91_leak.t 255 65280 ?? ?? % ?? t/92_leak.t 255 65280 ?? ?? % ?? t/93_leak.t 255 65280 ?? ?? % ?? 2 tests skipped. Failed 34/36 test scripts, 5.56% okay. 101/101 subtests failed, 0.00% +okay. make: *** [test_dynamic] Error 255 /usr/bin/make test -- NOT OK
Is Event::Lib not for 64bit box? and also I failed to make verify with the libevent-1.4.8-stable:
[root@localhost libevent-1.4.8-stable]# make verify cd test && make verify make[1]: Entering directory `/root/source/libevent-1.4.8-stable/test' Running tests: KQUEUE Skipping test DEVPOLL Skipping test POLL test-eof: OKAY test-weof: OKAY test-time: OKAY regress: type: 1, count: 1, ttl: 300: 152.160.49.201 type: 3, count: +1, ttl: 1800: 2001:1890:1112:1::20 FAILED SELECT test-eof: OKAY test-weof: OKAY test-time: OKAY regress: type: 1, count: 1, ttl: 285: 152.160.49.201 type: 3, count: +1, ttl: 1791: 2001:1890:1112:1::20 FAILED EPOLL test-eof: OKAY test-weof: OKAY test-time: OKAY regress: type: 1, count: 1, ttl: 275: 152.160.49.201 type: 3, count: +1, ttl: 1781: 2001:1890:1112:1::20 FAILED EVPORT Skipping test make[1]: Leaving directory `/root/source/libevent-1.4.8-stable/test'
I guess libEvent can't be used on 64bit box. If I am wrong, pls correct me.
thx in advance

Replies are listed 'Best First'.
Re: Does Event::Lib can be use on 64 bit box?
by poolpi (Hermit) on Sep 16, 2008 at 11:24 UTC

    Yes, with Linux debian 2.6.18-xen
    #1 SMP Fri May 18 16:01:42 BST 2007 x86_64 GNU/Linux

    #1) apt-get install libevent-dev
    #2) cpan[1]> install Event::Lib CPAN: Storable loaded ok (v2.18) Going to read /root/.cpan/Metadata Database was generated on Mon, 15 Sep 2008 04:02:50 GMT Running install for module 'Event::Lib' Running make for V/VP/VPARSEVAL/Event-Lib-1.03.tar.gz CPAN: Digest::SHA loaded ok (v5.45) CPAN: Compress::Zlib loaded ok (v2.012) Checksum for /root/.cpan/sources/authors/id/V/VP/VPARSEVAL/Event-Lib-1 +.03.tar.gz ok Scanning cache /root/.cpan/build for sizes ...................................................................... +......DONE Event-Lib-1.03/ Event-Lib-1.03/Changes Event-Lib-1.03/check.c Event-Lib-1.03/const-xs.inc Event-Lib-1.03/dhash.h Event-Lib-1.03/event_debug.h Event-Lib-1.03/fallback/ Event-Lib-1.03/fallback/const-c.inc Event-Lib-1.03/fallback/const-xs.inc Event-Lib-1.03/lib/ Event-Lib-1.03/lib/Event/ Event-Lib-1.03/lib/Event/Lib.pm Event-Lib-1.03/Lib.xs Event-Lib-1.03/Makefile.PL Event-Lib-1.03/MANIFEST Event-Lib-1.03/META.yml Event-Lib-1.03/ppport.h Event-Lib-1.03/README Event-Lib-1.03/scripts/ Event-Lib-1.03/scripts/client.pl Event-Lib-1.03/scripts/eprof Event-Lib-1.03/scripts/server.pl Event-Lib-1.03/t/ Event-Lib-1.03/t/00_pod.t Event-Lib-1.03/t/00_pod_coverage.t Event-Lib-1.03/t/01_event-lib.t Event-Lib-1.03/t/10_event.t Event-Lib-1.03/t/20_signal.t Event-Lib-1.03/t/30_timer.t Event-Lib-1.03/t/31_timer_one.t Event-Lib-1.03/t/32_timer_timeout.t Event-Lib-1.03/t/40_exception.t Event-Lib-1.03/t/41_exception.t Event-Lib-1.03/t/42_exception.t Event-Lib-1.03/t/43_exception.t Event-Lib-1.03/t/44_exception.t Event-Lib-1.03/t/45_exception.t Event-Lib-1.03/t/46_exception.t Event-Lib-1.03/t/47_exception_flags.t Event-Lib-1.03/t/50_cleanup.t Event-Lib-1.03/t/51_cleanup_persistent.t Event-Lib-1.03/t/52_cleanup_readded.t Event-Lib-1.03/t/53_cleanup_undef.t Event-Lib-1.03/t/54_cleanup_reassign.t Event-Lib-1.03/t/60_event_as_arg.t Event-Lib-1.03/t/61_events_in_struct.t Event-Lib-1.03/t/62_events_readded.t Event-Lib-1.03/t/63_events_readded.t Event-Lib-1.03/t/64_pending_events_destroyed.t Event-Lib-1.03/t/65_stress_no_clone.t Event-Lib-1.03/t/70_misc.t Event-Lib-1.03/t/71_misc.t Event-Lib-1.03/t/72_misc.t Event-Lib-1.03/t/73_misc.t Event-Lib-1.03/t/80_processes.t Event-Lib-1.03/t/90_leak.t Event-Lib-1.03/t/91_leak.t Event-Lib-1.03/t/92_leak.t Event-Lib-1.03/t/93_leak.t Event-Lib-1.03/typemap CPAN: File::Temp loaded ok (v0.18) CPAN: YAML loaded ok (v0.66) CPAN.pm: Going to build V/VP/VPARSEVAL/Event-Lib-1.03.tar.gz Checking existance of libevent...yes Checking capabilities... event_set_log_callback...yes event_priority_init...yes Additional defines: -DHAVE_LOG_CALLBACKS -DHAVE_PRIORITIES Checking if your kit is complete... Looks good Writing Makefile for Event::Lib cp lib/Event/Lib.pm blib/lib/Event/Lib.pm /usr/bin/perl /usr/share/perl/5.10/ExtUtils/xsubpp -typemap /usr/shar +e/perl/5.10/ExtUtils/typemap -typemap typemap Lib.xs > Lib.xsc && mv + Lib.xsc Lib.c cc -c -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe + -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 + -g -DVERSION=\"1.03\" -DXS_VERSION=\"1.03\" -fPIC "-I/usr/lib/perl +/5.10/CORE" -DHAVE_CONFIG_H -DHAVE_LOG_CALLBACKS -DHAVE_PRIORITIES +Lib.c Running Mkbootstrap for Event::Lib () chmod 644 Lib.bs rm -f blib/arch/auto/Event/Lib/Lib.so cc -shared -O2 -g -L/usr/local/lib Lib.o -o blib/arch/auto/Event/Lib +/Lib.so \ -levent -lm \ chmod 755 blib/arch/auto/Event/Lib/Lib.so cp Lib.bs blib/arch/auto/Event/Lib/Lib.bs chmod 644 blib/arch/auto/Event/Lib/Lib.bs Manifying blib/man3/Event::Lib.3pm VPARSEVAL/Event-Lib-1.03.tar.gz /usr/bin/make -- OK Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_h +arness(0, 'blib/lib', 'blib/arch')" t/*.t t/00_pod.........................ok + t/00_pod_coverage................ok + t/01_event-lib...................ok + t/10_event.......................ok + t/20_signal......................ok + t/30_timer.......................ok + t/31_timer_one...................ok + t/32_timer_timeout...............ok + t/40_exception...................ok + t/41_exception...................ok + t/42_exception...................ok + t/43_exception...................ok + t/44_exception...................ok + t/45_exception...................ok + t/46_exception...................ok + t/47_exception_flags.............ok + t/50_cleanup.....................ok + t/51_cleanup_persistent..........ok 2/6Test output counter mismatch [t +est 3] Test output counter mismatch [test 4] t/51_cleanup_persistent..........ok 5/6Test output counter mismatch [t +est 5] Test output counter mismatch [test 6] t/51_cleanup_persistent..........ok + t/52_cleanup_readded.............ok + t/53_cleanup_undef...............ok + t/54_cleanup_reassign............ok + t/60_event_as_arg................ok + t/61_events_in_struct............ok + t/62_events_readded..............ok + t/63_events_readded..............ok + t/64_pending_events_destroyed....ok + t/65_stress_no_clone.............ok + t/70_misc........................ok + t/71_misc........................ok + t/72_misc........................ok + t/73_misc........................ok + t/80_processes...................ok + t/90_leak........................ok + 1/1 skipped: various reasons t/91_leak........................ok + 1/1 skipped: various reasons t/92_leak........................ok + 1/1 skipped: various reasons t/93_leak........................ok + 1/1 skipped: various reasons All tests successful, 4 subtests skipped. Files=36, Tests=284, 50 wallclock secs ( 1.13 cusr + 0.41 csys = 1.5 +4 CPU) VPARSEVAL/Event-Lib-1.03.tar.gz /usr/bin/make test -- OK Running make install Prepending /root/.cpan/build/Event-Lib-1.03-xyJVqn/blib/arch /root/.cp +an/build/Event-Lib-1.03-xyJVqn/blib/lib to PERL5LIB for 'install' Files found in blib/arch: installing files in blib/lib into architectu +re dependent library tree Installing /usr/local/lib/perl/5.10.0/auto/Event/Lib/Lib.bs Installing /usr/local/lib/perl/5.10.0/auto/Event/Lib/Lib.so Installing /usr/local/lib/perl/5.10.0/Event/Lib.pm Installing /usr/local/man/man3/Event::Lib.3pm Writing /usr/local/lib/perl/5.10.0/auto/Event/Lib/.packlist Appending installation info to /usr/local/lib/perl/5.10.0/perllocal.po +d VPARSEVAL/Event-Lib-1.03.tar.gz /usr/bin/make install -- OK

    Update:

    # gcc -v Using built-in specs. Target: x86_64-linux-gnu Configured with: ../src/configure -v --enable-languages=c,c++,fortran, +objc,obj-c++ --prefix=/usr --enable-shared --with-system-zlib --libex +ecdir=/usr/lib --without-included-gettext --enable-threads=posix --en +able-nls --with-gxx-include-dir=/usr/include/c++/4.2 --program-suffix +=-4.2 --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc +--enable-mpfr --enable-checking=release --build=x86_64-linux-gnu --ho +st=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version 4.2.4 (Debian 4.2.4-3)

    hth,
    PooLpi

    'Ebry haffa hoe hab im tik a bush'. Jamaican proverb
Re: Does Event::Lib can be use on 64 bit box?
by sunshine_august (Scribe) on Sep 17, 2008 at 04:15 UTC
    I can't install Event::Lib for this reason:
    Can't load '/root/.cpan/build/Event-Lib-1.03/blib/arch/auto/Event/Lib/Lib.so' for module Event::Lib:
    the Lib.so exists in the right place:
    [root@localhost ~]# ls -ld /root/.cpan/build/Event-Lib-1.03/blib/arch/ +auto/Event/Lib/Lib.so -rwxr-xr-x 1 root root 142438 Sep 17 12:07 /root/.cpan/build/Event-Li +b-1.03/blib/arch/auto/Event/Lib/Lib.so
    I don't know why Event::Lib can't load this Lib.so.
    following is a more detail install log:
    ....... Checking existance of libevent...yes Checking capabilities... event_set_log_callback...yes event_priority_init...yes Additional defines: -DHAVE_LOG_CALLBACKS -DHAVE_PRIORITIES Checking if your kit is complete... Looks good Note (probably harmless): No library found for -levent Writing Makefile for Event::Lib cp lib/Event/Lib.pm blib/lib/Event/Lib.pm /usr/bin/perl /usr/lib/perl5/5.8.8/ExtUtils/xsubpp -typemap /usr/lib/ +perl5/5.8.8/ExtUtils/typemap -typemap typemap Lib.xs > Lib.xsc && mv + Lib.xsc Lib.c gcc -c -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -Wdecla +ration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FI +LE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe -m64 -DVERSION= +\"1.03\" -DXS_VERSION=\"1.03\" -fPIC "-I/usr/lib64/perl5/5.8.8/x86_64 +-linux-thread-multi/CORE" -DHAVE_CONFIG_H -DHAVE_LOG_CALLBACKS -DHAV +E_PRIORITIES Lib.c Running Mkbootstrap for Event::Lib () chmod 644 Lib.bs rm -f blib/arch/auto/Event/Lib/Lib.so gcc -shared Lib.o -o blib/arch/auto/Event/Lib/Lib.so \ -lm \ chmod 755 blib/arch/auto/Event/Lib/Lib.so cp Lib.bs blib/arch/auto/Event/Lib/Lib.bs chmod 644 blib/arch/auto/Event/Lib/Lib.bs Manifying blib/man3/Event::Lib.3pm /usr/bin/make -- OK Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_h +arness(0, 'blib/lib', 'blib/arch')" t/*.t t/00_pod.........................ok t/00_pod_coverage................ok t/01_event-lib...................Can't load '/root/.cpan/build/Event-L +ib-1.03/blib/arch/auto/Event/Lib/Lib.so' for module Event::Lib: /root +/.cpan/build/Event-Lib-1.03/blib/arch/auto/Event/Lib/Lib.so: undefine +d symbol: event_loop at /usr/lib64/perl5/5.8.8/x86_64-linux-thread-mu +lti/DynaLoader.pm line 230. at t/01_event-lib.t line 10 Compilation failed in require at t/01_event-lib.t line 10. BEGIN failed--compilation aborted at t/01_event-lib.t line 10. t/01_event-lib...................dubious Test returned status 2 (wstat 512, 0x200) DIED. FAILED tests 1-2 Failed 2/2 tests, 0.00% okay t/10_event.......................Can't load '/root/.cpan/build/Event-L +ib-1.03/blib/arch/auto/Event/Lib/Lib.so' for module Event::Lib: /root +/.cpan/build/Event-Lib-1.03/blib/arch/auto/Event/Lib/Lib.so: undefine +d symbol: event_loop at /usr/lib64/perl5/5.8.8/x86_64-linux-thread-mu +lti/DynaLoader.pm line 230. at t/10_event.t line 3 Compilation failed in require at t/10_event.t line 3. BEGIN failed--compilation aborted at t/10_event.t line 3. .......
    I can't figure out what is wrong. some hint?
      The hint is this:
      Note (probably harmless): No library found for -levent
      Install Event::Lib on my box thru CPAN module reports "No library found for -levent" , so I tried to install it thru source,and specified the location of libevent.so like:
      perl Makefile.PL INC=-I/usr/local/include LIBS="-L/usr/local/lib -leve +nt"
      then all the test is successful.
      Although make test with Event::Lib successfully, 'make verify' with libevent still reports FAILED, this is weird.
      Whatever, Event::Lib can work well in my box now:)