modules.h 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. /**
  2. * @file modules.h
  3. * @author Ambroz Bizjak <ambrop7@gmail.com>
  4. *
  5. * @section LICENSE
  6. *
  7. * This file is part of BadVPN.
  8. *
  9. * BadVPN is free software: you can redistribute it and/or modify
  10. * it under the terms of the GNU General Public License version 2
  11. * as published by the Free Software Foundation.
  12. *
  13. * BadVPN is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License along
  19. * with this program; if not, write to the Free Software Foundation, Inc.,
  20. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  21. */
  22. #ifndef BADVPN_NCD_MODULES_MODULES_H
  23. #define BADVPN_NCD_MODULES_MODULES_H
  24. #include <stddef.h>
  25. #include <ncd/NCDModule.h>
  26. extern const struct NCDModuleGroup ncdmodule_var;
  27. extern const struct NCDModuleGroup ncdmodule_list;
  28. extern const struct NCDModuleGroup ncdmodule_depend;
  29. extern const struct NCDModuleGroup ncdmodule_multidepend;
  30. extern const struct NCDModuleGroup ncdmodule_concat;
  31. extern const struct NCDModuleGroup ncdmodule_concatv;
  32. extern const struct NCDModuleGroup ncdmodule_concatlist;
  33. extern const struct NCDModuleGroup ncdmodule_if;
  34. extern const struct NCDModuleGroup ncdmodule_strcmp;
  35. extern const struct NCDModuleGroup ncdmodule_regex_match;
  36. extern const struct NCDModuleGroup ncdmodule_logical;
  37. extern const struct NCDModuleGroup ncdmodule_sleep;
  38. extern const struct NCDModuleGroup ncdmodule_print;
  39. extern const struct NCDModuleGroup ncdmodule_blocker;
  40. extern const struct NCDModuleGroup ncdmodule_ip_in_network;
  41. extern const struct NCDModuleGroup ncdmodule_run;
  42. extern const struct NCDModuleGroup ncdmodule_runonce;
  43. extern const struct NCDModuleGroup ncdmodule_spawn;
  44. extern const struct NCDModuleGroup ncdmodule_call;
  45. extern const struct NCDModuleGroup ncdmodule_ref;
  46. extern const struct NCDModuleGroup ncdmodule_index;
  47. extern const struct NCDModuleGroup ncdmodule_alias;
  48. extern const struct NCDModuleGroup ncdmodule_process_manager;
  49. extern const struct NCDModuleGroup ncdmodule_net_backend_waitdevice;
  50. extern const struct NCDModuleGroup ncdmodule_net_backend_waitlink;
  51. extern const struct NCDModuleGroup ncdmodule_net_backend_badvpn;
  52. extern const struct NCDModuleGroup ncdmodule_net_backend_wpa_supplicant;
  53. #ifdef BADVPN_USE_LINUX_RFKILL
  54. extern const struct NCDModuleGroup ncdmodule_net_backend_rfkill;
  55. #endif
  56. extern const struct NCDModuleGroup ncdmodule_net_up;
  57. extern const struct NCDModuleGroup ncdmodule_net_dns;
  58. extern const struct NCDModuleGroup ncdmodule_net_iptables;
  59. extern const struct NCDModuleGroup ncdmodule_net_ipv4_addr;
  60. extern const struct NCDModuleGroup ncdmodule_net_ipv4_route;
  61. extern const struct NCDModuleGroup ncdmodule_net_ipv4_dhcp;
  62. extern const struct NCDModuleGroup ncdmodule_net_watch_interfaces;
  63. extern const struct NCDModuleGroup ncdmodule_sys_watch_input;
  64. #ifdef BADVPN_USE_LINUX_INPUT
  65. extern const struct NCDModuleGroup ncdmodule_sys_evdev;
  66. #endif
  67. #ifdef BADVPN_USE_INOTIFY
  68. extern const struct NCDModuleGroup ncdmodule_sys_watch_directory;
  69. #endif
  70. static const struct NCDModuleGroup *ncd_modules[] = {
  71. &ncdmodule_var,
  72. &ncdmodule_list,
  73. &ncdmodule_depend,
  74. &ncdmodule_multidepend,
  75. &ncdmodule_concat,
  76. &ncdmodule_concatv,
  77. &ncdmodule_concatlist,
  78. &ncdmodule_if,
  79. &ncdmodule_strcmp,
  80. &ncdmodule_regex_match,
  81. &ncdmodule_logical,
  82. &ncdmodule_sleep,
  83. &ncdmodule_print,
  84. &ncdmodule_blocker,
  85. &ncdmodule_ip_in_network,
  86. &ncdmodule_run,
  87. &ncdmodule_runonce,
  88. &ncdmodule_spawn,
  89. &ncdmodule_call,
  90. &ncdmodule_ref,
  91. &ncdmodule_index,
  92. &ncdmodule_alias,
  93. &ncdmodule_process_manager,
  94. &ncdmodule_net_backend_waitdevice,
  95. &ncdmodule_net_backend_waitlink,
  96. &ncdmodule_net_backend_badvpn,
  97. &ncdmodule_net_backend_wpa_supplicant,
  98. #ifdef BADVPN_USE_LINUX_RFKILL
  99. &ncdmodule_net_backend_rfkill,
  100. #endif
  101. &ncdmodule_net_up,
  102. &ncdmodule_net_dns,
  103. &ncdmodule_net_iptables,
  104. &ncdmodule_net_ipv4_addr,
  105. &ncdmodule_net_ipv4_route,
  106. &ncdmodule_net_ipv4_dhcp,
  107. &ncdmodule_net_watch_interfaces,
  108. &ncdmodule_sys_watch_input,
  109. #ifdef BADVPN_USE_LINUX_INPUT
  110. &ncdmodule_sys_evdev,
  111. #endif
  112. #ifdef BADVPN_USE_INOTIFY
  113. &ncdmodule_sys_watch_directory,
  114. #endif
  115. NULL
  116. };
  117. #endif