File: UseMakeDissectorReg.cmake

package info (click to toggle)
libbtbb 2015.09.R2-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,396 kB
  • ctags: 2,047
  • sloc: ansic: 9,645; python: 922; sh: 170; makefile: 143; ruby: 21
file content (33 lines) | stat: -rw-r--r-- 1,295 bytes parent folder | download | duplicates (23)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#
# $Id: UseMakeDissectorReg.cmake 33616 2010-07-22 12:18:36Z stig $
#
MACRO(REGISTER_DISSECTOR_FILES _outputfile _registertype )
	# FIXME: Only the Python stuff has been implemented
	#        Make this into a MACRO, to avoid duplication with plugins/.../
	#register.c: $(plugin_src) $(ALL_DISSECTORS_SRC) $(top_srcdir)/tools/make-dissector-reg \
	#    $(top_srcdir)/tools/make-dissector-reg.py
	#        @if test -n "$(PYTHON)"; then \
	#                echo Making register.c with python ; \
	#                $(PYTHON) $(top_srcdir)/tools/make-dissector-reg.py $(srcdir) \
	#                    dissectors $(ALL_DISSECTORS_SRC) ; \
	#        else \
	#                echo Making register.c with shell script ; \
	#                $(top_srcdir)/tools/make-dissector-reg $(srcdir) \
	#                   dissectors $(plugin_src) $(ALL_DISSECTORS_SRC) ; \
	#        fi
	set( _sources ${ARGN} )
	ADD_CUSTOM_COMMAND(
	    OUTPUT 
	      ${_outputfile}
	    COMMAND ${PYTHON_EXECUTABLE}
	      ${CMAKE_SOURCE_DIR}/tools/make-dissector-reg.py
	      ${CMAKE_CURRENT_SOURCE_DIR}
	      ${_registertype}
	      ${_sources}
	    DEPENDS
	      ${_sources}
	      ${CMAKE_SOURCE_DIR}/tools/make-dissector-reg
	      ${CMAKE_SOURCE_DIR}/tools/make-dissector-reg.py
	)
ENDMACRO(REGISTER_DISSECTOR_FILES)