Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^2: Installing Perl Wrapper Module for a C Library (Tree::Suffix) Locally

by monkfan (Curate)
on Mar 15, 2006 at 15:28 UTC ( [id://536840]=note: print w/replies, xml ) Need Help??


in reply to Re: Installing Perl Wrapper Module for a C Library (Tree::Suffix) Locally
in thread Installing Perl Wrapper Module for a C Library (Tree::Suffix) Locally

I would very much like to see the first error that the CPAN shell gets
Hi fizbin,
This is the error I got:
cpan> install Tree::Suffix CPAN: Storable loaded ok Going to read /home/monkfan/.cpan/Metadata Database was generated on Tue, 14 Mar 2006 16:19:09 GMT Running install for module Tree::Suffix Running make for G/GR/GRAY/Tree-Suffix-0.12.tar.gz CPAN: Digest::MD5 loaded ok CPAN: Compress::Zlib loaded ok Checksum for /home/monkfan/.cpan/sources/authors/id/G/GR/GRAY/Tree-Suf +fix-0.12.tar.gz ok Scanning cache /home/monkfan/.cpan/build for sizes Tree-Suffix-0.12/ Tree-Suffix-0.12/Changes Tree-Suffix-0.12/MANIFEST Tree-Suffix-0.12/META.yml Tree-Suffix-0.12/Makefile.PL Tree-Suffix-0.12/README Tree-Suffix-0.12/Suffix.xs Tree-Suffix-0.12/lib/ Tree-Suffix-0.12/lib/Tree/ Tree-Suffix-0.12/lib/Tree/Suffix.pm Tree-Suffix-0.12/ppport.h Tree-Suffix-0.12/t/ Tree-Suffix-0.12/t/00_load.t Tree-Suffix-0.12/t/01_new.t Tree-Suffix-0.12/t/02_insert.t Tree-Suffix-0.12/t/03_lcs.t Tree-Suffix-0.12/t/04_lrs.t Tree-Suffix-0.12/t/05_clear.t Tree-Suffix-0.12/t/06_remove.t Tree-Suffix-0.12/t/07_memleak.t Tree-Suffix-0.12/t/08_find.t Tree-Suffix-0.12/t/09_duplicates.t Tree-Suffix-0.12/t/10_pod.t Tree-Suffix-0.12/t/11_pod_coverage.t Tree-Suffix-0.12/t/12_string.t Removing previously used /home/ewijaya/.cpan/build/Tree-Suffix-0.12 CPAN.pm: Going to build G/GR/GRAY/Tree-Suffix-0.12.tar.gz Checking if your kit is complete... Looks good Note (probably harmless): No library found for -lstree Writing Makefile for Tree::Suffix /usr/bin/perl /usr/lib/perl5/5.8.5/ExtUtils/xsubpp -typemap /usr/lib/ +perl5/5.8.5/ExtUtils/typemap Suffix.xs > Suffix.xsc && mv Suffix.xsc + Suffix.c Running Mkbootstrap for Tree::Suffix () gcc -c -D_REENTRANT -D_GNU_SOURCE -DDEBUGGING -fno-strict-aliasing - +pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 +-I/usr/include/gdbm -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 - +DVERSION=\"0.12\" -DXS_VERSION=\"0.12\" -fPIC "-I/usr/lib/perl5/5.8.5 +/i386-linux-thread-multi/CORE" Suffix.c chmod 644 Suffix.bs cp Suffix.bs blib/arch/auto/Tree/Suffix/Suffix.bs chmod 644 blib/arch/auto/Tree/Suffix/Suffix.bs cp lib/Tree/Suffix.pm blib/lib/Tree/Suffix.pm Suffix.xs:6:22: libstree.h: No such file or directory Suffix.xs:19: error: syntax error before '*' token Suffix.xs:20: error: syntax error before '*' token Suffix.xs: In function `follow_string': Suffix.xs:21: error: `LST_Node' undeclared (first use in this function +) Suffix.xs:21: error: (Each undeclared identifier is reported only once Suffix.xs:21: error: for each function it appears in.) Suffix.xs:21: error: `node' undeclared (first use in this function) Suffix.xs:21: error: `tree' undeclared (first use in this function) Suffix.xs:22: error: `LST_Edge' undeclared (first use in this function +) Suffix.xs:22: error: `edge' undeclared (first use in this function) Suffix.xs:24: error: `string' undeclared (first use in this function) Suffix.xs: In function `XS_Tree__Suffix_new': Suffix.xs:54: error: `LST_STree' undeclared (first use in this functio +n) Suffix.xs:54: error: `tree' undeclared (first use in this function) Suffix.xs: In function `XS_Tree__Suffix_DESTROY': Suffix.xs:78: error: `LST_STree' undeclared (first use in this functio +n) Suffix.xs:78: error: `tree' undeclared (first use in this function) Suffix.xs:80: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_allow_duplicates': Suffix.xs:90: error: `LST_STree' undeclared (first use in this functio +n) Suffix.xs:90: error: `tree' undeclared (first use in this function) Suffix.xs:92: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_insert': Suffix.xs:105: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:105: error: `tree' undeclared (first use in this function) Suffix.xs:112: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_strings': Suffix.xs:128: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:128: error: `tree' undeclared (first use in this function) Suffix.xs:129: error: `LST_StringHash' undeclared (first use in this f +unction) Suffix.xs:129: error: `hash' undeclared (first use in this function) Suffix.xs:130: error: `LST_StringHashItem' undeclared (first use in th +is function) Suffix.xs:130: error: `hi' undeclared (first use in this function) Suffix.xs:133: error: syntax error before ')' token Suffix.xs:137: error: `LST_STRING_HASH_SIZE' undeclared (first use in +this function) Suffix.xs: In function `XS_Tree__Suffix_nodes': Suffix.xs:149: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:149: error: `tree' undeclared (first use in this function) Suffix.xs:151: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_clear': Suffix.xs:160: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:160: error: `tree' undeclared (first use in this function) Suffix.xs:162: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_dump': Suffix.xs:172: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:172: error: `tree' undeclared (first use in this function) Suffix.xs:175: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_remove': Suffix.xs:187: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:187: error: `tree' undeclared (first use in this function) Suffix.xs:188: error: `LST_StringHash' undeclared (first use in this f +unction) Suffix.xs:188: error: `hash' undeclared (first use in this function) Suffix.xs:189: error: `LST_StringHashItem' undeclared (first use in th +is function) Suffix.xs:189: error: `hi' undeclared (first use in this function) Suffix.xs:190: error: `LST_String' undeclared (first use in this funct +ion) Suffix.xs:190: error: `str' undeclared (first use in this function) Suffix.xs:195: error: syntax error before ')' token Suffix.xs:204: error: `LST_STRING_HASH_SIZE' undeclared (first use in +this function) Suffix.xs: In function `XS_Tree__Suffix__algorithm_longest_substrings' +: Suffix.xs:236: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:236: error: `tree' undeclared (first use in this function) Suffix.xs:237: error: `LST_StringSet' undeclared (first use in this fu +nction) Suffix.xs:237: error: `res' undeclared (first use in this function) Suffix.xs:238: error: `LST_String' undeclared (first use in this funct +ion) Suffix.xs:238: error: `str' undeclared (first use in this function) Suffix.xs:240: error: syntax error before ')' token Suffix.xs: In function `XS_Tree__Suffix_find': Suffix.xs:262: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:262: error: `tree' undeclared (first use in this function) Suffix.xs:263: error: `LST_String' undeclared (first use in this funct +ion) Suffix.xs:263: error: `str' undeclared (first use in this function) Suffix.xs:264: error: `LST_Edge' undeclared (first use in this functio +n) Suffix.xs:264: error: `edge' undeclared (first use in this function) Suffix.xs:265: error: `LST_Node' undeclared (first use in this functio +n) Suffix.xs:265: error: `node' undeclared (first use in this function) Suffix.xs:266: error: `shead' undeclared (first use in this function) Suffix.xs:266: error: `lst_node' undeclared (first use in this functio +n) Suffix.xs:266: error: syntax error before "stack" Suffix.xs:270: error: syntax error before ')' token Suffix.xs:281: error: `stack' undeclared (first use in this function) Suffix.xs:282: error: `iteration' undeclared (first use in this functi +on) Suffix.xs: In function `XS_Tree__Suffix_string': Suffix.xs:308: error: `LST_STree' undeclared (first use in this functi +on) Suffix.xs:308: error: `tree' undeclared (first use in this function) Suffix.xs:309: error: `LST_StringHash' undeclared (first use in this f +unction) Suffix.xs:309: error: `hash' undeclared (first use in this function) Suffix.xs:310: error: `LST_StringHashItem' undeclared (first use in th +is function) Suffix.xs:310: error: `hi' undeclared (first use in this function) Suffix.xs:311: error: `LST_StringIndex' undeclared (first use in this +function) Suffix.xs:311: error: syntax error before "range" Suffix.xs:314: error: syntax error before ')' token Suffix.xs:315: error: `LST_STRING_HASH_SIZE' undeclared (first use in +this function) Suffix.xs:320: error: `range' undeclared (first use in this function) make: *** [Suffix.o] Error 1 /usr/bin/make -j3 -- NOT OK Running make test Can't test without successful make Running make install make had returned bad status, install seems impossible
Running simple command:
$ perl Makefile.PL $ make $ make install
gave the same error as above

Regards,
Edward

Replies are listed 'Best First'.
Re^3: Installing Perl Wrapper Module for a C Library (Tree::Suffix) Locally
by Corion (Patriarch) on Mar 15, 2006 at 15:38 UTC

    The problematic line is this line:

    Note (probably harmless): No library found for -lstree

    I don't know why MakeMaker outputs this "propably harmless" message, because in my experience, it has never been harmless whenever I encountered it. This error message means that the Makefile.PL could not find the library stree, most likely because you didn't supply the correct -L and -I switches to it. This seems especially valid as your stree library is installed in an uncommon path I think.

    You will have to run your Makefile.PL manually and supply the correct paths to where the header/include files of the stree library got installed. Most likely like:

    perl -w Makefile.PL "INCLUDE=-I ../stree/include" "LIBS=-L ../stree/li +b"
Re^3: Installing Perl Wrapper Module for a C Library (Tree::Suffix) Locally
by fizbin (Chaplain) on Mar 15, 2006 at 15:54 UTC

    Okay, so it would appear that Makefile.PL and CPAN are not honoring your cflags environment setting. Furthermore, it appears that you need to pass extra C flag arguments to Makefile.PL as "CCFLAGS", not "CFLAGS". So, I would suggest trying this:

    perl Makefile.PL CCFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
    That should produce a Makefile that you can use with "make".
    --
    @/=map{[/./g]}qw/.h_nJ Xapou cets krht ele_ r_ra/; map{y/X_/\n /;print}map{pop@$_}@/for@/

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://536840]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (6)
As of 2024-04-23 13:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found