Build SQLite including the platform header for INTEGRITY.

The platform header defines geteuid(), which is necessary for the SQLite
library. The common platform header is also modified to handle being
included from C, and resolves a typo on the way.

Change-Id: I8ace8a11ceac0f541b9c9b0d8112609579224884
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Rolland Dudemaine 2016-03-23 11:17:13 +01:00
parent 8e2d3e3b90
commit 6be6d3bc19
2 changed files with 3 additions and 2 deletions

View File

@ -75,7 +75,7 @@
// INTEGRITY doesn't have getpagesize()
inline int getpagesize()
{
return ::sysconf(_SC_PAGESIZE);
return sysconf(_SC_PAGESIZE);
}
// geteuid() is only available with multi-process posix, but we do not want
@ -97,4 +97,4 @@ inline uid_t getuid(void)
#define QT_OPEN_LARGEFILE 0
#define PATH_MAX 1024
#endif // Q_QNX_PLATFORMDEFS_H
#endif // Q_INTEGRITY_PLATFORMDEFS_H

View File

@ -5,6 +5,7 @@ contains(QT_CONFIG, posix_fallocate):DEFINES += HAVE_POSIX_FALLOCATE=1
winrt: DEFINES += SQLITE_OS_WINRT
winphone: DEFINES += SQLITE_WIN32_FILEMAPPING_API=1
qnx: DEFINES += _QNX_SOURCE
integrity: QMAKE_CFLAGS += -include qplatformdefs.h
INCLUDEPATH += $$PWD/sqlite
SOURCES += $$PWD/sqlite/sqlite3.c