zsh-workers
 help / color / mirror / code / Atom feed
From: lists <lists@kalama.no-ip.org>
To: zsh-workers@sunsite.dk
Subject: Re: pcre module help
Date: Sun, 20 Jun 2004 22:38:14 -0500	[thread overview]
Message-ID: <6D2D3896-C334-11D8-8B47-000A95D2C79E@kalama.no-ip.org> (raw)
In-Reply-To: <20040620224419.GA16988@scowler.net>

Hi all,
	First, thanks for the documentation patch.  Secondly, I am unable to 
use the pcre module on Mac OS 10.3.4.  Regarding the bus error:

% zsh -f
% print $ZSH_VERSION
4.2.0
% zmodload zsh/pcre
% text=d
% [[ "$text" -pcre-match ^d+$ ]] && print text variable contains only 
"d's".
zsh: bus error  zsh -f

(at that point the shell exits)

I haven't used gdb before, so please correct me if this is wrong:
1. In one shell, I do the following:
% zsh -f
% zmodload zsh/pcre

2. In another shell, I did:
% ps ax|grep "[z]sh -f"
18610  p4  S+     0:00.03 zsh -f
% gdb /usr/local/bin/zsh 18610
GNU gdb 5.3-20030128 (Apple version gdb-309) (Thu Dec  4 15:41:30 GMT 
2003)
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and 
you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for 
details.
This GDB was configured as "powerpc-apple-darwin".
Reading symbols for shared libraries ... done
/Users/me/18610: No such file or directory.
Attaching to program: `/usr/local/bin/zsh', process 18610.
Reading symbols for shared libraries ..... done
0x9000eac4 in read ()
(gdb) bt
#0  0x9000eac4 in read ()
#1  0x000b65ec in ungetkeys ()
#2  0x000b677c in getkey ()
#3  0x000b5d5c in getkeymapcmd ()
#4  0x000b5c80 in getkeymapcmd ()
#5  0x000b5e80 in getkeycmd ()
#6  0x000b6ac8 in zlecore ()
#7  0x000b70c4 in zleread ()
#8  0x000287e0 in ingetc ()
#9  0x00028638 in ingetc ()
#10 0x000200f0 in iaddtoline ()
#11 0x0002ebe8 in gettok ()
#12 0x0002e1c0 in yylex ()
#13 0x00044d88 in parse_event ()
#14 0x00025594 in loop ()
#15 0x000282f0 in zsh_main ()
#16 0x00001c98 in start ()
#17 0x8fe1a558 in __dyld__dyld_start ()
(gdb) quit
The program is running.  Quit anyway (and detach it)? (y or n) y
Detaching from program: `/usr/local/bin/zsh', process 18610 thread 
0x307.


Please let me know if other/more information would help.  Regarding the 
"pcre_compile: not available on this system" message:

% zsh -f
% zmodload zsh/pcre
% pcre_compile ^d+$
pcre_compile: not available on this system

I just attempted to compile zsh 4.2.0 with the --enable-pcre option 
again and noticed the following:

checking for pcre_compile... no
checking for pcre_study... no
checking for pcre_exec... no
...
checking pcre.h usability... no
checking pcre.h presence... no
checking for pcre.h... no
...
checking for library containing pcre_compile... no

What could it be?  I'm happy to get you more information/test patches, 
etc.

Thanks,
Ryan


On Jun 20, 2004, at 5:44 PM, Clint Adams wrote:

>> The shell crashing is consistent when I try to use -pcre-match after
>> attempting to run pcre_compile.  Also, the -pcre-match method is not
>> mentioned in the zshmodules manual.
>
>
> Index: Doc/Zsh/mod_pcre.yo
> ===================================================================
> RCS file: /cvsroot/zsh/zsh/Doc/Zsh/mod_pcre.yo,v
> retrieving revision 1.4
> diff -u -r1.4 mod_pcre.yo
> --- Doc/Zsh/mod_pcre.yo	16 Mar 2004 15:14:39 -0000	1.4
> +++ Doc/Zsh/mod_pcre.yo	20 Jun 2004 22:42:20 -0000
> @@ -32,3 +32,15 @@
>  case it will set the array var(arr).
>  )
>  enditem()
> +
> +The tt(zsh/pcre) module makes available the following test condition:
> +startitem()
> +findex(pcre-match)
> +item(expr tt(-pcre-match) pcre)(
> +Matches a string against a perl-compatible regular expression.
> +
> +For example,
> +
> +[[ "$text" -pcre-match ^d+$ ]] && print text variable contains only 
> "d's".
> +)
> +enditem()


      reply	other threads:[~2004-06-21  3:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <D289C58E-C2AF-11D8-8B47-000A95D2C79E@kalama.no-ip.org>
     [not found] ` <20040620144844.GA24131@scowler.net>
     [not found]   ` <20040620173608.GA38615@quark.hightek.org>
     [not found]     ` <20040620193711.GA15629@scowler.net>
     [not found]       ` <20040620212037.GA39276@quark.hightek.org>
2004-06-20 21:30         ` Clint Adams
2004-06-21  9:28           ` Peter Stephenson
2004-06-20 22:44     ` Clint Adams
2004-06-21  3:38       ` lists [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6D2D3896-C334-11D8-8B47-000A95D2C79E@kalama.no-ip.org \
    --to=lists@kalama.no-ip.org \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).