46 #include "qplatformdefs.h" 49 #if defined(_WRS_KERNEL) 52 #include <selectLib.h> 62 void *lfind(
const void*
key,
const void*
base,
size_t*
elements,
size_t size,
63 int (*
compare)(
const void*,
const void*))
65 const char* current = (
char*) base;
66 const char*
const end = (
char*) (current + (*elements) * size);
67 while (current != end) {
69 return (
void*)current;
79 int rand_r(
unsigned int * )
85 int usleep(
unsigned int usec)
87 div_t dt = div(usec, 1000000);
88 struct timespec ts = { dt.quot, dt.rem * 1000 };
90 return nanosleep(&ts, 0);
97 #if defined(Q_CC_DIAB) && !defined(VXWORKS_DKM) && !defined(VXWORKS_RTP) 98 # pragma weak gettimeofday 100 int gettimeofday(
struct timeval *tv,
void *)
103 if (
sizeof(
struct timeval) ==
sizeof(
struct timespec)) {
104 int res = clock_gettime(CLOCK_REALTIME, (
struct timespec *) tv);
111 int res = clock_gettime(CLOCK_REALTIME, &ts);
113 tv->tv_sec = ts.tv_sec;
114 tv->tv_usec = ts.tv_nsec / 1000;
123 #if defined(_WRS_KERNEL) 124 return vmPageSizeGet();
126 return sysconf(_SC_PAGESIZE);
131 int symlink(
const char *,
const char *)
137 ssize_t readlink(
const char *,
char *,
size_t)
144 int truncate(
const char *path, off_t length)
148 int res = ftruncate(fd, length);
180 struct passwd *getpwuid(uid_t uid)
182 static struct passwd pwbuf = {
"root", 0, 0, 0, 0, 0, 0 };
192 struct group *getgrgid(gid_t gid)
194 static struct group grbuf = {
"root", 0, 0, 0 };
208 #endif // Q_OS_VXWORKS
static bool compare(const QVariant::Private *a, const QVariant::Private *b)
Compares a to b.
#define QT_USE_NAMESPACE
This macro expands to using QT_NAMESPACE if QT_NAMESPACE is defined and nothing otherwise.
static const QTextHtmlElement elements[Html_NumElements]
static const KeyPair *const end
int open(const char *, int,...)