Thursday, 9 October 2008
|
| globs and trees in Perl6 Timothy S. Nelson 16:51:04 |
| | Hi all. I've enjoyed(?) reading over the February/March thread entitled "Musings on operator overloading". I've brought a few thoughts along; if they're old news, please tell me where to do more reading on it .
Over the last year or two, I've discovered XPath. I've always thought XML a little annoying, but I'm very impressed with XPath (which I regard as "the glob() of XML"), and I've been wondering how to get the power of XPath in relation to *all* data, not just XML.
My eventual thought was that what would be useful is a role called Plex (for those who aren't familiar with a Plex, just think "Tree" and you'll have the right idea). The basic idea is that the Plex role could have a variety of implementors depending on the data desired (much like the DBI/DBD split, but for trees instead of tables). The backends could of course include filesystems, but also XML, LDAP, OO databases, and DNS domains.
Tabular data could also be mapped into trees if desired. This could be anything from SQL to text files.
As an additional idea, backend conversion could be performed. This would be especially useful in the case of files. For example:
$root/etc/fstab <convert to text table> / "/boot"
...which would select the row from fstab that contains the "/boot" partition; admittedly I've fudged the conversion here.
As you can see from my example, my idea is also that then there could be Plex operators which would select out the data desired. In the example above, it would be necessary for / to be a combination of a flow operator and a variadic function that takes string and codeblock parameters; it returns a list of values which are all Plex::Node.
Btw, it was quite a long time before I was able to find the operator overloading documentation; "Subroutines" was not an intuitive place to look
. Is there any chance we could add something to S03 that says something like "see S06 and S13 for operator overloading"?
--------------------------------------------------------------------- | Name: Tim Nelson | Because the Creator is, | | E-mail: wayland@wayland.id.au | I am | ---------------------------------------------------------------------
----BEGIN GEEK CODE BLOCK---- Version 3.12 GCS d+++ s+: a- C++$ U+++$ P+++$ L+++ E- W+ N+ w--- V- PE(+) Y+>++ PGP->+++ R(+) !tv b++ DI++++ D G+ e++>++++ h! y- -----END GEEK CODE BLOCK-----
|
| | 11 answers | Add comment |
|
| getting error when add column to table Mmccaws2 04:20:19 |
| | Hi
I don't understand the error for this statement for SQLITE
$dbh->do("ALTER TABLE new_definition ( ADD COLUMN loopback TEXT)");
here is the error message:
DBD::SQLite::db do failed: near "(": syntax error(1) at dbdimp.c line 271 at ./a ddnewdef.pl line 38. DBD::SQLite::db do failed: near "(": syntax error(1) at dbdimp.c line 271 at ./a ddnewdef.pl line 38.
Or is it the case I'll have to delete the table and create the table with the new column added.
Also additional question about SQLITE. I've been developing using against a SQLITE db. I trimmed hundreds of entries out of table and the count command returns values shows that the number of entries has reduced. However the file doesn't reduce in size. Does SQLITE keep the last greatest file size eventhough the table has been trimmed? Or is there something else I need to do.
Thanks
Mike
|
| | 2 answer | Add comment |
Wednesday, 8 October 2008
|
| [svn:perl6-synopsis] r14590 - doc/trunk/design/syn Guest 22:26:15 |
| | Author: larry Date: Wed Oct 8 12:06:24 2008 New Revision: 14590
Modified: doc/trunk/design/syn/S13.pod
Log: wrong year, ruoso++
Modified: doc/trunk/design/syn/S13.pod ============================================================================== --- doc/trunk/design/syn/S13.pod (original) +++ doc/trunk/design/syn/S13.pod Wed Oct 8 12:06:24 2008 @@ -12,7 +12,7 @@ Maintainer: Larry Wall <larry@wall.org> Date: 2 Nov 2004 - Last Modified: 8 Oct 2007 + Last Modified: 8 Oct 2008 Number: 13 Version: 11
|
| | Add comment |
|
| Problem with column_info/DBD::Oracle 1.21 Alfred Mickautsch 15:07:21 |
| | Hello,
with ActivePerl 5.10.0 build 1004, DBI 1.607, DBD::Oracle 1.21 and Oracle 10.2.0.1.0 in a PAR-archived executable on a Win XP machine I get the following error message:
DBD::Oracle::db column_info failed: ORA-01008: not all variables bound (DBD ERROR: OCIStmtExecute) [for Statement "SELECT * ...
A trace file (level 15, some lines skipped) is attached.
I am stuck, because on our machines everything works just fine with Oracle clients 8.2, 9.2 and 10.2. Can somebody help me or point to some useful information?
Thankyou
Alfred
-- Alfred Mickautsch
SCHULER Business Solutions AG Karl-Berner-Str. 4 72285 Pfalzgrafenweiler Deutschland Tel: +49 7445 830-184 Fax: +49 7445 830-349 E-Mail: alfred.mickautsch@schuler-ag.com Web: www.schuler-ag.com
SCHULER Business Solutions AG Aktiengesellschaft mit Sitz in D-72285 Pfalzgrafenweiler, Karl-Berner-Str. 4 Registergericht Stuttgart HRB 430947 Vorstand: Uwe Jonas, Harald Sieber Vorsitzender des Aufsichtsrates: Achim Gauъ
|
| | 1 answer | Add comment |
Tuesday, 7 October 2008
|
| [svn:perl6-synopsis] r14586 - doc/trunk/design/syn Guest 20:04:54 |
| | Author: larry Date: Sun Oct 5 17:05:41 2008 New Revision: 14586
Modified: doc/trunk/design/syn/S03.pod
Log: Add missing series operator, mostly for readability.
Modified: doc/trunk/design/syn/S03.pod ============================================================================== --- doc/trunk/design/syn/S03.pod (original) +++ doc/trunk/design/syn/S03.pod Sun Oct 5 17:05:41 2008 @@ -12,9 +12,9 @@ Maintainer: Larry Wall <larry@wall.org> Date: 8 Mar 2004 - Last Modified: 1 Oct 2008 + Last Modified: 5 Oct 2008 Number: 3 - Version: 140 + Version: 141 =head1 Overview @@ -49,7 +49,7 @@ R Item assignment = := ::= => += -= **= xx= .= L Loose unary true not X Comma operator , p5=> - X List infix Z minmax X X~X X*X XeqvX + X List infix Z minmax X X~X X*X XeqvX ... R List prefix : print push say die map substr ... [+] [*] any $ @ X Loose and and andthen X Loose or or xor orelse @@ -1584,6 +1584,75 @@ See L</Cross operators>. +=item * + +C<< infix:<...> >>, the series operator. + +This operator takes a concrete list on its left and a function to be +iterated on its right when the list must be extended. + +The value of the operator is the lazy list formed of the +concrete list followed by the result of applying the function to the +tail of the list as needed. The function indicates by its arity +how many of the preceding values to pay attention to (and which the +operator must track internally). Demonstration of this falls to the +lot of the venerable Fibonacci sequence: + + 1, 1 ... { $^y + $^z } # 1,1,2,3,5,8... + 1, 1 ... &infix:<+> # 1,1,2,3,5,8... + +More typically the function is unary, in which case any extra values +in the list may be construed as human-readable documentation: + + 0,2,4 ... { $_ + 2 } # same as 1..*:by(2) + <a b c> ... { .succ } # same as 'a'..* + +The function need not be monotonic, of course: + + 1 ... { -$_ } # 1, -1, 1, -1, 1, -1... + False ... &prefix:<!> # False, True, False... + +The function can be 0-ary as well: + + () ... &rand # list of random numbers + +If the right operand is C<*> (Whatever) and the sequence is obviously +arithmetic or geometric, the appropriate function is deduced: + + 1, 3, 5 ... * # odd numbers + 1. 2. 4 ... * # powers of 2 + +Conjecture: other such patterns may be recognized in the future, +depending on which unrealistic benchmark we want to run faster. C<:)> + +Note: the yada operator is recognized only where a term is expected. +This operator may only be used where an infix is expected. If you +put a comma before the C<...> it will be taken as a yada list operator +expressing the desire to fail when the list reaches that point: + + 1..20, ... "I only know up to 20 so far mister" + +If the yada operator finds a closure for its argument at compile time, +it should probably whine about the fact that it's difficult to turn +a closure into an error message. Alternately, we could treat +an elipsis as special when it follows a comma to better support +traditional math notation. + +The function may choose to terminate its list by returning (). +Since this operator is list associative, an inner function may be +followed by a C<...> and another function to continue the list, +and so on. Hence, + + 1 ... { $_ + 1 if $_ < 10 } + ... { $_ + 10 if $_ < 100 } + ... { $_ + 100 if $_ < 1000 } + +produces + + 1,2,3,4,5,6,7,8,9, + 10,20,30,40,50,60,70,80,90, + 100,200,300,400,500,600,700,800,900 + =back Many of these operators return a list of Captures, which depending on
|
| | 9 answers | Add comment |
|
| [svn:perl6-synopsis] r14588 - doc/trunk/design/syn Guest 05:15:19 |
| | Author: larry Date: Mon Oct 6 18:15:17 2008 New Revision: 14588
Modified: doc/trunk/design/syn/S05.pod
Log: Added ~ twiddle macro to make it easier to write bracketing constructs.
Modified: doc/trunk/design/syn/S05.pod ============================================================================== --- doc/trunk/design/syn/S05.pod (original) +++ doc/trunk/design/syn/S05.pod Mon Oct 6 18:15:17 2008 @@ -14,9 +14,9 @@ Maintainer: Patrick Michaud <pmichaud@pobox.com> and Larry Wall <larry@wall.org> Date: 24 Jun 2002 - Last Modified: 7 Jul 2008 + Last Modified: 6 Oct 2008 Number: 5 - Version: 83 + Version: 84 This document summarizes Apocalypse 5, which is about the new regex syntax. We now try to call them I<regex> rather than "regular @@ -685,6 +685,59 @@ [ <ident> !~~ 'moose' ] || 'squirrel' +=item * + +The C<~> operator is a helper for matching nested subrules with a +specific terminator as the goal. It appears to be placed between the +opening and closing bracket, like so: + + '(' ~ ')' <expression> + +However, it mostly ignores the left argument, and operates on the next +two atoms (which may be quantified). Its operation on those next +two atoms is to "twiddle" them so that they are actually matched in +reverse order. Hence the expression above, at first blush, is merely +shortand for: + + '(' <expression> ')' + +But beyond that, when it rewrites the atoms it also inserts the +apparatus that will set up the inner expression to recognize the +terminator, and to produce an appropriate error message if the +inner expression does not terminate on the required closing atom. +So it really does pay attention to the left bracket as well, and it +actually rewrites our example to something more like: + + $<OPEN> = '(' <SETGOAL: ')'> <expression> [ $GOAL || <FAILGOAL> ] + +Note that you can use this construct to set up expectations for +a closing construct even when there's no opening bracket: + + <null> ~ ')' \d+ + +By default the error message uses the name of the current rule as an +indicator of the abstract goal of the parser at that point. However, +often this is not terribly informative, especially when rules are named +according to an internal scheme that will not make sense to the user. +The C<:dba> ("doing business as") adverb may be used to set up a more informative name for +what the following code is trying to parse: + + token postfix:sym<[ ]> { + :dba<array subscript> + '[' ~ ']' <expression> + } + +Then instead of getting a message like: + + Unable to parse expression in postfix:sym<[ ]>; couldn't find final ']' + +you'll get a message like: + + Unable to parse expression in array subscript; couldn't find final ']' + +(The C<:dba> adverb may also be used to give names to alternations +and alternatives, which helps the lexer give better error messages.) + =back =head1 Bracket rationalization
|
| | Add comment |
Monday, 6 October 2008
|
| [svn:perl6-synopsis] r14587 - doc/trunk/design/syn Guest 06:14:14 |
| | Author: larry Date: Sun Oct 5 19:14:11 2008 New Revision: 14587
Modified: doc/trunk/design/syn/S03.pod
Log: typos
Modified: doc/trunk/design/syn/S03.pod ============================================================================== --- doc/trunk/design/syn/S03.pod (original) +++ doc/trunk/design/syn/S03.pod Sun Oct 5 19:14:11 2008 @@ -1620,7 +1620,7 @@ arithmetic or geometric, the appropriate function is deduced: 1, 3, 5 ... * # odd numbers - 1. 2. 4 ... * # powers of 2 + 1, 2, 4 ... * # powers of 2 Conjecture: other such patterns may be recognized in the future, depending on which unrealistic benchmark we want to run faster. C<:)> @@ -1635,7 +1635,7 @@ If the yada operator finds a closure for its argument at compile time, it should probably whine about the fact that it's difficult to turn a closure into an error message. Alternately, we could treat -an elipsis as special when it follows a comma to better support +an ellipsis as special when it follows a comma to better support traditional math notation. The function may choose to terminate its list by returning ().
|
| | Add comment |
Sunday, 5 October 2008
|
| [svn:perl6-synopsis] r14585 - doc/trunk/design/syn Guest 18:11:21 |
| | Author: larry Date: Wed Oct 1 12:54:11 2008 New Revision: 14585
Modified: doc/trunk/design/syn/S03.pod
Log: Revision to accumulator semantics so that -= dwims
Modified: doc/trunk/design/syn/S03.pod ============================================================================== --- doc/trunk/design/syn/S03.pod (original) +++ doc/trunk/design/syn/S03.pod Wed Oct 1 12:54:11 2008 @@ -3251,8 +3251,20 @@ If you apply an assignment operator to a protoobject, it is assumed that you are implementing some kind of notional "reduction" to an accumulator -variable. To that end, the base operator is dropped and a simple -assignment is done instead. Hence you may correctly write: +variable. To that end, the operation is defined in terms +of the corresponding reduction operator, where the protoobject +becomes the operator's identify value. So if you say: + + $x -= 1; + +it is more or less equivalent to: + + $x = [-]() unless defined $x; # 0 for [-]() + $x = $x - 1; + +and $x ends up with -1 in it, as expected. + +Hence you may correctly write: my Num $prod; for @factors -> $f {
|
| | 2 answer | Add comment |
Saturday, 4 October 2008
|
| Carry Variable to Form Mike Flannigan 18:02:23 |
| | I have an html file that parses passed parameters with this code: ____________________________________
<script type="text/javascript">
var query = location.href.substring((location.href.indexOf('?')+1), location.href.length); if(location.href.indexOf('?') < 0) query = ''; querysplit = query.split('&'); query = new Array();
for(var i = 0; i < querysplit.length; i++){ var namevalue = querysplit[i].split('='); namevalue[1] = namevalue[1].replace(/\+/g, ' '); query[namevalue[0]] = unescape(namevalue[1]); }
window.onload = function(){ // Do stuff with query string data here.
document.getElementById('state').innerHTML = query['state']; }
var value = <span id='state'></span>;
</script>
<HTML> <HEAD> <TITLE>Title</TITLE> </HEAD> <BODY>
<p>The valve is <span id='state'></span> </p>
</body> </html> ____________________________________
All that works fine.
Then I try to copy the parsed value in the Subject field as follows:
____________________________________
<FORM ACTION="http://lotsofstuffhere&confirm=confirmed.html&error=error.html" METHOD="POST"> <INPUT NAME="recipient" TYPE="HIDDEN" VALUE="myemail"> <TABLE> <TR> <TD valign=middle>Your Name:</TD> <TD><INPUT NAME="name" SIZE="30"></TD> </TR> <TR> <TD valign=middle>Your E-mail:</TD> <TD><INPUT NAME="e-mail" SIZE="30"></TD> </TR> <TR> <TD valign=middle>Link:</TD> <TD><INPUT NAME="link" SIZE="60" VALUE="Some Link"></TD> </TR> <TR> <TD valign=middle>Subject:</TD> <TD><INPUT NAME="subject" SIZE="60" VALUE=<span id='state'></span>></TD> </TR> <TR> <TD valign=top><BR>Comments:</TD> <TD><TEXTAREA NAME="body" VALUE="" cols=60 rows=10></TEXTAREA></TD> </TR> <INPUT NAME="followup-page" TYPE="HIDDEN" VALUE="http://www.myprogram"> <TR> <TD></TD> <TD><INPUT TYPE="submit" name="submit" VALUE="Send"></TD> </TR> </TABLE> </FORM> ____________________________________
This does not work. It puts "<span" in the subject field.
Is it because of scoping? How can I get this to work? I tried literally 40 different things, but none worked. I also spent roughly 4 hours searching for a solution.
I can get this done with a Perl file, but unfortunately my Webserver will not run it properly.
Mike
|
| | 4 answer | Add comment |
|
| globs and rules and trees, oh my! (was: Re: XPath grammars (Was:
Re: globs and trees in Perl6)) Timothy S. Nelson 04:48:18 |
| | On Fri, 3 Oct 2008, Timothy S. Nelson wrote:
On Fri, 3 Oct 2008, Timothy S. Nelson wrote: On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all the work (like my idea of using a slash for a combined feed and call code operator). I could be wrong, but it seems to me that we could get something that's somewhat like XPath this way, without having to worry about defining an XPath grammar or anything. I'm talking to myself here  . The guys on IRC convinced me that the way to go might be something like a grammar, but that does trees and tree transformations instead of a text input stream. See the IRC log for details  . Talking to myself again. I'm not as convinced as I was. I'll write up a long post about that if necessary, but want to get something else figured out first. First, a paste from the IRC log: <TimToady> note to treematching folks: it is envisaged that signatures in a rule will match nodes in a tree My question is, how is this expected to work? Can someone give an example? I'm assuming that this relates to Jon Lang's comment about using rules to match non-strings.
I'm starting to see how *matching* would work now. But how would it be if I wanted to search a tree for all nodes whose "readonly" attribute were true, and return an array of those nodes? Hmm. Or something like the following XPath...
/html/body//p/a[@name = "#SampleName"]
(my XPath isn't that great, but I'm assuming this will find all a tags in the html body that are the direct descendant of a paragraph, and have their @name attribute set to "#SampleName"). My guess is something like this:
$htmlobject = HTML->new();
$htmlobject.children() ==> grep { /html/ } ==> map { .children() } ==> grep { /body/ } ==> map { .children() } ==> recursivegrep { /p/ } ==> map { .children() } ==> grep { /a/ and .name eq "#Samplename" } ==> $anchors
I'm guessing that might do it (although the tree role and recursivegrep would also require some work). But the syntax is dreadful . You can see why I was talking about having a feed operator that did a grep and got children as well as doing the feed. But no doubt I'm missing something here. And I'm still thinking like a Perl5 programmer .
--------------------------------------------------------------------- | Name: Tim Nelson | Because the Creator is, | | E-mail: wayland@wayland.id.au | I am | ---------------------------------------------------------------------
----BEGIN GEEK CODE BLOCK---- Version 3.12 GCS d+++ s+: a- C++$ U+++$ P+++$ L+++ E- W+ N+ w--- V- PE(+) Y+>++ PGP->+++ R(+) !tv b++ DI++++ D G+ e++>++++ h! y- -----END GEEK CODE BLOCK-----
|
| | 1 answer | Add comment |
Friday, 3 October 2008
|
| Re: XPath grammars (Was: Re: globs and trees in Perl6) Timothy S. Nelson 04:15:52 |
| | On Thu, 2 Oct 2008, Daniel Ruoso wrote:
One thing we realized at that time is that XPath is good enough, even if it seems to be adressing XML specifically, it has the concept of "dimension" that can be extended to represent arbitrary aspects of objects. Hmm. Back in March, before I discovered that perl6 was actually far enough along to start using a bit, I wrote an article which includes information about what I do and don't like about XPath:
http://computerstuff.jdarx.info/content/treepath-universal-tree-navigation-language
It basically recommends that there be two path dialects, Complex TreePath (which is basically XPath) and Simple TreePath (which is basically a somewhat modified version of glob).
Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all the work (like my idea of using a slash for a combined feed and call code operator). I could be wrong, but it seems to me that we could get something that's somewhat like XPath this way, without having to worry about defining an XPath grammar or anything.
--------------------------------------------------------------------- | Name: Tim Nelson | Because the Creator is, | | E-mail: wayland@wayland.id.au | I am | ---------------------------------------------------------------------
----BEGIN GEEK CODE BLOCK---- Version 3.12 GCS d+++ s+: a- C++$ U+++$ P+++$ L+++ E- W+ N+ w--- V- PE(+) Y+>++ PGP->+++ R(+) !tv b++ DI++++ D G+ e++>++++ h! y- -----END GEEK CODE BLOCK-----
|
| | 5 answers | Add comment |
Thursday, 2 October 2008
|
| HP's Testdrive being replaced. Michael G Schwern 10:24:45 |
| | I just found this out, and I assume others here occasionally make use of testdrive and don't know.
HP is shutting down it's testdrive program which gives logins to its many operating systems (see also VMS) for developer evaluation and testing. It's replacing it with something called HP Partner Virtualization Program which it says is better and will make you smell nice and be more attractive.
For more info... http://www.hp.com/go/pvp http://www.hp.com/go/dspp
They did make one note that OpenVMS is not yet part of HP PVP, so that part of testdrive will remain open until it is. *whew*
-- Insulting our readers is part of our business model. http://somethingpositive.net/sp07122005.shtml
|
| | 3 answer | Add comment |
|
| DBD::Oracle on Linux 64bit Сотников Роман Валерьевич 06:37:52 |
| | Hi,
I try to install DBD::Oracle 1.22 on RHEL4-U4-x86_64-AS Red Hat. Version of Oracle cleint is: 9.2.0.7
Perl version is: [root@nsk-fm02 DBD-Oracle-1.22]# perl -V Summary of my perl5 (revision 5 version 8 subversion 5) configuration: Platform: osname=linux, osvers=2.6.9-22.18.bz155725.elsmp, archname=x86_64-linux-thread-multi uname='linux hs20-bc1-3.build.redhat.com 2.6.9-22.18.bz155725.elsmp #1 smp thu nov 17 15:34:08 est 2005 x86_64 x86_64 x86_64 gnulinux ' config_args='-des -Doptimize=-O2 -g -pipe -m64 -Dversion=5.8.5 -Dmyhostname=localhost -Dperladmin=root@localhost -Dcc=gcc -Dcf_by=Red Hat, Inc. -Dinstallprefix=/usr -Dprefix=/usr -Dlibpth=/usr/local/lib64 /lib64 /usr/lib64 -Dprivlib=/usr/lib/perl5/5.8.5 -Dsitelib=/usr/lib/perl5/site_perl/5.8.5 -Dvendorlib=/usr/lib/perl5/vendor_perl/5.8.5 -Darchlib=/usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi -Dsitearch=/usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi -Dvendorarch=/usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi -Darchname=x86_64-linux -Dvendorprefix=/usr -Dsiteprefix=/usr -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Dd_dosuid -Dd_semctl_semun -Di_db -Ui_ndbm -Di_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=/usr/bin/less -isr -Dinc_version_list=5.8.4 5.8.3 5.8.2 5.8.1 5.8.0' hint=recommended, useposix=true, d_sigaction=define usethreads=define use5005threads=undef useithreads=define usemultiplicity=define useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='gcc', ccflags ='-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', optimize='-O2 -g -pipe -m64', cppflags='-D_REENTRANT -D_GNU_SOURCE -DDEBUGGING -fno-strict-aliasing -pipe -I/usr/local/include -I/usr/include/gdbm' ccversion='', gccversion='3.4.6 20060404 (Red Hat 3.4.6-2)', gccosandvers='' intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16 ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='gcc', ldflags ='' libpth=/usr/local/lib64 /lib64 /usr/lib64 libs=-lresolv -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc perllibs=-lresolv -lnsl -ldl -lm -lcrypt -lutil -lpthread -lc libc=/lib/libc-2.3.3.so, so=so, useshrplib=true, libperl=libperl.so gnulibc_version='2.3.4' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E -Wl,-rpath,/usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/CORE' cccdlflags='-fPIC', lddlflags='-shared'
Characteristics of this binary (from libperl): Compile-time options: DEBUGGING MULTIPLICITY USE_ITHREADS USE_64_BIT_INT USE_64_BIT_ALL USE_LARGE_FILES PERL_IMPLICIT_CONTEXT Built under linux Compiled at Jul 24 2006 18:28:14 @INC: /usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi /usr/lib/perl5/5.8.5 /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.4/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.3/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.2/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.1/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.0/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.3 /usr/lib/perl5/site_perl/5.8.2 /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.4/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.3/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.2/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.1/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.0/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl/5.8.4 /usr/lib/perl5/vendor_perl/5.8.3 /usr/lib/perl5/vendor_perl/5.8.2 /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl . Press any key to continue...
First, I try to run perl Makefile.PL and got an error like this:
[root@nsk-fm02 DBD-Oracle-1.22]# perl Makefile.PL Multiple copies of Driver.xst found in: /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ at Makefile.PL line 37 Using DBI 1.607 (for perl 5.008005 on x86_64-linux-thread-multi) installed in /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/
Configuring DBD::Oracle for perl 5.008005 on linux (x86_64-linux-thread-multi)
Remember to actually *READ* the README file! Especially if you have any problems.
Installing on a linux, Ver#2.6 Using Oracle in /u01/app/oracle/product/9.2.0 DEFINE _SQLPLUS_RELEASE = "902000700" (CHAR) Oracle version 9.2.0.7 (9.2) Found /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Found /u01/app/oracle/product/9.2.0/rdbms/lib/ins_rdbms.mk Found /u01/app/oracle/product/9.2.0/precomp/demo/proc/demo_proc.mk Using /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Your LD_LIBRARY_PATH env var is set to '/u01/app/oracle/product/9.2.0/lib' Reading /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Reading /u01/app/oracle/product/9.2.0/rdbms/lib/env_rdbms.mk
Attempting to discover Oracle OCI build rules gcc -c -o DBD_ORA_OBJ.o DBD_ORA_OBJ.c by executing: [make -f /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk build ECHODO=echo ECHO=echo GENCLNTSH='echo genclntsh' CC=true OPTIMIZE= CCFLAGS= EXE=DBD_ORA_EXE OBJS=DBD_ORA_OBJ.o] Oracle oci build command: [true -L/u01/app/oracle/product/9.2.0/lib/ -L/u01/app/oracle/product/9.2.0/rdbms/lib/ -o DBD_ORA_EXE DBD_ORA_OBJ.o -lclntsh `cat /u01/app/oracle/product/9.2.0/lib/sysliblist` -ldl -lm ]
Found header files in /u01/app/oracle/product/9.2.0/rdbms/demo /u01/app/oracle/product/9.2.0/rdbms/public.
Checking for functioning wait.ph
System: perl5.008005 linux hs20-bc1-3.build.redhat.com 2.6.9-22.18.bz155725.elsmp #1 smp thu nov 17 15:34:08 est 2005 x86_64 x86_64 x86_64 gnulinux Compiler: gcc -O2 -g -pipe -m64 -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 Linker: /usr/bin/ld Sysliblist: -ldl -lm -lpthread -lnsl Oracle makefiles would have used these definitions but we override them: CC: gcc CFLAGS: $(GFLAG) $(OPTIMIZE) $(CDEBUG) $(CCFLAGS) $(PFLAGS)\ $(SHARED_CFLAG) $(USRFLAGS) [$(GFLAG) -O3 $(CDEBUG) -m32 -trigraphs -fPIC -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/plsql/public -I/u01/app/oracle/product/9.2.0/network/public -DLINUX -DORAX86_64 -D_GNU_SOURCE -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DSLTS_ENABLE -DSLMXMX_ENABLE -D_REENTRANT -DNS_THREADS -DLONG_IS_64 -fno-strict-aliasing -DSS_64BIT_SERVER $(LPFLAGS) $(USRFLAGS)] LDFLAGS: $(LDFLAGS32) [-m32 -o $@ -L/u01/app/oracle/product/9.2.0/rdbms//lib32/ -L/u01/app/oracle/product/9.2.0/lib32/ -L/u01/app/oracle/product/9.2.0/lib32/stubs/] Linking with OTHERLDFLAGS = -L/u01/app/oracle/product/9.2.0/lib/ -L/u01/app/oracle/product/9.2.0/rdbms/lib/ -lclntsh `cat /u01/app/oracle/product/9.2.0/lib/sysliblist` -ldl -lm [from 'build' rule]
Checking if your kit is complete...
Warning: the following files are missing in your kit: META.yml Please inform the author.
LD_RUN_PATH=/u01/app/oracle/product/9.2.0/lib:/u01/app/oracle/product/9.2.0/rdbms/lib Using DBD::Oracle 1.22. Using DBD::Oracle 1.22. Multiple copies of Driver.xst found in: /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ at Makefile.PL line 1693 Using DBI 1.607 (for perl 5.008005 on x86_64-linux-thread-multi) installed in /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ Writing Makefile for DBD::Oracle
*** If you have problems... read all the log printed above, and the README and README.help.txt files. (Of course, you have read README by now anyway, haven't you?)
Press any key to continue...
I've read the bug trace on CPAN, and got an analogical bud ID 38882. But, package 1.22 didn't have file META.yml, so I've cut line "META.yml Module meta-data (added by MakeMaker)" in the MANIFEST and got an more or less successfully makefile.
The log of Makefile.PL is: [root@nsk-fm02 DBD-Oracle-1.22]# perl Makefile.PL Multiple copies of Driver.xst found in: /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ at Makefile.PL line 37 Using DBI 1.607 (for perl 5.008005 on x86_64-linux-thread-multi) installed in /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/
Configuring DBD::Oracle for perl 5.008005 on linux (x86_64-linux-thread-multi)
Remember to actually *READ* the README file! Especially if you have any problems.
Installing on a linux, Ver#2.6 Using Oracle in /u01/app/oracle/product/9.2.0 DEFINE _SQLPLUS_RELEASE = "902000700" (CHAR) Oracle version 9.2.0.7 (9.2) Found /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Found /u01/app/oracle/product/9.2.0/rdbms/lib/ins_rdbms.mk Found /u01/app/oracle/product/9.2.0/precomp/demo/proc/demo_proc.mk Using /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Your LD_LIBRARY_PATH env var is set to '/u01/app/oracle/product/9.2.0/lib' Reading /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk Reading /u01/app/oracle/product/9.2.0/rdbms/lib/env_rdbms.mk
Attempting to discover Oracle OCI build rules gcc -c -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/plsql/public -I/u01/app/oracle/product/9.2.0/network/public -I/usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI -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 -m64 -DVERSION=\"1.22\" -DXS_VERSION=\"1.22\" -fPIC "-I/usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/CORE" -Wall -Wno-comment -DUTF8_SUPPORT -DNEW_OCI_INIT -DORA_OCI_VERSION=\"9.2.0.7\" DBD_ORA_OBJ.c by executing: [make -f /u01/app/oracle/product/9.2.0/rdbms/demo/demo_rdbms.mk build ECHODO=echo ECHO=echo GENCLNTSH='echo genclntsh' CC=true OPTIMIZE= CCFLAGS= EXE=DBD_ORA_EXE OBJS=DBD_ORA_OBJ.o] Oracle oci build command: [true -L/u01/app/oracle/product/9.2.0/lib/ -L/u01/app/oracle/product/9.2.0/rdbms/lib/ -o DBD_ORA_EXE DBD_ORA_OBJ.o -lclntsh `cat /u01/app/oracle/product/9.2.0/lib/sysliblist` -ldl -lm ]
Found header files in /u01/app/oracle/product/9.2.0/rdbms/demo /u01/app/oracle/product/9.2.0/rdbms/public.
Checking for functioning wait.ph
System: perl5.008005 linux hs20-bc1-3.build.redhat.com 2.6.9-22.18.bz155725.elsmp #1 smp thu nov 17 15:34:08 est 2005 x86_64 x86_64 x86_64 gnulinux Compiler: gcc -O2 -g -pipe -m64 -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 Linker: /usr/bin/ld Sysliblist: -ldl -lm -lpthread -lnsl Oracle makefiles would have used these definitions but we override them: CC: gcc CFLAGS: $(GFLAG) $(OPTIMIZE) $(CDEBUG) $(CCFLAGS) $(PFLAGS)\ $(SHARED_CFLAG) $(USRFLAGS) [$(GFLAG) -O3 $(CDEBUG) -m32 -trigraphs -fPIC -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/plsql/public -I/u01/app/oracle/product/9.2.0/network/public -DLINUX -DORAX86_64 -D_GNU_SOURCE -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DSLTS_ENABLE -DSLMXMX_ENABLE -D_REENTRANT -DNS_THREADS -DLONG_IS_64 -fno-strict-aliasing -DSS_64BIT_SERVER $(LPFLAGS) $(USRFLAGS)] LDFLAGS: $(LDFLAGS32) [-m32 -o $@ -L/u01/app/oracle/product/9.2.0/rdbms//lib32/ -L/u01/app/oracle/product/9.2.0/lib32/ -L/u01/app/oracle/product/9.2.0/lib32/stubs/] Linking with OTHERLDFLAGS = -L/u01/app/oracle/product/9.2.0/lib/ -L/u01/app/oracle/product/9.2.0/rdbms/lib/ -lclntsh `cat /u01/app/oracle/product/9.2.0/lib/sysliblist` -ldl -lm [from 'build' rule]
LD_RUN_PATH=/u01/app/oracle/product/9.2.0/lib:/u01/app/oracle/product/9.2.0/rdbms/lib Using DBD::Oracle 1.22. Using DBD::Oracle 1.22. Multiple copies of Driver.xst found in: /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ at Makefile.PL line 1693 Using DBI 1.607 (for perl 5.008005 on x86_64-linux-thread-multi) installed in /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/ Writing Makefile for DBD::Oracle
*** If you have problems... read all the log printed above, and the README and README.help.txt files. (Of course, you have read README by now anyway, haven't you?)
Press any key to continue...
After that, I've tried to make... [root@nsk-fm02 DBD-Oracle-1.22]# make cp Oracle.pm blib/lib/DBD/Oracle.pm cp oraperl.ph blib/lib/oraperl.ph cp dbdimp.h blib/arch/auto/DBD/Oracle/dbdimp.h cp ocitrace.h blib/arch/auto/DBD/Oracle/ocitrace.h cp Oraperl.pm blib/lib/Oraperl.pm cp Oracle.h blib/arch/auto/DBD/Oracle/Oracle.h cp lib/DBD/Oracle/GetInfo.pm blib/lib/DBD/Oracle/GetInfo.pm cp mk.pm blib/arch/auto/DBD/Oracle/mk.pm /usr/bin/perl -p -e "s/~DRIVER~/Oracle/g" /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/DBI/Driver.xst > Oracle.xsi /usr/bin/perl /usr/lib/perl5/5.8.5/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.8.5/ExtUtils/typemap -typemap typemap Oracle.xs > Oracle.xsc && mv Oracle.xsc Oracle.c gcc -c -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/rdbms/demo -I/u01/app/oracle/product/9.2.0/rdbms/public -I/u01/app/oracle/product/9.2.0/plsql/p | |