]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
REORG: include: move acl.h to haproxy/acl.h{,-t}.h
authorWilly Tarreau <w@1wt.eu>
Thu, 4 Jun 2020 17:11:43 +0000 (19:11 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 11 Jun 2020 08:18:58 +0000 (10:18 +0200)
The files were moved almost as-is, just dropping arg-t and auth-t from
acl-t but keeping arg-t in acl.h. It was useful to revisit the call places
since a handful of files used to continue to include acl.h while they did
not need it at all. Struct stream was only made a forward declaration
since not otherwise needed.

25 files changed:
include/haproxy/acl-t.h [moved from include/types/acl.h with 95% similarity]
include/haproxy/acl.h [moved from include/proto/acl.h with 97% similarity]
include/types/fcgi-app.h
include/types/proxy.h
src/acl.c
src/auth.c
src/backend.c
src/cfgparse-listen.c
src/cfgparse.c
src/compression.c
src/fcgi-app.c
src/flt_spoe.c
src/frontend.c
src/haproxy.c
src/http_acl.c
src/http_act.c
src/http_ana.c
src/http_rules.c
src/listener.c
src/payload.c
src/peers.c
src/ssl_sample.c
src/ssl_sock.c
src/stream.c
src/tcp_rules.c

similarity index 95%
rename from include/types/acl.h
rename to include/haproxy/acl-t.h
index d9f408435e0cf48579b5e69068514bfce816b98e..3e3762c4ed410f392e32984d3b5427b4261e8db7 100644 (file)
@@ -1,8 +1,8 @@
 /*
- * include/types/acl.h
+ * include/haproxy/acl-t.h
  * This file provides structures and types for ACLs.
  *
- * Copyright (C) 2000-2012 Willy Tarreau - w@1wt.eu
+ * Copyright (C) 2000-2020 Willy Tarreau - w@1wt.eu
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#ifndef _TYPES_ACL_H
-#define _TYPES_ACL_H
+#ifndef _HAPROXY_ACL_T_H
+#define _HAPROXY_ACL_T_H
 
-#include <haproxy/auth-t.h>
+#include <import/ebmbtree.h>
+
+#include <haproxy/list-t.h>
 #include <haproxy/pattern-t.h>
 #include <haproxy/api-t.h>
-#include <haproxy/list-t.h>
 
-#include <haproxy/arg-t.h>
 #include <types/proxy.h>
 #include <types/server.h>
 
-#include <import/ebmbtree.h>
 
 /* ACL test result.
  *
@@ -70,10 +69,6 @@ enum acl_cond_pol {
        ACL_COND_UNLESS,        /* negative condition (after 'unless') */
 };
 
-/* some dummy declarations to silent the compiler */
-struct proxy;
-struct stream;
-
 /*
  * ACL keyword: Associates keywords with parsers, methods to retrieve the value and testers.
  */
@@ -157,7 +152,7 @@ struct acl_cond {
        int line;                   /* line in the config file where the condition is declared */
 };
 
-#endif /* _TYPES_ACL_H */
+#endif /* _HAPROXY_ACL_T_H */
 
 /*
  * Local variables:
similarity index 97%
rename from include/proto/acl.h
rename to include/haproxy/acl.h
index 56ae22899d1b352baca1b587ef43994b07993787..fcf50a5fcc27e58438db7c83bd499a30c511bc02 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * include/proto/acl.h
+ * include/haproxy/acl.h
  * This file provides interface definitions for ACL manipulation.
  *
  * Copyright (C) 2000-2013 Willy Tarreau - w@1wt.eu
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#ifndef _PROTO_ACL_H
-#define _PROTO_ACL_H
+#ifndef _HAPROXY_ACL_H
+#define _HAPROXY_ACL_H
 
+#include <haproxy/acl-t.h>
+#include <haproxy/arg-t.h>
 #include <haproxy/api.h>
-#include <types/acl.h>
+
+struct stream;
 
 /*
  * FIXME: we need destructor functions too !
@@ -144,7 +147,7 @@ void acl_unregister_keywords(struct acl_kw_list *kwl);
 int init_acl();
 
 
-#endif /* _PROTO_ACL_H */
+#endif /* _HAPROXY_ACL_H */
 
 /*
  * Local variables:
index c82f39a3862b70a93b66cd1ba5de7aa13c34cbbc..b314d69e0a5ca384db329b903a202608d04b9901 100644 (file)
@@ -22,6 +22,7 @@
 #ifndef _TYPES_HTTP_FCGI_H
 #define _TYPES_HTTP_FCGI_H
 
+#include <haproxy/acl-t.h>
 #include <haproxy/api-t.h>
 #include <import/ist.h>
 #include <haproxy/fcgi.h>
@@ -30,7 +31,6 @@
 
 #include <import/ebistree.h>
 
-#include <types/acl.h>
 #include <types/filters.h>
 
 #define FCGI_APP_FL_KEEP_CONN     0x00000001 /* Keep the connection alive */
