From davidnicol at gmail.com Sat Jan 6 22:31:33 2007 From: davidnicol at gmail.com (David Nicol) Date: Sun, 7 Jan 2007 00:31:33 -0600 Subject: [Kc] a tool to normalize CPP directive indentation Message-ID: <934f64a20701062231j1db159a5p8667036221419f74@mail.gmail.com> So I'm reading through some header files and wanting all the #ifdefs and whatnot to line up sanely so I wrote the attached. I have not tested it extensively but it is appears to correctly ignore parts that are commented out, and it also is supposed to ignore comment-open marks, that is, /*, when it is part of a double-quoted string. It will also complain when it has a line with an odd number of uncommented "s. -- pre-?, ?, ?, rc, release. -------------- next part -------------- A non-text attachment was scrubbed... Name: CPP_conditional_indenter.pl Type: application/x-perl Size: 1435 bytes Desc: not available Url : http://mail.pm.org/pipermail/kc/attachments/20070107/11489fc9/attachment.bin From darylvf at gmail.com Thu Jan 11 12:45:14 2007 From: darylvf at gmail.com (Daryl Fallin) Date: Thu, 11 Jan 2007 14:45:14 -0600 Subject: [Kc] Math::GMP install problem Message-ID: I am trying to install Net::SSH::Perl and it needs Math::GMP, which has been giving me fits. I have no idea what the problem is and hoping that someone else has come across this problem before. Thank You I have cut out a lot of the messages that seemed redundant, but if its needed I will be happy to provide the full output. =============================== cpan[1]> install Math::GMP CPAN: Storable loaded ok Going to read /root/.cpan/Metadata Database was generated on Thu, 11 Jan 2007 01:27:30 GMT Running install for module Math::GMP Running make for C/CH/CHIPT/Math-GMP-2.04.tar.gz CPAN: Digest::SHA loaded ok CPAN: Compress::Zlib loaded ok Checksum for /root/.cpan/sources/authors/id/C/CH/CHIPT/Math-GMP-2.04.tar.gz ok Scanning cache /root/.cpan/build for sizes Math-GMP-2.04/ Math-GMP-2.04/Changes Math-GMP-2.04/COPYING.LIB Math-GMP-2.04/MANIFEST Math-GMP-2.04/typemap Math-GMP-2.04/GMP.xs Math-GMP-2.04/t/ Math-GMP-2.04/t/gmppm.t Math-GMP-2.04/lib/ Math-GMP-2.04/lib/Math/ Math-GMP-2.04/lib/Math/GMP.pm Math-GMP-2.04/INSTALL Math-GMP-2.04/Makefile.PL Math-GMP-2.04/README Math-GMP-2.04/LICENSE Removing previously used /root/.cpan/build/Math-GMP-2.04 CPAN.pm: Going to build C/CH/CHIPT/Math-GMP-2.04.tar.gz Checking if your kit is complete... Looks good Writing Makefile for Math::GMP cp lib/Math/GMP.pm blib/lib/Math/GMP.pm AutoSplitting blib/lib/Math/GMP.pm (blib/lib/auto/Math/GMP) /usr/bin/perl /usr/lib/perl5/5.8.8/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.8.8/ExtUtils/typemap -typemap typemap GMP.xs > GMP.xsc && mv GMP.xsc GMP.c cc -c -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -fno-strict-aliasing -pipe -Wdeclaration-after-statement -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -march=i586 -mtune=i686 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -g -Wall -pipe -DVERSION=\"2.04\" -DXS_VERSION=\"2.04\" -fPIC "-I/usr/lib/perl5/5.8.8/i586-linux-thread-multi/CORE" GMP.c GMP.xs:4:17: error: gmp.h: No such file or directory GMP.xs: In function ???constant???: GMP.xs:49: warning: label ???not_there??? defined but not used GMP.c: In function ???XS_Math__GMP_new_from_scalar???: GMP.c:93: error: ???mpz_t??? undeclared (first use in this function) GMP.c:93: error: (Each undeclared identifier is reported only once GMP.c:93: error: for each function it appears in.) GMP.c:93: error: ???RETVAL??? undeclared (first use in this function) GMP.xs:70: warning: implicit declaration of function ???mpz_init_set_str??? GMP.c: In function ???XS_Math__GMP_new_from_scalar_with_base???: GMP.c:114: error: ???mpz_t??? undeclared (first use in this function) GMP.c:114: error: ???RETVAL??? undeclared (first use in this function) GMP.c: In function ???XS_Math__GMP_destroy???: GMP.c:133: error: ???mpz_t??? undeclared (first use in this function) GMP.c:133: error: ???n??? undeclared (first use in this function) GMP.c:137: error: expected expression before ???)??? token GMP.c:136: warning: unused variable ???tmp??? GMP.xs:90: warning: implicit declaration of function ???mpz_clear??? GMP.c: In function ???XS_Math__GMP_stringify_gmp???: GMP.c:157: error: ???mpz_t??? undeclared (first use in this function) GMP.c:157: error: ???n??? undeclared (first use in this function) GMP.xs:98: warning: ISO C90 forbids mixed declarations and code GMP.c:166: error: expected expression before ???)??? token GMP.c:165: warning: unused variable ???tmp??? GMP.xs:101: warning: implicit declaration of function ???mpz_sizeinbase??? GMP.xs:105: warning: implicit declaration of function ???mpz_get_str??? GMP.c: In function ???XS_Math__GMP_get_str_gmp???: ... ... ... GMP.c: In function ???XS_Math__GMP_gmp_sqrt???: GMP.c:1098: error: ???mpz_t??? undeclared (first use in this function) GMP.c:1098: error: ???m??? undeclared (first use in this function) GMP.c:1099: error: ???RETVAL??? undeclared (first use in this function) GMP.c:1103: error: expected expression before ???)??? token GMP.c:1102: warning: unused variable ???tmp??? GMP.xs:466: warning: implicit declaration of function ???mpz_sqrt??? make: *** [GMP.o] Error 1 /usr/bin/make -- NOT OK Running make test Can't test without successful make Running make install make had returned bad status, install seems impossible Failed during this command: CHIPT/Math-GMP-2.04.tar.gz : make NO cpan[2]> =============================== From amoore at mooresystems.com Thu Jan 11 14:43:35 2007 From: amoore at mooresystems.com (Andrew Moore) Date: Thu, 11 Jan 2007 16:43:35 -0600 Subject: [Kc] Math::GMP install problem In-Reply-To: References: Message-ID: <20070111224335.GC13711@mooresystems.com> On Thu, Jan 11, 2007 at 02:45:14PM -0600, Daryl Fallin wrote: > I am trying to install Net::SSH::Perl and it needs Math::GMP, which > has been giving me fits. I have no idea what the problem is and > hoping that someone else has come across this problem before. Hi Daryl - I suspect that you don't have the GMP library installed. Math::GMP is just a perl interface to it. From the INSTALL document with Math::GMP: -- To install this package, you will need a version of the GMP library. You can get it at the homepage of GMP: http://www.swox.com/gmp/ -- Or, I bet that your distribution has a way to install it, like apt-get or rpm or yast or whatever is appropriate for your distribution. Let us know if that doesn't seem to be the problem. Good luck! -Andy From darylvf at gmail.com Wed Jan 17 11:45:42 2007 From: darylvf at gmail.com (Daryl Fallin) Date: Wed, 17 Jan 2007 13:45:42 -0600 Subject: [Kc] Math::GMP install problem In-Reply-To: <20070111224335.GC13711@mooresystems.com> References: <20070111224335.GC13711@mooresystems.com> Message-ID: Andy - This worked. I just fired up Yast and installed the GMP development libraries and everything worked great! Thank You - daryl On 1/11/07, Andrew Moore wrote: > On Thu, Jan 11, 2007 at 02:45:14PM -0600, Daryl Fallin wrote: > > I am trying to install Net::SSH::Perl and it needs Math::GMP, which > > has been giving me fits. I have no idea what the problem is and > > hoping that someone else has come across this problem before. > > Hi Daryl - > > I suspect that you don't have the GMP library installed. Math::GMP is > just a perl interface to it. From the INSTALL document with Math::GMP: > > -- > > To install this package, you will need a version of the GMP library. You can > get it at the homepage of GMP: > > http://www.swox.com/gmp/ > > -- > > Or, I bet that your distribution has a way to install it, like apt-get > or rpm or yast or whatever is appropriate for your distribution. > > Let us know if that doesn't seem to be the problem. > > Good luck! > -Andy > _______________________________________________ > kc mailing list > kc at pm.org > http://mail.pm.org/mailman/listinfo/kc > From darylvf at gmail.com Fri Jan 19 09:20:44 2007 From: darylvf at gmail.com (Daryl Fallin) Date: Fri, 19 Jan 2007 11:20:44 -0600 Subject: [Kc] Has anyone used the Net:SSH2 perl Module Message-ID: When I run the example code it completes the SCP and the SFTP calls with no problem whatsoever, but when trying to use a channel it fails. It appears that everything works ok, authentication, etc, but I get zero output using a channel. I turned on debug and and this is the output I get: daryl at seclab10:~/CPAN/Net-SSH2-0.09/example> ./read.pl [user daryl] Password: [user daryl] libssh2_channel_open_ex(ss->session, pv_channel_type, len_channel_type, window_size, packet_size, ((void *)0) , 0 ) -> 0x8362f88 Net::SSH2::poll: timeout = 250, array[1] - [0] = channel - [0] events 1 - libssh2_poll returned 0 - [0] revents 0 Net::SSH2::Channel::DESTROY Net::SSH2::DESTROY object 0x8180488 daryl at seclab10:~/CPAN/Net-SSH2-0.09/example> Here is the code as I ran it for the above output: #!/usr/bin/perl -w # Sample Net::SSH2 code illustrating several ways to read the remote # /etc/passwd file. use Net::SSH2; use IO::Scalar; my $ssh2 = Net::SSH2->new; $ssh2->debug(1); die "can't connect" unless $ssh2->connect('localhost'); # use an interactive authentication method with default callback # (if a password is provided here, it will forward it without prompting) die "can't authenticate" unless $ssh2->auth(username => scalar getpwuid($<), interact => 1); sub _read { my $handle = shift; while (my $line = <$handle>) { chomp $line; $line =~ s/:.*$//; print "found user '$line'\n"; } } # (c) type it over a channel $chan = $ssh2->channel; $chan->exec('cat /etc/passwd') or die; _read($chan); Thank You - Daryl -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/kc/attachments/20070119/07fa6d31/attachment.html From amoore at mooresystems.com Tue Jan 23 13:31:00 2007 From: amoore at mooresystems.com (Andrew Moore) Date: Tue, 23 Jan 2007 15:31:00 -0600 Subject: [Kc] Kansas City Perl opportunity.... In-Reply-To: References: Message-ID: <20070123213100.GB14101@mooresystems.com> Hi KC Mongers - Here's a job opening that landed in my email box a moment ago. Please contact Cindy Whitten directly if you're interested. Also - I'll be out of town on the second Tuesday of Feb (the 13th), so I'll miss the meeting (as usual). If anyone has topic suggestions, please don't hesitate to speak up! -Andy On Tue, Jan 23, 2007 at 02:39:12PM -0600, cwhitten at Comtek-Group.com wrote: > > Hi Andrew, > I was reviewing the Kansas City perm Managers site and thought I'd contact > you. We have a Perl Developer opportunity in the Kansas City area. I > didnt know if you know anyone who may be looking or not but thought I'd > ask. Please pass on my contact information if you may know a Perl > Developer , thanks! > > Requires experience with C/C++, PERL, HTML/DHTML, XML, SQL and an > understanding of linking back-end applications. Java is a big plus. > Analyzes, designs, implements and supports web-related applications support > of company???s internet/intranet strategy. Maintains e-commerce or > business-related applications. > Skills: Knowledge of authoring tools and human interface. Must be > experienced with performance aspects of application development. Knowledge > of DBMSs, development methodology, standards, design tools, Java Script, VB > Script, PERL, XML, HTML, SQL, Oracle and Java. Knowledge of web design > principles and standards, firewall and network security and Internet > database connectivity. > Should have a mature attittude and be a self-starter, willing to share > knowledge with the team. > C or C++, PERL, HTML/DHTML, XML, SQL > > > Cindy > > Cindy Whitten > Senior Technical Recruiter > COMTEK-Group > Phone: 972-792-1031 > Toll: 1-866-247-9083 > Fax: 972-644-6602 > cwhitten at comtek-group.com > http://www.comtek-group.com