File: osdetect.h

package info (click to toggle)
squid 7.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 33,440 kB
  • sloc: cpp: 184,513; ansic: 12,442; sh: 5,688; makefile: 5,247; perl: 2,560; sql: 326; python: 240; awk: 141; sed: 1
file content (88 lines) | stat: -rw-r--r-- 2,445 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/*
 * Copyright (C) 1996-2025 The Squid Software Foundation and contributors
 *
 * Squid software is distributed under GPLv2+ license and includes
 * contributions from numerous individuals and organizations.
 * Please see the COPYING and CONTRIBUTORS files for details.
 */

#ifndef SQUID_COMPAT_OSDETECT_H
#define SQUID_COMPAT_OSDETECT_H

/****************************************************************************
 *--------------------------------------------------------------------------*
 * DO *NOT* MAKE ANY CHANGES below here unless you know what you're doing...*
 *--------------------------------------------------------------------------*
 ****************************************************************************/

/*
 * Define the _SQUID_TYPE_ based on a guess of the OS.
 *
 * NP: This MUST come first in compat.h with no OS-specific includes
 *     or other definitions within this if-else structure.
 */

/* SUN SOLARIS / OPENSOLARIS */
#if defined(__sun__) || defined(__sun) || defined(__SUNPRO_CC) || defined(__SunOS_OSversion)

#if defined(__SVR4) /* Solaris */
#define _SQUID_SOLARIS_ 1
#else /* SunOS */
#define _SQUID_SUNOS_ 1
#endif /* __SVR4 */

#elif defined(__hpux)       /* HP-UX - SysV-like? */
#define _SQUID_HPUX_ 1

#elif defined(__osf__)      /* OSF/1 */
#define _SQUID_OSF_ 1

#elif defined(_AIX)     /* AIX */
#define _SQUID_AIX_ 1

#elif defined(__linux__)    /* Linux. WARNING: solaris-x86 also sets this */
#define _SQUID_LINUX_ 1

#elif defined(__FreeBSD__)  /* FreeBSD */
#define _SQUID_FREEBSD_ 1

#elif defined(__FreeBSD_kernel__)      /* GNU/kFreeBSD */
#define _SQUID_KFREEBSD_ 1

#elif defined(__sgi__)  || defined(sgi) || defined(__sgi)   /* SGI */
#define _SQUID_SGI_ 1

#elif defined(__NetBSD__)
#define _SQUID_NETBSD_ 1

#elif defined(__OpenBSD__)
#define _SQUID_OPENBSD_ 1

#elif defined(__DragonFly__)
#define _SQUID_DRAGONFLY_ 1

#elif defined(__CYGWIN__)
#define _SQUID_CYGWIN_ 1

#elif defined(__MINGW32__) || defined(__MINGW__)
#define _SQUID_MINGW_ 1

#elif defined(WIN32) || defined(WINNT) || defined(__WIN32__) || defined(__WIN32)
#define _SQUID_WINDOWS_ 1

#elif defined(__APPLE__)
#define _SQUID_APPLE_ 1

#elif defined(sony_news) && defined(__svr4)
#define _SQUID_NEWSOS6_ 1

#elif defined(__QNX__)
#define _SQUID_QNX_ 1

#elif defined(__EMX__) || defined(OS2) || defined(__OS2__)
#define _SQUID_OS2_ 1

#endif /* OS automatic detection */

#endif /* SQUID_COMPAT_OSDETECT_H */