index 7579d8a2735c7c69c1ce3bd912466461748dd0fd..53d9e3c0dbb9b3266a1d211fc98476a93c0ca3a7 100644 (file)
@@ -27,6 +27,7 @@
 #include <netinet/in.h>
 #include <arpa/inet.h>
 
+#include <haproxy/arg-t.h>
 #include <haproxy/api-t.h>
 #include <haproxy/check-t.h>
 #include <haproxy/chunk.h>
@@ -39,7 +40,7 @@
 #include <import/eb32tree.h>
 #include <import/ebistree.h>
 
-#include <types/acl.h>
+#include <haproxy/acl-t.h>
 #include <types/backend.h>
 #include <types/filters.h>
 #include <haproxy/freq_ctr-t.h>
index c0b698550fbe2d33caddc9c60563141d94f5287f..ea0a54dc15e603e189cd2195e666142729866981 100644 (file)
--- a/src/acl.c
+++ b/src/acl.c
@@ -14,6 +14,7 @@
 #include <stdio.h>
 #include <string.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/auth.h>
 #include <haproxy/api.h>
 #include <haproxy/list.h>
@@ -23,7 +24,6 @@
 
 #include <haproxy/global.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/channel.h>
 #include <proto/log.h>
index fe21a458d0a4934c324b712b8dde559ea8d32609..faac16d4e2c63cd715a2bdc620e12bcae2367e87 100644 (file)
@@ -32,7 +32,6 @@
 #include <haproxy/pattern-t.h>
 #include <haproxy/thread.h>
 
-#include <proto/acl.h>
 #include <proto/log.h>
 
 struct userlist *userlist = NULL;    /* list of all existing userlists */
index b7c47ccf848a44a2c36da35d0b211afb37b5a591..f78742771621d0c9b3bc10fe93a2de69ecd60aed 100644 (file)
@@ -19,6 +19,7 @@
 #include <ctype.h>
 #include <sys/types.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <haproxy/check.h>
 #include <haproxy/frontend.h>
@@ -40,7 +41,6 @@
 
 #include <haproxy/global.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/backend.h>
 #include <proto/channel.h>
index 51e118c4d86b1cb8de9bdfe3fdb0538d41d35d8e..0c6fa35b76e75a5944199e176c43b1d1315ecadb 100644 (file)
@@ -14,6 +14,7 @@
 #include <common/cfgparse.h>
 #include <common/uri_auth.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/capture-t.h>
 #include <haproxy/check.h>
 #include <haproxy/compression-t.h>
@@ -25,7 +26,6 @@
 #include <haproxy/sample.h>
 #include <types/stats.h>
 
-#include <proto/acl.h>
 #include <haproxy/protocol.h>
 #include <proto/proxy.h>
 #include <proto/server.h>
index 3de138f71bac15b25820c93ea30f385ba0be129e..376430f267ce1beb996c7a1adc15a9169cf3dd03 100644 (file)
@@ -33,6 +33,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/action-t.h>
 #include <haproxy/auth.h>
 #include <haproxy/api.h>
@@ -66,7 +67,6 @@
 #include <haproxy/global.h>
 #include <types/stats.h>
 
