[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mod-security-users
Subject:    Re: [mod-security-users] pcre.h not found although it's in place
From:       Peter Haraldson <peter () tuxit ! se>
Date:       2011-06-08 11:14:45
Message-ID: 4DEF59A5.7090607 () tuxit ! se
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


So this problem is now solved, here's the solution:
I tried according to Breno Silva's suggestions, the first line
/./configure --with-pcre=/nih/pcre-8.12/pcre-config
/did not change anything.
However, second line
/make CPPFLAGS=-I/nih/pcre-8.12/include/
/there's the solution. (With standard "./configure 
--with-pcre=/nih/pcre-8.12/" )

Thanks a lot!
Peter Haraldson


Breno Silva wrote:
> Can your try :
>
> ./configure --with-pcre=/nih/pcre-8.12//pcre-config /
> make CPPFLAGS=-I/nih/pcre-8.12/include/
>
> thanks
>
> Breno
>
> On Tue, May 31, 2011 at 4:18 AM, Peter Haraldson <peter@tuxit.se 
> <mailto:peter@tuxit.se>> wrote:
>
>     On a webserver running SLES 11 I'm trying to compile
>     mod_security_2.6.0.
>     The error is related to pcre:
>     /In file included from modsecurity.h:36,
>                      from mod_security2.c:20:
>     msc_pcre.h:20:18: error: pcre.h: Filen eller katalogen finns inte
>     (= "File or directory not found")
>     mod_security2.c: In function ‘version’:
>     mod_security2.c:87: error: ‘PCRE_MAJOR’ undeclared (first use in
>     this function)
>     mod_security2.c:87: error: (Each undeclared identifier is reported
>     only once
>     mod_security2.c:87: error: for each function it appears in.)
>     mod_security2.c:87: error: ‘PCRE_MINOR’ undeclared (first use in
>     this function)
>     mod_security2.c:93: warning: passing argument 1 of ‘strstr’ makes
>     pointer from integer without a cast
>     /
>     Strange thing is that pcre.h is in the right place, defined by
>     --with-pcre=/nih/pcre-8.12/
>
>     *Servers setup:*
>     Minimal installation of SLES11.
>     Compiled manually: openssl-1.0.0d, pcre-8.12, apache-2.2.19,
>     php-5.2.17 - all under directory /nih/
>     Both apache and php are compiled with
>     "--with-pcre=/nih/pcre-8.12/" without any problems.
>
>     Compiling mod_security-2.6.0 with:
>     /./configure --with-apxs=/nih/httpd-2.2.19/bin/apxs
>     --with-pcre=/nih/pcre-8.12/
>     --with-apr=/nih/httpd-2.2.19/bin/apr-1-config
>     --with-apu=/nih/httpd-2.2.19/bin/apu-1-config
>     /
>     *In Makefile:*
>     /usr/local/src/modsecurity-apache_2.6.0 # cat Makefile |grep PCRE
>     /MODSEC_APXS_EXTRA_CFLAGS =  -Wc,-DWITH_PCRE_STUDY
>     -Wc,-DMODSEC_PCRE_MATCH_LIMIT=1500
>     -Wc,-DMODSEC_PCRE_MATCH_LIMIT_RECURSION=1500
>     MODSEC_EXTRA_CFLAGS = -DWITH_PCRE_STUDY
>     -DMODSEC_PCRE_MATCH_LIMIT=1500
>     -DMODSEC_PCRE_MATCH_LIMIT_RECURSION=1500
>     PCRE_CFLAGS = -I/nih/pcre-8.12/include
>     PCRE_CONFIG = /nih/pcre-8.12//bin/pcre-config
>     PCRE_CPPFLAGS =
>     PCRE_LDADD = -L/nih/pcre-8.12/lib -lpcre
>     PCRE_LDFLAGS =
>     PCRE_VERSION = 8.12/
>
>     # ls /nih/pcre-8.12/include/
>     /pcrecpparg.h  pcrecpp.h  pcre.h  pcreposix.h  pcre_scanner.h 
>     pcre_stringpiece.h
>     / # ls /nih/pcre-8.12/bin/
>     /pcre-config  pcregrep  pcretest
>     /
>     So everything is in place, mod_security has correct options.
>     Still running"make" gives error above, "pcre.h not found"
>     Any ideas of how to solve this?
>
>     Regards
>     Peter Haraldson
>
>     -- 
>     Peter Haraldson
>     peter@tuxit.se <mailto:peter@tuxit.se>
>     018-495 62 30 
>         
>
>
>     ------------------------------------------------------------------------------
>     Simplify data backup and recovery for your virtual environment
>     with vRanger.
>     Installation's a snap, and flexible recovery options mean your
>     data is safe,
>     secure and there when you need it. Data protection magic?
>     Nope - It's vRanger. Get your free trial download today.
>     http://p.sf.net/sfu/quest-sfdev2dev
>     _______________________________________________
>     mod-security-users mailing list
>     mod-security-users@lists.sourceforge.net
>     <mailto:mod-security-users@lists.sourceforge.net>
>     https://lists.sourceforge.net/lists/listinfo/mod-security-users
>     ModSecurity Services from Trustwave's SpiderLabs:
>     https://www.trustwave.com/spiderLabs.php
>
>

-- 
Peter Haraldson
peter@tuxit.se
018-495 62 30 


[Attachment #5 (text/html)]

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=windows-1252"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
So this problem is now solved, here's the solution:<br>
I tried according to Breno Silva's suggestions, the first line<br>
<i>./configure --with-pcre=/nih/pcre-8.12/pcre-config<br>
</i>did not change anything. <br>
However, second line <br>
<i>make CPPFLAGS=-I/nih/pcre-8.12/include/<br>
</i>there's the solution. (With standard "./configure
--with-pcre=/nih/pcre-8.12/" )<br>
<br>
Thanks a lot!<br>
Peter Haraldson<br>
<br>
<br>
Breno Silva wrote:
<blockquote
 cite="mid:BANLkTi=OjooZW8UohFGXtQS8x9JRUToTzQ@mail.gmail.com"
 type="cite">Can your try :<br>
  <br>
./configure --with-pcre=/nih/pcre-8.12/<i>pcre-config </i><br>
make CPPFLAGS=-I/nih/pcre-8.12/include/<br>
  <br>
thanks<br>
  <br>
Breno<br>
  <br>
  <div class="gmail_quote">On Tue, May 31, 2011 at 4:18 AM, Peter
Haraldson <span dir="ltr">&lt;<a moz-do-not-send="true"
 href="mailto:peter@tuxit.se">peter@tuxit.se</a>&gt;</span> wrote:<br>
  <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; \
padding-left: 1ex;">  <div bgcolor="#ffffff" text="#000000">On a webserver running \
SLES 11 I'm trying to compile mod_security_2.6.0.<br>
The error is related to pcre: <br>
    <i>In file included from modsecurity.h:36,<br>
                 from mod_security2.c:20:<br>
msc_pcre.h:20:18: error: pcre.h: Filen eller katalogen finns inte (=
"File or directory not found")<br>
mod_security2.c: In function ‘version’:<br>
mod_security2.c:87: error: ‘PCRE_MAJOR’ undeclared (first use in this
function)<br>
mod_security2.c:87: error: (Each undeclared identifier is reported only
once<br>
mod_security2.c:87: error: for each function it appears in.)<br>
mod_security2.c:87: error: ‘PCRE_MINOR’ undeclared (first use in this
function)<br>
mod_security2.c:93: warning: passing argument 1 of ‘strstr’ makes
pointer from integer without a cast<br>
    </i><br>
Strange thing is that pcre.h is in the right place, defined by
--with-pcre=/nih/pcre-8.12/<br>
    <br>
    <b>Servers setup:</b><br>
Minimal installation of SLES11.<br>
Compiled manually: openssl-1.0.0d, pcre-8.12, apache-2.2.19, php-5.2.17
- all under directory /nih/<br>
Both apache and php are compiled with "--with-pcre=/nih/pcre-8.12/"
without any problems.<br>
    <br>
Compiling mod_security-2.6.0 with: <br>
    <i>./configure --with-apxs=/nih/httpd-2.2.19/bin/apxs
--with-pcre=/nih/pcre-8.12/
--with-apr=/nih/httpd-2.2.19/bin/apr-1-config
--with-apu=/nih/httpd-2.2.19/bin/apu-1-config<br>
    </i><br>
    <b>In Makefile:</b><br>
/usr/local/src/modsecurity-apache_2.6.0 # cat Makefile |grep PCRE<br>
    <i>MODSEC_APXS_EXTRA_CFLAGS =  -Wc,-DWITH_PCRE_STUDY
-Wc,-DMODSEC_PCRE_MATCH_LIMIT=1500
-Wc,-DMODSEC_PCRE_MATCH_LIMIT_RECURSION=1500<br>
MODSEC_EXTRA_CFLAGS = -DWITH_PCRE_STUDY -DMODSEC_PCRE_MATCH_LIMIT=1500
-DMODSEC_PCRE_MATCH_LIMIT_RECURSION=1500<br>
PCRE_CFLAGS = -I/nih/pcre-8.12/include<br>
PCRE_CONFIG = /nih/pcre-8.12//bin/pcre-config<br>
PCRE_CPPFLAGS =<br>
PCRE_LDADD = -L/nih/pcre-8.12/lib -lpcre<br>
PCRE_LDFLAGS =<br>
PCRE_VERSION = 8.12</i><br>
    <br>
# ls /nih/pcre-8.12/include/<br>
    <i>pcrecpparg.h  pcrecpp.h  pcre.h  pcreposix.h  pcre_scanner.h 
pcre_stringpiece.h<br>
    </i> # ls /nih/pcre-8.12/bin/<br>
    <i>pcre-config  pcregrep  pcretest<br>
    </i><br>
So everything is in place, mod_security has correct options.<br>
Still running"make" gives error above, "pcre.h not found"<br>
Any ideas of how to solve this?<br>
    <br>
Regards<br>
Peter Haraldson<br>
    <pre cols="72">-- 
Peter Haraldson
<a moz-do-not-send="true" href="mailto:peter@tuxit.se" \
target="_blank">peter@tuxit.se</a> 018-495 62 30 
    </pre>
    </div>
    <br>
------------------------------------------------------------------------------<br>
Simplify data backup and recovery for your virtual environment with
vRanger.<br>
Installation's a snap, and flexible recovery options mean your data is
safe,<br>
secure and there when you need it. Data protection magic?<br>
Nope - It's vRanger. Get your free trial download today.<br>
    <a moz-do-not-send="true" href="http://p.sf.net/sfu/quest-sfdev2dev"
 target="_blank">http://p.sf.net/sfu/quest-sfdev2dev</a><br>
_______________________________________________<br>
mod-security-users mailing list<br>
    <a moz-do-not-send="true"
 href="mailto:mod-security-users@lists.sourceforge.net">mod-security-users@lists.sourceforge.net</a><br>
  <a moz-do-not-send="true"
 href="https://lists.sourceforge.net/lists/listinfo/mod-security-users"
 target="_blank">https://lists.sourceforge.net/lists/listinfo/mod-security-users</a><br>
 ModSecurity Services from Trustwave's SpiderLabs:<br>
    <a moz-do-not-send="true"
 href="https://www.trustwave.com/spiderLabs.php" \
target="_blank">https://www.trustwave.com/spiderLabs.php</a><br>  <br>
  </blockquote>
  </div>
  <br>
</blockquote>
<br>
<pre class="moz-signature" cols="72">-- 
Peter Haraldson
<a class="moz-txt-link-abbreviated" href="mailto:peter@tuxit.se">peter@tuxit.se</a>
018-495 62 30 
</pre>
</body>
</html>



------------------------------------------------------------------------------
EditLive Enterprise is the world's most technically advanced content
authoring tool. Experience the power of Track Changes, Inline Image
Editing and ensure content is compliant with Accessibility Checking.
http://p.sf.net/sfu/ephox-dev2dev

_______________________________________________
mod-security-users mailing list
mod-security-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mod-security-users
ModSecurity Services from Trustwave's SpiderLabs:
https://www.trustwave.com/spiderLabs.php


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic