"Fossies" - the Fresh Open Source Software Archive

Member "apr-1.7.0/include/arch/win32/apr_private.h" (29 Nov 2017, 4525 Bytes) of package /linux/www/apr-1.7.0.tar.bz2:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "apr_private.h" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 1.6.5_vs_1.7.0.

    1 /* Licensed to the Apache Software Foundation (ASF) under one or more
    2  * contributor license agreements.  See the NOTICE file distributed with
    3  * this work for additional information regarding copyright ownership.
    4  * The ASF licenses this file to You under the Apache License, Version 2.0
    5  * (the "License"); you may not use this file except in compliance with
    6  * the License.  You may obtain a copy of the License at
    7  *
    8  *     http://www.apache.org/licenses/LICENSE-2.0
    9  *
   10  * Unless required by applicable law or agreed to in writing, software
   11  * distributed under the License is distributed on an "AS IS" BASIS,
   12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   13  * See the License for the specific language governing permissions and
   14  * limitations under the License.
   15  */
   16 
   17 /*
   18  * Note: 
   19  * This is the windows specific autoconf-like config file
   20  * which unix would create at build time.
   21  */
   22 
   23 #ifdef WIN32
   24 
   25 #ifndef APR_PRIVATE_H
   26 #define APR_PRIVATE_H
   27 
   28 /* Include the public APR symbols, include our idea of the 'right'
   29  * subset of the Windows.h header.  This saves us repetition.
   30  */
   31 #include "apr.h"
   32 
   33 /* 
   34  * Add a _very_few_ declarations missing from the restricted set of headers
   35  * (If this list becomes extensive, re-enable the required headers above!)
   36  * winsock headers were excluded by WIN32_LEAN_AND_MEAN, so include them now
   37  */
   38 #ifndef SW_HIDE
   39 #define SW_HIDE             0
   40 #endif
   41 
   42 /* For the misc.h late-loaded dynamic symbols, we need some obscure types 
   43  * Avoid dragging in wtypes.h unless it's absolutely necessary [generally
   44  * not with APR itself, until some GUI-related security is introduced.]
   45  */
   46 #ifndef _WIN32_WCE
   47 #define HAVE_ACLAPI 1
   48 #ifdef __wtypes_h__
   49 #include <accctrl.h>
   50 #else
   51 #define __wtypes_h__
   52 #include <accctrl.h>
   53 #undef __wtypes_h__
   54 #endif
   55 #else
   56 #define HAVE_ACLAPI 0
   57 #endif
   58 
   59 #if APR_HAVE_SYS_TYPES_H
   60 #include <sys/types.h>
   61 #endif
   62 #if APR_HAVE_STDDEF_H
   63 #include <stddef.h>
   64 #endif
   65 #include <stdio.h>
   66 #if APR_HAVE_TIME_H
   67 #include <time.h>
   68 #endif
   69 
   70 /* Use this section to define all of the HAVE_FOO_H
   71  * that are required to build properly.
   72  */
   73 #define HAVE_LIMITS_H 1
   74 #define HAVE_MALLOC_H 1
   75 #define HAVE_SIGNAL_H 1
   76 /* #define HAVE_STDDEF_H 1 why not? */
   77 #define HAVE_STDLIB_H 1
   78 
   79 #define HAVE_STRICMP  1
   80 #define HAVE_STRNICMP 1
   81 #define HAVE_STRDUP   1
   82 #define HAVE_STRSTR   1
   83 #define HAVE_MEMCHR   1
   84 
   85 #define SIGHUP     1
   86 /* 2 is used for SIGINT on windows */
   87 #define SIGQUIT    3
   88 /* 4 is used for SIGILL on windows */
   89 #define SIGTRAP    5
   90 #define SIGIOT     6
   91 #define SIGBUS     7
   92 /* 8 is used for SIGFPE on windows */
   93 #define SIGKILL    9
   94 #define SIGUSR1    10
   95 /* 11 is used for SIGSEGV on windows */
   96 #define SIGUSR2    12
   97 #define SIGPIPE    13
   98 #define SIGALRM    14
   99 /* 15 is used for SIGTERM on windows */
  100 #define SIGSTKFLT  16
  101 #define SIGCHLD    17 
  102 #define SIGCONT    18
  103 #define SIGSTOP    19
  104 #define SIGTSTP    20
  105 /* 21 is used for SIGBREAK on windows */
  106 /* 22 is used for SIGABRT on windows */
  107 #define SIGTTIN    23
  108 #define SIGTTOU    24
  109 #define SIGURG     25
  110 #define SIGXCPU    26
  111 #define SIGXFSZ    27
  112 #define SIGVTALRM  28
  113 #define SIGPROF    29
  114 #define SIGWINCH   30
  115 #define SIGIO      31
  116 
  117 /* APR COMPATABILITY FUNCTIONS
  118  * This section should be used to define functions and
  119  * macros which are need to make Windows features look
  120  * like POSIX features.
  121  */
  122 typedef void (Sigfunc)(int);
  123 
  124 #define sleep(t)                 Sleep((t) * 1000)
  125 
  126 #define SIZEOF_SHORT           2
  127 #define SIZEOF_INT             4
  128 #define SIZEOF_LONGLONG        8
  129 #define SIZEOF_CHAR            1
  130 #define SIZEOF_SSIZE_T         SIZEOF_INT
  131 
  132 unsigned __stdcall SignalHandling(void *);
  133 int thread_ready(void);
  134 
  135 #if !APR_HAVE_ERRNO_H
  136 APR_DECLARE_DATA int errno;
  137 #define ENOSPC 1
  138 #endif
  139 
  140 #if APR_HAVE_IPV6
  141 #define HAVE_GETADDRINFO 1
  142 #define HAVE_GETNAMEINFO 1
  143 #define HAVE_IF_INDEXTONAME 1
  144 #define HAVE_IF_NAMETOINDEX 1
  145 #endif
  146 
  147 /* MSVC 7.0 introduced _strtoi64 */
  148 #if _MSC_VER >= 1300 && _INTEGRAL_MAX_BITS >= 64 && !defined(_WIN32_WCE)
  149 #define APR_INT64_STRFN       _strtoi64
  150 #endif
  151 
  152 #if APR_HAS_LARGE_FILES
  153 #ifdef APR_INT64_STRFN
  154 #define APR_OFF_T_STRFN         APR_INT64_STRFN
  155 #else
  156 #define APR_OFF_T_STRFN         apr_strtoi64
  157 #endif
  158 #else
  159 #if defined(_WIN32_WCE)
  160 #define APR_OFF_T_STRFN         strtol
  161 #else
  162 #define APR_OFF_T_STRFN         strtoi
  163 #endif
  164 #endif
  165 
  166 /* used to check for DWORD overflow in 64bit compiles */
  167 #define APR_DWORD_MAX 0xFFFFFFFFUL
  168 
  169 /*
  170  * Include common private declarations.
  171  */
  172 #include "../apr_private_common.h"
  173 
  174 #endif  /*APR_PRIVATE_H*/
  175 #endif  /*WIN32*/