modules.h 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  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_synchronous_process;
  44. extern const struct NCDModuleGroup ncdmodule_process_manager;
  45. extern const struct NCDModuleGroup ncdmodule_net_backend_waitdevice;
  46. extern const struct NCDModuleGroup ncdmodule_net_backend_waitlink;
  47. extern const struct NCDModuleGroup ncdmodule_net_backend_badvpn;
  48. extern const struct NCDModuleGroup ncdmodule_net_backend_wpa_supplicant;
  49. #ifdef BADVPN_USE_LINUX_RFKILL
  50. extern const struct NCDModuleGroup ncdmodule_net_backend_rfkill;
  51. #endif
  52. extern const struct NCDModuleGroup ncdmodule_net_up;
  53. extern const struct NCDModuleGroup ncdmodule_net_dns;
  54. extern const struct NCDModuleGroup ncdmodule_net_iptables;
  55. extern const struct NCDModuleGroup ncdmodule_net_ipv4_addr;
  56. extern const struct NCDModuleGroup ncdmodule_net_ipv4_route;
  57. extern const struct NCDModuleGroup ncdmodule_net_ipv4_dhcp;
  58. extern const struct NCDModuleGroup ncdmodule_net_watch_interfaces;
  59. extern const struct NCDModuleGroup ncdmodule_sys_watch_input;
  60. #ifdef BADVPN_USE_LINUX_INPUT
  61. extern const struct NCDModuleGroup ncdmodule_sys_evdev;
  62. #endif
  63. #ifdef BADVPN_USE_INOTIFY
  64. extern const struct NCDModuleGroup ncdmodule_sys_watch_directory;
  65. #endif
  66. static const struct NCDModuleGroup *ncd_modules[] = {
  67. &ncdmodule_var,
  68. &ncdmodule_list,
  69. &ncdmodule_depend,
  70. &ncdmodule_multidepend,
  71. &ncdmodule_concat,
  72. &ncdmodule_concatv,
  73. &ncdmodule_concatlist,
  74. &ncdmodule_if,
  75. &ncdmodule_strcmp,
  76. &ncdmodule_regex_match,
  77. &ncdmodule_logical,
  78. &ncdmodule_sleep,
  79. &ncdmodule_print,
  80. &ncdmodule_blocker,
  81. &ncdmodule_ip_in_network,
  82. &ncdmodule_run,
  83. &ncdmodule_runonce,
  84. &ncdmodule_synchronous_process,
  85. &ncdmodule_process_manager,
  86. &ncdmodule_net_backend_waitdevice,
  87. &ncdmodule_net_backend_waitlink,
  88. &ncdmodule_net_backend_badvpn,
  89. &ncdmodule_net_backend_wpa_supplicant,
  90. #ifdef BADVPN_USE_LINUX_RFKILL
  91. &ncdmodule_net_backend_rfkill,
  92. #endif
  93. &ncdmodule_net_up,
  94. &ncdmodule_net_dns,
  95. &ncdmodule_net_iptables,
  96. &ncdmodule_net_ipv4_addr,
  97. &ncdmodule_net_ipv4_route,
  98. &ncdmodule_net_ipv4_dhcp,
  99. &ncdmodule_net_watch_interfaces,
  100. &ncdmodule_sys_watch_input,
  101. #ifdef BADVPN_USE_LINUX_INPUT
  102. &ncdmodule_sys_evdev,
  103. #endif
  104. #ifdef BADVPN_USE_INOTIFY
  105. &ncdmodule_sys_watch_directory,
  106. #endif
  107. NULL
  108. };
  109. #endif