WARNING: uuid.h: present but cannot be compiled

Поиск
Список
Период
Сортировка
Искать

WARNING: uuid.h: present but cannot be compiled

От:
"David E. Wheeler" <david@justatheory.com>
Дата:
I'm building 8.4beta1 on Mac OS X 10.5.6. I have ossp-uuid installed  
with its includes in /usr/local/include/ossp-uuid. I'm building  
PostgreSQL like so:

export CPPFLAGS="-I/usr/local/include/ossp-uuid"
./configure --with-libedit-preferred --with-bonjour --with-perl PERL=/ 
user/local/bin/perl \
--with-openssl --with-pam --with-krb5 --with-libxml --with-ldap --with- 
ossp-uuid \
--with-libs=/usr/local/lib --with-includes=/usr/local/include -- 
prefix=/usr/local/pgsql

Configure generates this warning:

checking uuid.h presence... yes
configure: WARNING: uuid.h: present but cannot be compiled
configure: WARNING: uuid.h:     check for missing prerequisite headers?
configure: WARNING: uuid.h: see the Autoconf documentation
configure: WARNING: uuid.h:     section "Present But Cannot Be Compiled"
configure: WARNING: uuid.h: proceeding with the preprocessor's result
configure: WARNING: uuid.h: in the future, the compiler will take  
precedence
configure: WARNING:     ## ---------------------------------------- ##
configure: WARNING:     ## Report this to pgsql-bugs@postgresql.org ##
configure: WARNING:     ## ---------------------------------------- ##
checking for uuid.h... yes

I guess it's finding Apple's uuid.h and not OSSP's? Do I need to set  
some other environment variable to tell PostgreSQL where to find the  
ossp uuid include?

BTW, I moved OSSP's uuid.h because it caused conflicts with other apps  
that just need Apple's uuid.h. This is a known issue for OSSP UUID:

   http://cvs.ossp.org/tktview?tn=164

Best,

David

Re: WARNING: uuid.h: present but cannot be compiled

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
"David E. Wheeler"  writes:
> I'm building 8.4beta1 on Mac OS X 10.5.6. I have ossp-uuid installed  
> with its includes in /usr/local/include/ossp-uuid.