-#include <proto/acl.h>
 #include <proto/backend.h>
 #include <proto/channel.h>
 #include <proto/stats.h>
index 081bf03bed55b63701c46e02eb0a84cb633a5805..f77292cf4a56b52122a9cec7593b3af951581c8d 100644 (file)
@@ -35,7 +35,6 @@
 #include <haproxy/global.h>
 #include <haproxy/compression-t.h>
 
-#include <proto/acl.h>
 #include <haproxy/compression.h>
 #include <haproxy/freq_ctr.h>
 #include <proto/stream.h>
index 0db8e795a99fe110667999b83a5fdace3e3a91a7..dda4b3a998c22a328fbb7c2a935b74d73651ee76 100644 (file)
@@ -10,6 +10,7 @@
  *
  */
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <haproxy/chunk.h>
 #include <common/cfgparse.h>
@@ -23,7 +24,6 @@
 
 #include <haproxy/global.h>
 
-#include <proto/acl.h>
 #include <proto/fcgi-app.h>
 #include <proto/filters.h>
 #include <proto/log.h>
index 1ffa4a7806a6906386c7bc6f5e1e5e2a9739631a..7d36a8e0ce90cae211d8abc4eb61776c6cc807a6 100644 (file)
@@ -12,6 +12,7 @@
 #include <ctype.h>
 #include <errno.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/action-t.h>
 #include <haproxy/api.h>
 #include <common/cfgparse.h>
@@ -31,7 +32,6 @@
 #include <haproxy/global.h>
 #include <types/spoe.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/backend.h>
 #include <proto/filters.h>
index 050a08fb8411f322b7dca047d1bf72e3088ff5ac..068e8d69f7c9418a453e81f2d097078c08c9a139 100644 (file)
@@ -22,6 +22,7 @@
 
 #include <netinet/tcp.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <haproxy/chunk.h>
 #include <haproxy/frontend.h>
@@ -32,7 +33,6 @@
 
 #include <haproxy/global.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/channel.h>
 #include <haproxy/fd.h>
index 504add9769f6642c5f736297518747403b2fd14b..b420df9383e5f136e459f2307cd4cab1a03dfc91 100644 (file)
@@ -78,6 +78,7 @@
 #include <systemd/sd-daemon.h>
 #endif
 
+#include <haproxy/acl.h>
 #include <haproxy/auth.h>
 #include <haproxy/api.h>
 #include <import/sha1.h>
 #include <types/cli.h>
 #include <types/filters.h>
 #include <haproxy/global.h>
-#include <types/acl.h>
 
-#include <proto/acl.h>
 #include <haproxy/activity.h>
 #include <haproxy/arg.h>
 #include <proto/backend.h>
index 0b6adfdb019f6b37b31595c196096a93d4349b7e..17a818e10b2b0068e5ca8e7fc1a019c0cdf92bcd 100644 (file)
@@ -16,6 +16,7 @@
 #include <string.h>
 #include <time.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/auth.h>
 #include <haproxy/api.h>
 #include <haproxy/chunk.h>
@@ -25,7 +26,6 @@
 #include <haproxy/tools.h>
 #include <haproxy/version.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 
 
index 356d57287abb4faa4cfa9d9a42608f40173e76c2..844eeafbf1edd74c8863057d5fbf6318ef74238a 100644 (file)
@@ -16,6 +16,7 @@
 #include <string.h>
 #include <time.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/action.h>
 #include <haproxy/api.h>
 #include <common/cfgparse.h>
@@ -34,7 +35,6 @@
 
 #include <haproxy/capture-t.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/log.h>
 #include <proto/http_ana.h>
index edfacc4ffaf6063fe595f6232012d419bcaf1446..8555293782b0a7ce156510f8ee3fe8599dacd47d 100644 (file)
@@ -10,6 +10,7 @@
  *
  */
 
+#include <haproxy/acl.h>
 #include <haproxy/action-t.h>
 #include <haproxy/api.h>
 #include <haproxy/base64.h>
@@ -25,7 +26,6 @@
 
 #include <haproxy/capture-t.h>
 
-#include <proto/acl.h>
 #include <proto/channel.h>
 #include <proto/filters.h>
 #include <proto/log.h>
