Re: [pcre-dev] libtool

Page principale
Supprimer ce message
Auteur: Philip Hazel
Date:  
À: H.Merijn Brand, Graycode
CC: pcre-dev
Sujet: Re: [pcre-dev] libtool
On Thu, 12 Jul 2012, H.Merijn Brand wrote:

> One of the things that the copied config.h.generic doe not make
> clear is if the defines I want need
>
> #define WHATEVER 1
>
> or
>
> #define WHATEVER
>
> I chose to use the first on all instances


I have edited the file so that (I hope) it is now clear what the defines
should be. In many cases, WHATEVER just needs to be defined; it doesn't
matter what the value is.

> Core was generated by `pcretest'.
> Program terminated with signal 11, Segmentation fault.
> #0 0x0000000100037688 in find_fixedlength ()
> (gdb) where
> #0 0x0000000100037688 in find_fixedlength ()
> #1 0x0000000100037ae8 in compile_regex ()
> #2 0x0000000100036434 in compile_branch ()
> #3 0x00000001000379ac in compile_regex ()
> #4 0x0000000100039374 in pcre_compile2 ()
> #5 0x0000000100039a44 in pcre_compile ()
> #6 0x000000010000395c in main ()


Scanning the code, I can't see any obvious reason why this should happen
for testdata/testinput4.

> Re-building with -g:
>
> (gdb) where
> warning: (Internal error: pc 0x100012af8 in read in psymtab, but not in symtab.)
>
> warning: (Internal error: pc 0x100012af8 in read in psymtab, but not in symtab.)
>
> #0 0x0000000100012af8 in find_fixedlength () at /usr/include/sys/time.h:231


Looks like the same crash, but what time.h has to do with it I don't
know, because there is no use of time in find_fixedlength(). I wonder if
there is some macro defined in your /usr/include/sys/time.h that is
clashing with something in the code? The Gentoo Linux version of the
file doesn't have that many lines. If you can send me a copy of your
time.h I can take a look.

Do you get the same crash if you build PCRE using autotools or CMake?

On Thu, 12 Jul 2012, Graycode wrote:

> NON-AUTOTOOLS-BUILD section "GENERIC INSTRUCTIONS FOR THE PCRE C
> LIBRARY" steps (6) and (8) seem incorrect. They indicate a need for
> pcre_jit_compile.c only if you have #defined SUPPORT_JIT.
>
> In fact, pcre_jit_compile.c may always be required. That c file
> supplies dummy functions when you have not #defined SUPPORT_JIT.


Yes, indeed. It was a bug (my mistake) in NON-AUTOTOOLS-BUILD. I have
now committed a revised version that makes it clear that you must always
compile pcre_jit_compile.c.

Thanks for doing this test.

Philip

--
Philip Hazel