Well, then you would need --with-includes=/usr/local/include/ossp-uuid
(don't bother setting CPPFLAGS in addition).

> I guess it's finding Apple's uuid.h and not OSSP's?

Yeah, that's what it looks like, although it's odd that that fails
to compile.

			regards, tom lane

Re: WARNING: uuid.h: present but cannot be compiled

От:
"David E. Wheeler" <david@justatheory.com>
Дата:
On Apr 17, 2009, at 7:08 AM, Tom Lane wrote:

> "David E. Wheeler"  writes:
>> I'm building 8.4beta1 on Mac OS X 10.5.6. I have ossp-uuid installed
>> with its includes in /usr/local/include/ossp-uuid.
>
> Well, then you would need --with-includes=3D/usr/local/include/ossp-uuid
> (don't bother setting CPPFLAGS in addition).

Duh, I already had --with-includes for another directory. Thanks.

>> I guess it's finding Apple's uuid.h and not OSSP's?
>
> Yeah, that's what it looks like, although it's odd that that fails
> to compile.

Yeah, seems odd=85

Best,

David

Re: WARNING: uuid.h: present but cannot be compiled

От:
David E. Wheeler <david@kineticode.com>
Дата:
On Apr 17, 2009, at 10:21 AM, David E. Wheeler wrote:

> On Apr 17, 2009, at 9:22 AM, David E. Wheeler wrote:
>
>> So does it not know to look in /usr/local/include/ossp-uuid when  
>> it's looking for uuid.h?
>
> Tried a few more things. No matter where I put uuid.h, configure  
> doesn't seem to find it. I put it in /usr/local/include and ran  
> configure with --with-includes=/usr/local/include and it didn't find  
> it. RhodiumToad said on IRC that it's looking for "ossp/uuid.h", so  
> I tried putting it in /usr/local/include/ossp/ and ran configure  
> with the same --with-include and it still didn't find it. So at this  
> point, I'm unable to figure out how to get configure to find and use  
> the OSSP uuid header. :-(

I take that back. It can find it in the ossp subdirectiry, as  
RhodiumToad said, but it can't compile it:

checking ossp/uuid.h usability... no
checking ossp/uuid.h presence... yes
configure: WARNING: ossp/uuid.h: present but cannot be compiled
configure: WARNING: ossp/uuid.h:     check for missing prerequisite  
headers?
configure: WARNING: ossp/uuid.h: see the Autoconf documentation
configure: WARNING: ossp/uuid.h:     section "Present But Cannot Be  
Compiled"
configure: WARNING: ossp/uuid.h: proceeding with the preprocessor's  
result
configure: WARNING: ossp/uuid.h: in the future, the compiler will take  
precedence
configure: WARNING:     ## ---------------------------------------- ##
configure: WARNING:     ## Report this to pgsql-bugs@postgresql.org ##
configure: WARNING:     ## ---------------------------------------- ##
checking for ossp/uuid.h... yes

Best,

David

Re: WARNING: uuid.h: present but cannot be compiled

От:
David E. Wheeler <david@kineticode.com>
Дата:
On Apr 17, 2009, at 10:47 AM, David E. Wheeler wrote:

> On Apr 17, 2009, at 10:21 AM, David E. Wheeler wrote:
>
>> On Apr 17, 2009, at 9:22 AM, David E. Wheeler wrote:
>>
>>> So does it not know to look in /usr/local/include/ossp-uuid when  
>>> it's looking for uuid.h?
>>
>> Tried a few more things. No matter where I put uuid.h, configure  
>> doesn't seem to find it. I put it in /usr/local/include and ran  
>> configure with --with-includes=/usr/local/include and it didn't  
>> find it. RhodiumToad said on IRC that it's looking for "ossp/ 
>> uuid.h", so I tried putting it in /usr/local/include/ossp/ and ran  
>> configure with the same --with-include and it still didn't find it.  
>> So at this point, I'm unable to figure out how to get configure to  
>> find and use the OSSP uuid header. :-(
>
> I take that back. It can find it in the ossp subdirectiry, as  
> RhodiumToad said, but it can't compile it:
>
> checking ossp/uuid.h usability... no
> checking ossp/uuid.h presence... yes
> configure: WARNING: ossp/uuid.h: present but cannot be compiled
> configure: WARNING: ossp/uuid.h:     check for missing prerequisite  
> headers?
> configure: WARNING: ossp/uuid.h: see the Autoconf documentation
> configure: WARNING: ossp/uuid.h:     section "Present But Cannot Be  
> Compiled"
> configure: WARNING: ossp/uuid.h: proceeding with the preprocessor's  
> result
> configure: WARNING: ossp/uuid.h: in the future, the compiler will  
> take precedence
> configure: WARNING:     ## ---------------------------------------- ##
> configure: WARNING:     ## Report this to pgsql-bugs@postgresql.org ##
> configure: WARNING:     ## ---------------------------------------- ##
> checking for ossp/uuid.h... yes

Oh, and despite that warning, I am in fact able to build and install  
the OSSP UUID contrib module. So I've no idea what that warning is  
about.

Best,

David

Re: WARNING: uuid.h: present but cannot be compiled

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
"David E. Wheeler"  writes:
> I take that back. It can find it in the ossp subdirectiry, as  
> RhodiumToad said, but it can't compile it:

> checking ossp/uuid.h usability... no
> checking ossp/uuid.h presence... yes
> configure: WARNING: ossp/uuid.h: present but cannot be compiled

Why not?  There should be compiler messages in config.log.

			regards, tom lane

Re: WARNING: uuid.h: present but cannot be compiled

От:
"David E. Wheeler" <david@kineticode.com>
Дата:
Вложения:
On Apr 17, 2009, at 11:08 AM, Tom Lane wrote:

> "David E. Wheeler"  writes:
>> I take that back. It can find it in the ossp subdirectiry, as
>> RhodiumToad said, but it can't compile it:
>
>> checking ossp/uuid.h usability... no
>> checking ossp/uuid.h presence... yes
>> configure: WARNING: ossp/uuid.h: present but cannot be compiled
>
> Why not?  There should be compiler messages in config.log.

Dunno. Here's the log for the latest build:




Best,

David

Re: WARNING: uuid.h: present but cannot be compiled

От:
Alvaro Herrera <alvherre@commandprompt.com>
Дата:
David E. Wheeler wrote:
> On Apr 17, 2009, at 11:08 AM, Tom Lane wrote:
>
>> "David E. Wheeler"  writes:
>>> I take that back. It can find it in the ossp subdirectiry, as
>>> RhodiumToad said, but it can't compile it:
>>
>>> checking ossp/uuid.h usability... no
>>> checking ossp/uuid.h presence... yes
>>> configure: WARNING: ossp/uuid.h: present but cannot be compiled
>>
>> Why not?  There should be compiler messages in config.log.
>
> Dunno. Here's the log for the latest build:

configure:13224: checking ossp/uuid.h usability
configure:13241: gcc -no-cpp-precomp -c -O2 -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fwrapv  -I/usr/local/include/libxml2  -I/usr/local/include conftest.c >&5
In file included from conftest.c:98:
/usr/local/include/ossp/uuid.h:94: error: conflicting types for 'uuid_t'
/usr/include/unistd.h:133: error: previous declaration of 'uuid_t' was here

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

Re: WARNING: uuid.h: present but cannot be compiled

От:
"David E. Wheeler" <david@kineticode.com>
Дата:
On Apr 17, 2009, at 11:28 AM, Alvaro Herrera wrote:

>> Dunno. Here's the log for the latest build:
>
> configure:13224: checking ossp/uuid.h usability
> configure:13241: gcc -no-cpp-precomp -c -O2 -Wall -Wmissing- 
> prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif- 
> labels -fno-strict-aliasing -fwrapv  -I/usr/local/include/libxml2  - 
> I/usr/local/include conftest.c >&5
> In file included from conftest.c:98:
> /usr/local/include/ossp/uuid.h:94: error: conflicting types for  
> 'uuid_t'
> /usr/include/unistd.h:133: error: previous declaration of 'uuid_t'  
> was here

Oh, that old canard. So it's just http://cvs.ossp.org/tktview?tn=164  
again.

Thanks,

David
FAQ