PageRenderTime 56ms CodeModel.GetById 20ms RepoModel.GetById 0ms app.codeStats 0ms

/openvas-client-3.0.3/openvas/Makefile

#
Makefile | 303 lines | 232 code | 69 blank | 2 comment | 1 complexity | 4cc2f380fd625dcd6260f139d4d4749c MD5 | raw file
Possible License(s): GPL-2.0
  1. include ../openvas.tmpl
  2. GTKLIBS= $(GTKCONFIG_LIBS)
  3. INCLUDE = ${OTP_FLAGS} ${OMP_FLAGS} ${include} $(GTKCONFIG_CFLAGS) $(GLIB_CFLAGS) \
  4. -I../src/gui -I../src/util -I../include $(LIBOPENVAS_CFLAGS)
  5. LIBS = $(X_LIBS) $(X_CFLAGS) $(GTKLIBS) $(GLIB_LIBS) $(GDC_LIB) \
  6. $(RUN_LIBS) $(C_R_LIB) -lm \
  7. $(DL_LIB) -lz $(SOCKET_LIB) $(LIBOPENVAS_LIBS)
  8. OPENVAS_INCLUDE=`sh ./cflags`
  9. CFLAGS+=-Wall
  10. # The name of the executable:
  11. OPENVASCLIENT=OpenVAS-Client$(EXEEXT)
  12. # Add some specific Windows compile options for Cygwin
  13. SYSTEM:=$(shell uname -o)
  14. ifeq ($(SYSTEM), Cygwin)
  15. CFLAGS+=-mms-bitfields
  16. LDFLAGS+=-mwindows
  17. OPENVASCLIENT=OpenVAS-Client.exe
  18. endif
  19. OBJS = auth.o \
  20. openvas_plugin.o \
  21. comm.o \
  22. sighand.o \
  23. cli.o \
  24. parser.o \
  25. plugin_infos.o \
  26. plugin_cache.o \
  27. context.o \
  28. preferences.o \
  29. attack.o \
  30. report.o \
  31. report_save.o \
  32. report_utils.o \
  33. nbe_output.o \
  34. html_output.o \
  35. latex_output.o \
  36. text_output.o \
  37. xml_output_ng.o \
  38. html_graph_output.o \
  39. monitor_dialog.o \
  40. error_dlg.o \
  41. backend.o \
  42. data_mining.o \
  43. prefs_dialog.o \
  44. prefs_scope_tree.o \
  45. prefs_dialog_scan_opt.o \
  46. prefs_dialog_user.o \
  47. prefs_dialog_auth.o \
  48. prefs_dialog_plugins_prefs.o \
  49. prefs_plugins.o \
  50. prefs_plugins_tree.o \
  51. prefs_target.o \
  52. prefs_kb.o \
  53. listnotebook.o \
  54. read_target_file.o \
  55. regex.o \
  56. filter.o \
  57. openvas_ssh_key_create.o \
  58. sslui.o \
  59. subset.o \
  60. openvas-client.o
  61. GTK_OBJS = prefs_comment.o prefs_context.o prefs_options.o prefs_report.o \
  62. prefs_dialog_prefs.o prefs_scan_assistant.o pdf_output.o readonly.o
  63. GUI_OBJS = ../src/gui/about_dlg.o ../src/gui/severityfiltermngr_dlg.o \
  64. ../src/gui/slad_install.o ../src/gui/ssh_keys_dialog.o \
  65. ../src/gui/treeview_support.o \
  66. ../src/gui/ssh_key_info_form.o ../src/gui/nvt_pref_sshlogin.o \
  67. ../src/gui/severity_override_form.o
  68. UTIL_OBJS = ../src/util/parseutils.o \
  69. ../src/util/file_utils.o \
  70. ../src/util/openvas_lsc_user_makensis.o\
  71. ../src/util/openvas_lsc_user_deb.o\
  72. ../src/util/openvas_lsc_user_rpm.o \
  73. ../src/util/openvas_lsc_target_prep.o\
  74. ../src/util/openvas-socket.o
  75. all : cflags ${make_bindir}/$(OPENVASCLIENT)
  76. ${make_bindir}/$(OPENVASCLIENT) : cflags $(OPENVASCLIENT)
  77. test -d ${make_bindir} || mkdir ${make_bindir}
  78. cp $(OPENVASCLIENT) ${make_bindir}
  79. cflags :
  80. @echo "$(OPENVAS_CFLAGS) $(OPENVAS_DEFS) -DPACKAGE=\"OpenVAS-Client\" $(INCLUDE)" | sed 's/\"/\\\"/g' > cflags.tmp
  81. @echo "echo \"`cat cflags.tmp`\"" > cflags
  82. @rm cflags.tmp
  83. @chmod +x cflags
  84. $(OPENVASCLIENT) : cflags util $(OBJS) $(if $(USE_GTK),$(GTK_OBJS) gui)
  85. $(CC) $(LDFLAGS) $(OBJS) $(if $(USE_GTK),$(GTK_OBJS) $(GUI_OBJS)) $(UTIL_OBJS) -o $(OPENVASCLIENT) $(LIBS)
  86. context.o : cflags context.c context.h ../src/gui/error_dlg.h comm.h plugin_cache.h
  87. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c context.c
  88. preferences.o : cflags preferences.c preferences.h ../src/gui/error_dlg.h globals.h
  89. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c preferences.c
  90. prefs_dialog.o : cflags prefs_dialog/prefs_dialog.c prefs_dialog/prefs_dialog.h\
  91. prefs_dialog/prefs_help.h globals.h context.h prefs_dialog/prefs_context.h\
  92. ../src/gui/error_dlg.h prefs_dialog/prefs_comment.h \
  93. xpm/connect_16.xpm xpm/connected.xpm xpm/connect_24.xpm xpm/disconnect_16.xpm\
  94. xpm/access_rules.xpm xpm/credentials.xpm xpm/general_prefs.xpm \
  95. xpm/knowledgebase.xpm xpm/plugins.xpm xpm/properties.xpm \
  96. xpm/target_selection.xpm
  97. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog.c
  98. prefs_scope_tree.o : cflags prefs_dialog/prefs_scope_tree.c ../src/gui/error_dlg.h \
  99. globals.h preferences.h context.h prefs_dialog/prefs_context.h \
  100. prefs_dialog/prefs_dialog_auth.h xpm/connected.xpm
  101. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_scope_tree.c
  102. prefs_dialog_scan_opt.o : cflags prefs_dialog/prefs_dialog_scan_opt.c\
  103. prefs_dialog/prefs_dialog_scan_opt.h \
  104. ../src/gui/error_dlg.h prefs_dialog/readonly.h \
  105. globals.h
  106. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog_scan_opt.c
  107. prefs_target.o : cflags prefs_dialog/prefs_target.c\
  108. prefs_dialog/prefs_target.h read_target_file.h
  109. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_target.c
  110. prefs_dialog_user.o : cflags prefs_dialog/prefs_dialog_user.c globals.h \
  111. prefs_dialog/readonly.h
  112. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog_user.c
  113. prefs_dialog_auth.o : cflags prefs_dialog/prefs_dialog_auth.c \
  114. prefs_dialog/prefs_help.h globals.h context.h\
  115. ../src/gui/error_dlg.h
  116. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog_auth.c
  117. openvas_plugin.o : cflags openvas_plugin.c
  118. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c openvas_plugin.c
  119. prefs_plugins.o : cflags prefs_dialog/prefs_plugins.c ../src/gui/error_dlg.h\
  120. prefs_dialog/prefs_help.h prefs_dialog/prefs_plugins_tree.h\
  121. prefs_dialog/readonly.h globals.h
  122. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_plugins.c
  123. prefs_plugins_tree.o : cflags prefs_dialog/prefs_plugins_tree.c \
  124. prefs_dialog/prefs_plugins_tree.h filter.h \
  125. ../src/gui/error_dlg.h prefs_dialog/prefs_help.h globals.h \
  126. plugin_infos.h xpm/warning_small.xpm
  127. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_plugins_tree.c
  128. openvas_ssh_key_create.o : cflags ../src/util/openvas_ssh_key_create.c \
  129. ../src/util/openvas_ssh_key_create.h
  130. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c ../src/util/openvas_ssh_key_create.c
  131. error_dlg.o : cflags ../src/gui/error_dlg.c ../src/gui/error_dlg.h globals.h
  132. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c ../src/gui/error_dlg.c
  133. ssh_key_info_form.o : cflags ../src/gui/ssh_key_info_form.c ../src/gui/ssh_key_info_form.h globals.h
  134. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c ../src/gui/ssh_key_info_form.c
  135. prefs_dialog_plugins_prefs.o : cflags prefs_dialog/prefs_dialog_plugins_prefs.c context.h \
  136. prefs_dialog/listnotebook.h prefs_dialog/readonly.h
  137. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog_plugins_prefs.c
  138. prefs_kb.o : cflags prefs_dialog/prefs_kb.c prefs_dialog/prefs_help.h \
  139. context.h
  140. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_kb.c
  141. prefs_context.o : cflags prefs_dialog/prefs_context.c globals.h context.h \
  142. preferences.h ../src/gui/error_dlg.h prefs_dialog/prefs_comment.h
  143. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_context.c
  144. prefs_comment.o : cflags prefs_dialog/prefs_comment.c \
  145. prefs_dialog/prefs_comment.h globals.h
  146. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_comment.c
  147. prefs_options.o : cflags prefs_dialog/prefs_options.c \
  148. prefs_dialog/prefs_options.h prefs_dialog/listnotebook.h \
  149. globals.h
  150. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_options.c
  151. prefs_report.o : cflags prefs_dialog/prefs_report.c \
  152. prefs_dialog/prefs_report.h globals.h xpm/computer.xpm xpm/network.xpm \
  153. xpm/warning_small.xpm xpm/info_small.xpm xpm/error_small.xpm xpm/nothing.xpm
  154. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_report.c
  155. prefs_dialog_prefs.o : cflags prefs_dialog/prefs_dialog_prefs.c \
  156. prefs_dialog/prefs_dialog_prefs.h globals.h
  157. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_dialog_prefs.c
  158. prefs_scan_assistant.o : cflags prefs_dialog/prefs_scan_assistant.c \
  159. ../src/gui/error_dlg.h context.h prefs_dialog/prefs_context.h \
  160. prefs_dialog/prefs_scope_tree.h prefs_dialog/prefs_dialog.h \
  161. prefs_dialog/prefs_dialog_auth.h
  162. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/prefs_scan_assistant.c
  163. listnotebook.o : cflags prefs_dialog/listnotebook.c \
  164. prefs_dialog/listnotebook.h prefs_dialog/readonly.h
  165. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/listnotebook.c
  166. readonly.o : cflags prefs_dialog/readonly.c prefs_dialog/readonly.h
  167. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c prefs_dialog/readonly.c
  168. plugin_infos.o : cflags plugin_infos.c plugin_infos.h globals.h context.h openvas_plugin.h
  169. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c plugin_infos.c
  170. plugin_cache.o : cflags plugin_cache.c plugin_cache.h openvas_plugin.h \
  171. ../src/gui/error_dlg.h context.h preferences.h globals.h
  172. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c plugin_cache.c
  173. main_window.o : cflags main_window.c main_window.h
  174. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c main_window.c
  175. nbe_output.o : cflags nbe_output.c nbe_output.h ../src/gui/error_dlg.h
  176. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c nbe_output.c
  177. html_output.o : cflags html_output.c html_output.h ../src/gui/error_dlg.h globals.h
  178. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c html_output.c
  179. text_output.o : cflags text_output.c text_output.h ../src/gui/error_dlg.h globals.h
  180. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c text_output.c
  181. xml_output_ng.o : cflags xml_output_ng.c ../src/gui/error_dlg.h globals.h context.h openvas_plugin.h
  182. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c xml_output_ng.c
  183. latex_output.o : cflags latex_output.c latex_output.h globals.h openvas_plugin.h
  184. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c latex_output.c
  185. html_graph_output.o : cflags html_graph_output.c html_graph_output.h ../src/gui/error_dlg.h globals.h
  186. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c html_graph_output.c
  187. pdf_output.o : cflags pdf_output.c pdf_output.h globals.h openvas_plugin.h
  188. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c pdf_output.c
  189. monitor_dialog.o : cflags monitor_dialog.c monitor_dialog.h globals.h \
  190. context.h report.h xpm/computer.xpm \
  191. prefs_dialog/prefs_context.h prefs_dialog/prefs_scope_tree.h
  192. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c monitor_dialog.c
  193. backend.o : cflags backend.c backend.h ../src/gui/error_dlg.h
  194. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c backend.c
  195. data_mining.o : cflags data_mining.c data_mining.h subset.c subset.h
  196. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c data_mining.c
  197. report_utils.o : cflags report_utils.h report_utils.c
  198. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c report_utils.c
  199. openvas-client.o : cflags openvas-client.c globals.h context.h preferences.h openvas-client.h
  200. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -DOPENVASCLIENT_CONFDIR=\"$(OPENVASCLIENT_CONFDIR)\" -c openvas-client.c
  201. sighand.o : cflags sighand.c sighand.h ../src/gui/error_dlg.h context.h backend.h auth.h
  202. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c sighand.c
  203. auth.o : cflags auth.c globals.h
  204. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c auth.c
  205. comm.o : cflags comm.c ../src/gui/error_dlg.h globals.h context.h plugin_cache.h openvas_plugin.h
  206. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c comm.c
  207. report.o : cflags report.c ../src/gui/error_dlg.h globals.h context.h \
  208. plugin_cache.h openvas_plugin.h \
  209. prefs_dialog/prefs_scope_tree.h prefs_dialog/prefs_context.h
  210. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c report.c
  211. report_save.o : cflags report_save.c preferences.h context.h ../src/gui/error_dlg.h
  212. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c report_save.c
  213. parser.o : cflags parser.c ../src/gui/error_dlg.h globals.h
  214. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c parser.c
  215. attack.o : cflags attack.c globals.h context.h
  216. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c attack.c
  217. cli.o : cflags cli.c cli.h globals.h preferences.h openvas_plugin.h
  218. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c cli.c
  219. read_target_file.o : cflags read_target_file.c ../src/gui/error_dlg.h globals.h
  220. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c read_target_file.c
  221. subset.o : cflags subset.c subset.h
  222. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c subset.c
  223. util:
  224. $(MAKE) -C ../src/util
  225. gui: util
  226. $(MAKE) -C ../src/gui
  227. regex.o : cflags regex.c
  228. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c regex.c
  229. filter.o : cflags filter.c ../src/gui/error_dlg.h openvas_plugin.h
  230. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c filter.c
  231. sslui.o : cflags sslui.c globals.h xpm/lock.xpm
  232. $(CC) $(CFLAGS) $(OPENVAS_INCLUDE) -c sslui.c
  233. clean :
  234. rm -f *.o $(OPENVASCLIENT) *~ cflags prefs_dialog/*.o