index 955c04f789ba071bc092e14ae1162ea63d8b8381..6864e5ea3d5fbbdcf896333c0e21749646e88a2d 100644 (file)
@@ -16,6 +16,7 @@
 #include <string.h>
 #include <time.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/action.h>
 #include <haproxy/api.h>
 #include <common/cfgparse.h>
@@ -28,7 +29,6 @@
 
 #include <haproxy/capture-t.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/http_ana.h>
 #include <haproxy/sample.h>
index 6a13b1c5b062cb841134234f99245ccbb053f472..ab0a4a726d6b04e52d923d1a70b4fbea320f9d55 100644 (file)
@@ -18,6 +18,7 @@
 #include <unistd.h>
 #include <fcntl.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <common/cfgparse.h>
 #include <haproxy/connection.h>
@@ -31,7 +32,6 @@
 
 #include <haproxy/protocol-t.h>
 
-#include <proto/acl.h>
 #include <haproxy/fd.h>
 #include <haproxy/freq_ctr.h>
 #include <proto/log.h>
index 5664ec7dd537f073260f4509f3292696fa5648e0..c4f8b2cf9e26551b0ee15098dd89c076cca6e33b 100644 (file)
 #include <stdlib.h>
 #include <string.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <haproxy/connection.h>
 #include <haproxy/net_helper.h>
 #include <haproxy/payload.h>
 #include <haproxy/pattern.h>
 #include <haproxy/htx.h>
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/channel.h>
 #include <haproxy/sample.h>
index f576eaae2b0d347f89c79ef4c6fd6fd16e093844..cba840d55d0e103badca2e5bfc34fb2a6b1bcfa3 100644 (file)
@@ -35,7 +35,6 @@
 
 #include <types/stats.h>
 
-#include <proto/acl.h>
 #include <proto/applet.h>
 #include <proto/channel.h>
 #include <proto/cli.h>
index 509b0c57567d99446e86bb02262e8718ef97d46c..8314f3da318b14a2b2c49c3f87516da8593c6190 100644 (file)
@@ -20,6 +20,7 @@
 #include <string.h>
 #include <unistd.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/api.h>
 #include <haproxy/buf-t.h>
 #include <haproxy/obj_type.h>
@@ -30,7 +31,6 @@
 
 #include <types/ssl_sock.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/ssl_sock.h>
 
index 12e95758dd4a4979cc5db043dcfca2d5b6ab4d7c..5cad3d656237ab04c27db559cdcc4a0d4a7af2dc 100644 (file)
@@ -72,7 +72,6 @@
 #include <types/ssl_sock.h>
 #include <types/stats.h>
 
-#include <proto/acl.h>
 #include <haproxy/arg.h>
 #include <proto/channel.h>
 #include <proto/cli.h>
index 5a70ccadc76598a804ab72a5c981a4680b214119..ce41a2962c54fc639bb018d431f2aaeaec562094 100644 (file)
@@ -14,6 +14,7 @@
 #include <unistd.h>
 #include <fcntl.h>
 
+#include <haproxy/acl.h>
 #include <haproxy/action.h>
 #include <haproxy/api.h>
 #include <haproxy/capture.h>
@@ -41,7 +42,6 @@
 #include <types/filters.h>
 #include <types/stats.h>
 
-#include <proto/acl.h>
 #include <haproxy/activity.h>
 #include <haproxy/arg.h>
 #include <proto/backend.h>
index 9b4977d9da486c3f75eaade3d68464f2b5df4721..85073691dfcb045cce74fe943d8a01de5c4ccc26 100644 (file)
@@ -9,6 +9,7 @@
  * 2 of the License, or (at your option) any later version.
  *
  */
+#include <haproxy/acl.h>
 #include <haproxy/action.h>
 #include <haproxy/api.h>
 #include <haproxy/capture-t.h>
@@ -24,7 +25,6 @@
 
 #include <haproxy/arg-t.h>
 
-#include <proto/acl.h>
 #include <proto/channel.h>
 #include <proto/log.h>
 #include <proto/proxy.h>