~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to mkspecs/aix-xlc/qplatformdefs.h

  • Committer: Bazaar Package Importer
  • Author(s): Adam Conrad
  • Date: 2005-08-24 04:09:09 UTC
  • Revision ID: james.westby@ubuntu.com-20050824040909-xmxe9jfr4a0w5671
Tags: upstream-4.0.0
ImportĀ upstreamĀ versionĀ 4.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef QPLATFORMDEFS_H
 
2
#define QPLATFORMDEFS_H
 
3
 
 
4
// Get Qt defines/settings
 
5
 
 
6
#include "qglobal.h"
 
7
 
 
8
// Set any POSIX/XOPEN defines at the top of this file to turn on specific APIs
 
9
 
 
10
#include <unistd.h>
 
11
 
 
12
 
 
13
// We are hot - unistd.h should have turned on the specific APIs we requested
 
14
 
 
15
 
 
16
#include <pthread.h>
 
17
#include <dirent.h>
 
18
#include <fcntl.h>
 
19
#include <grp.h>
 
20
#include <pwd.h>
 
21
#include <signal.h>
 
22
#include <dlfcn.h>
 
23
#include <strings.h> // AIX X11 headers define FD_ZERO using bzero()
 
24
 
 
25
#include <sys/types.h>
 
26
#include <sys/ioctl.h>
 
27
#include <sys/ipc.h>
 
28
#include <sys/time.h>
 
29
#include <sys/select.h>
 
30
#include <sys/shm.h>
 
31
#include <sys/socket.h>
 
32
#include <sys/stat.h>
 
33
#include <sys/wait.h>
 
34
#include <netinet/in.h>
 
35
 
 
36
#ifdef QT_LARGEFILE_SUPPORT
 
37
#define QT_STATBUF              struct stat64
 
38
#define QT_STATBUF4TSTAT        struct stat64
 
39
#define QT_STAT                 ::stat64
 
40
#define QT_FSTAT                ::fstat64
 
41
#define QT_LSTAT                ::lstat64
 
42
#define QT_OPEN                 ::open64
 
43
#define QT_TRUNCATE             ::truncate64
 
44
#define QT_FTRUNCATE            ::ftruncate64
 
45
#define QT_LSEEK                ::lseek64
 
46
#else
 
47
#define QT_STATBUF              struct stat
 
48
#define QT_STATBUF4TSTAT        struct stat
 
49
#define QT_STAT                 ::stat
 
50
#define QT_FSTAT                ::fstat
 
51
#define QT_LSTAT                ::lstat
 
52
#define QT_OPEN                ::open
 
53
#define QT_TRUNCATE            ::truncate
 
54
#define QT_FTRUNCATE           ::ftruncate
 
55
#define QT_LSEEK               ::lseek
 
56
#endif
 
57
 
 
58
#define QT_STAT_REG             S_IFREG
 
59
#define QT_STAT_DIR             S_IFDIR
 
60
#define QT_STAT_MASK            S_IFMT
 
61
#define QT_STAT_LNK             S_IFLNK
 
62
#define QT_SOCKET_CONNECT       ::connect
 
63
#define QT_SOCKET_BIND          ::bind
 
64
#define QT_FILENO               fileno
 
65
#define QT_CLOSE                ::close
 
66
#define QT_READ                 ::read
 
67
#define QT_WRITE                ::write
 
68
#define QT_ACCESS               ::access
 
69
#define QT_GETCWD               ::getcwd
 
70
#define QT_CHDIR                ::chdir
 
71
#define QT_MKDIR                ::mkdir
 
72
#define QT_RMDIR                ::rmdir
 
73
#define QT_OPEN_RDONLY          O_RDONLY
 
74
#define QT_OPEN_WRONLY          O_WRONLY
 
75
#define QT_OPEN_RDWR            O_RDWR
 
76
#define QT_OPEN_CREAT           O_CREAT
 
77
#define QT_OPEN_TRUNC           O_TRUNC
 
78
#define QT_OPEN_APPEND          O_APPEND
 
79
 
 
80
#define QT_SIGNAL_RETTYPE       void
 
81
#define QT_SIGNAL_ARGS          int
 
82
#define QT_SIGNAL_IGNORE        SIG_IGN
 
83
 
 
84
#ifdef _AIX43
 
85
// AIX 4.3 and better
 
86
#define QT_SOCKLEN_T            socklen_t
 
87
#elif _AIX42
 
88
// AIX 4.2
 
89
#define QT_SOCKLEN_T            size_t
 
90
#else
 
91
// AIX 4.1
 
92
#define QT_SOCKLEN_T            size_t
 
93
// override
 
94
#define QT_SOCKOPTLEN_T         int
 
95
#endif
 
96
 
 
97
#if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE-0 >= 500)
 
98
// AIX 4.3 and better
 
99
#define QT_SNPRINTF             ::snprintf
 
100
#define QT_VSNPRINTF            ::vsnprintf
 
101
#endif
 
102
 
 
103
#endif // QPLATFORMDEFS_H