php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #24703 failure building sqlite extension
Submitted: 2003-07-18 05:14 UTC Modified: 2003-07-19 07:48 UTC
From: php at sjondamon dot org Assigned:
Status: Wont fix Package: SQLite related
PHP Version: 4.3.2 OS: Windows/Cygwin
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2003-07-18 05:14 UTC] php at sjondamon dot org
Description:
------------
I'm building php on cygwin, and tried to include the sqlite extension. First, building everything static gave me errors, so I decided to build sqlite shared, but that also gave me errors.
Building is standard:

phpize
./configure --with-sqlite
make

the errors I get are below.


Regards, Sjon.

Actual result:
--------------
$ make
/bin/bash /build/php-4.3.2/ext/sqlite/libtool --mode=compile gcc -I/build/php-4.3.2/ext/sqlite/libsqlite/src -I. -I/build/php-4.3.2/ext/sqlite -DPHP_ATOM_INC -I/build/php-4.3.2/ext/sqlite/include -I/build/php-4.3.2/ext/sqlite/main -I/build/php-4.3.2/ext/sqlite -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/Zend -I/usr/include/php/TSRM  -DHAVE_CONFIG_H  -g -O2  -prefer-pic -c /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c -o libsqlite/src/os.lo
 gcc -I/build/php-4.3.2/ext/sqlite/libsqlite/src -I. -I/build/php-4.3.2/ext/sqlite -DPHP_ATOM_INC -I/build/php-4.3.2/ext/sqlite/include -I/build/php-4.3.2/ext/sqlite/main -I/build/php-4.3.2/ext/sqlite -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/Zend -I/usr/include/php/TSRM -DHAVE_CONFIG_H -g -O2 -c /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c  -DPIC -o libsqlite/src/.libs/os.o
In file included from /build/php-4.3.2/ext/sqlite/libsqlite/src/config.h:1,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/sqliteInt.h:16,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:18:
/build/php-4.3.2/ext/sqlite/config.h:53:1: warning: "OS_UNIX" redefined
In file included from /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:17:
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:75:1: warning: this is the location of the previous definition
In file included from /build/php-4.3.2/ext/sqlite/libsqlite/src/config.h:1,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/sqliteInt.h:16,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:18:
/build/php-4.3.2/ext/sqlite/config.h:56:1: warning: "OS_WIN" redefined
In file included from /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:17:
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:74:1: warning: this is the location of the previous definition
In file included from /usr/include/sys/types.h:363,
                 from /usr/include/stdio.h:46,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/vdbe.h:22,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/sqliteInt.h:19,
                 from /build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:18:
/usr/include/cygwin/types.h:39: conflicting types for `off_t'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:127: previous declaration of `off_t'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `findLockInfo':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:186: storage size of `statbuf' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsOpenReadWrite':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:329: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:329: `O_RDWR' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:329: (Each undeclared identifieris reported only once
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:329: for each function it appears in.)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:329: `O_CREAT' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:330: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:331: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:331: `O_RDONLY' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:332: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:340: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:340: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:342: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:343: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsOpenExclusive':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:453: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:454: `O_RDWR' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:454: `O_CREAT' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:454: `O_EXCL' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:455: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:459: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:459: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:461: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:462: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsOpenReadOnly':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:539: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:539: `O_RDONLY' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:540: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:544: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:544: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:546: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:547: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsTempFileName':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:617: storage size of `buf' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsClose':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:708: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:710: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsRead':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:748: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsWrite':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:799: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: At top level:
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:853: conflicting types for `sqliteOsSeek'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:163: previous declaration of `sqliteOsSeek'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsSeek':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:856: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsSync':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:900: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: At top level:
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:932: conflicting types for `sqliteOsTruncate'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:165: previous declaration of `sqliteOsTruncate'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsTruncate':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:935: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: At top level:
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:961: conflicting types for `sqliteOsFileSize'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.h:166: previous declaration of `sqliteOsFileSize'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsFileSize':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:963: storage size of `buf' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:965: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsReadLock':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1080: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1082: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1086: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1087: storage size of `lock' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1089: `F_RDLCK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1092: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1092: `F_SETLK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1097: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsWriteLock':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1190: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1190: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1191: storage size of `lock' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1193: `F_WRLCK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1196: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1196: `F_SETLK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1201: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c: In function `sqliteOsUnlock':
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1299: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1300: structure has no member named `pLock'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1303: storage size of `lock' isn't known
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1305: `F_UNLCK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1308: structure has no member named `fd'
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1308: `F_SETLK' undeclared (first use in this function)
/build/php-4.3.2/ext/sqlite/libsqlite/src/os.c:1313: structure has no member named `pLock'
make: *** [libsqlite/src/os.lo] Error 1

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-07-18 05:20 UTC] php at sjondamon dot org
oh, and sqlite version is 1.0, latest from pear.
 [2003-07-18 05:47 UTC] wez@php.net
cygwin is not a supported configuration for PHP.
However, if you come up with a patch, it will most likely be comitted.
 [2003-07-18 10:07 UTC] php at sjondamon dot org
the patch did help, but then another error appeared.
It seems that /usr/include/cygwin/types.h has off_t defined like "typedef __off32_t off_t;" where in os.h it's "typedef long long off_t;", wich caused the next set of errors.

It seems that there's more borked, but then in the whole cygwin/php region. if I specify --prefix with configure (in /ext/xxx), it still insists on installing to /usr, and while I used --with-sqlite=shared, it will only build and install .a files...


I guess it's time for some real unix :)


I have no intension nor knowledge on fixing this, so unless anybody want's more info, this bug can be closed/suspended/etc.


Sjon.
 [2003-07-18 10:08 UTC] php at sjondamon dot org
to clarify: os.h => ext/sqlite/libsqlite/src/os.h
 [2003-07-19 07:48 UTC] sniper@php.net
You could try the snapshots instead, you might have some non-working autoconf/etc. there. But in any case, Cygwin is not (and will not be) on our unwritten supported platforms list.

I committed this small fix though.

 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Thu Dec 03 11:01:23 2020 UTC