/packages/httpd24/src/apr/apr24.pas

https://github.com/slibre/freepascal · Pascal · 142 lines · 57 code · 17 blank · 68 comment · 0 complexity · 15516577f57ed1092a8187d6cc9dc620 MD5 · raw file

  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. unit apr24;
  17. {$ifdef fpc}
  18. {$mode delphi}{$H+}
  19. {$endif}
  20. {$ifdef Unix}
  21. {$PACKRECORDS C}
  22. {$endif}
  23. {$DEFINE Apache2_4}
  24. {$DEFINE FPCAPACHE_2_4}
  25. interface
  26. uses
  27. {$ifdef WINDOWS}
  28. Windows,
  29. {$ELSE}
  30. UnixType,
  31. {$ENDIF}
  32. SysUtils, ctypes;
  33. const
  34. {$IFDEF WINDOWS}
  35. LibAPR = 'libapr-1.dll';
  36. {$ELSE}
  37. LibAPR = '';
  38. {$ENDIF}
  39. {$IF DEFINED(WINDOWS) AND NOT DEFINED(WIN64)}//Win64 is same as Linux, no funky function name changes
  40. LibNamePrefix = '_';
  41. LibSuff_ = '_';
  42. LibSuff0 = '@0';
  43. LibSuff4 = '@4';
  44. LibSuff8 = '@8';
  45. LibSuff12 = '@12';
  46. LibSuff16 = '@16';
  47. LibSuff20 = '@20';
  48. LibSuff24 = '@24';
  49. LibSuff28 = '@28';
  50. LibSuff32 = '@32';
  51. {$ELSE}
  52. LibNamePrefix = '';
  53. LibSuff_ = '_';
  54. LibSuff0 = '';
  55. LibSuff4 = '';
  56. LibSuff8 = '';
  57. LibSuff12 = '';
  58. LibSuff16 = '';
  59. LibSuff20 = '';
  60. LibSuff24 = '';
  61. LibSuff28 = '';
  62. LibSuff32 = '';
  63. {$ENDIF}
  64. {**********************************************************}
  65. { Declarations moved here to be on top of all declarations }
  66. {**********************************************************}
  67. {from apr-util-X.X.X/include/apr_hooks.h}
  68. //* Hook orderings */
  69. //** run this hook first, before ANYTHING */
  70. APR_HOOK_REALLY_FIRST = (-10);
  71. //** run this hook first */
  72. APR_HOOK_FIRST = 0;
  73. //** run this hook somewhere */
  74. APR_HOOK_MIDDLE = 10;
  75. //** run this hook after every other hook which is defined*/
  76. APR_HOOK_LAST = 20;
  77. //** run this hook last, after EVERYTHING */
  78. APR_HOOK_REALLY_LAST = 30;
  79. type
  80. apr_int64_t = Int64;
  81. apr_uint64_t = QWord;
  82. apr_off_t = Int64;
  83. Papr_off_t = ^apr_off_t;
  84. apr_size_t = size_t;
  85. Papr_size_t = ^apr_size_t;
  86. apr_int32_t = LongInt;
  87. apr_uint32_t = LongWord;
  88. apr_ino_t = apr_uint64_t;
  89. pid_t = Longint;
  90. Ppid_t = ^pid_t;
  91. time_t = LongInt;//ansi time_t
  92. Papr_file_t = Pointer;//
  93. Pap_filter_t = Pointer;//temporary, it is in util_filter.inc
  94. {from apr_hash.h (real struct is defined in apr_hash.c)}
  95. apr_hash_t = record end;
  96. Papr_hash_t = ^apr_hash_t;
  97. {apr_bucket_alloc_t is found in apr-util-X.X.X/buckets/apr_buckets_alloc.c
  98. and not .h header file declared}
  99. Papr_bucket_alloc_t = Pointer;//^apr_bucket_alloc_t;
  100. {$IFNDEF WINDOWS}
  101. va_list = Pointer;
  102. {$ENDIF}
  103. {$include apr_errno.inc}
  104. {$include apr_pools.inc}
  105. //{$include apr_general.inc}
  106. //{$include apr_dso.inc}
  107. {$include apr_user.inc}
  108. {$include apr_time.inc}
  109. {$include apr_tables.inc}
  110. {$include apr_file_info.inc}
  111. //{$include apr_file_io.inc}
  112. {$include apr_strings.inc}
  113. //{$include apr_lib.inc}
  114. //{$include apr_signal.inc}
  115. //{$include apr_network_io.inc}
  116. //{$include apr_hash.inc}
  117. {.$include apr_portable.inc}
  118. {.$include ../aprutils/apr_uri.inc}
  119. //{$include apr_thread_proc.inc}
  120. {$include apr_version.inc}
  121. //{$include apr_poll.inc}
  122. //moved from http_protocol.h(http_protocol.inc)
  123. {$include apr_mmap.inc}
  124. implementation
  125. end.