[nginx] Added freenginx macro to simplify version detection.
Maxim Dounin
mdounin at mdounin.ru
Thu Jul 3 04:45:48 UTC 2025
details: http://freenginx.org/hg/nginx/rev/a1dd1c5d8e86
branches:
changeset: 9387:a1dd1c5d8e86
user: Maxim Dounin <mdounin at mdounin.ru>
date: Thu Jul 03 07:44:39 2025 +0300
description:
Added freenginx macro to simplify version detection.
For modules which want to be compatible with both freenginx and F5 NGINX
relevant version detection for the r->start_time change in 9379:2edfdf15f9b4
would look like:
#if (defined freenginx && nginx_version >= 1029000)
... use r->start_time
#else
... use r->start_sec
#endif
Requested by Georgy Shelkovy,
https://github.com/freenginx/nginx/issues/12
diffstat:
src/core/nginx.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diffs (12 lines):
diff --git a/src/core/nginx.h b/src/core/nginx.h
--- a/src/core/nginx.h
+++ b/src/core/nginx.h
@@ -12,6 +12,8 @@
#define nginx_version 1029000
#define NGINX_VERSION "1.29.0"
+#define freenginx 1
+
#define NGINX_NAME "freenginx"
#define NGINX_VER NGINX_NAME "/" NGINX_VERSION
More information about the nginx-devel
mailing list