cmake will now honor -Werror if configured (default: on)

svn path=/trunk/; revision=30852
This commit is contained in:
Jörg Mayer 2009-11-07 10:07:00 +00:00
parent f6dfb9f323
commit 9ee31d1d0e
25 changed files with 425 additions and 103 deletions

View File

@ -69,7 +69,7 @@ option(AUTOGEN_dcerpc "Autogenerate dcerpc dissectors" OFF)
option(AUTOGEN_pidl "Autogenerate pidl dissectors" OFF)
option(DISABLE_WERROR "Do not treat Warnings as errors" OFF)
option(ENABLE_EXTRA_GCC_CHECKS "Do additional -W checks in GCC (disables -Werror)" ON)
option(ENABLE_EXTRA_GCC_CHECKS "Do additional -W checks in GCC (disables -Werror)" OFF)
option(ENABLE_AIRPCAP "Enable Airpcap support" ON)
# todo
option(ENABLE_STATIC "Build a static version of Wireshark" OFF)
@ -93,7 +93,6 @@ option(ENABLE_KERBEROS "Build with Kerberos support" ON)
set(WIRESHARK_C_FLAGS
-O2
-Werror
-Wall
-W
-Wextra
@ -161,8 +160,8 @@ foreach(THIS_FLAG ${WIRESHARK_C_FLAGS})
math(EXPR C "${C} + 1")
endforeach()
if(DISABLE_WERROR OR ENABLE_EXTRA_GCC_CHECKS)
remove_definitions( -Werror )
if(NOT DISABLE_WERROR AND NOT ENABLE_EXTRA_GCC_CHECKS)
check_c_compiler_flag(-Werror WERROR)
endif()
if(CMAKE_COMPILER_IS_GNUCC)
@ -650,6 +649,9 @@ if(BUILD_text2pcap)
set(text2pcap_FILES
text2pcap.c
)
set(text2pcap_CLEAN_FILES
${text2pcap_FILES}
)
add_lex_files(text2pcap_FILES
text2pcap-scanner.l
)
@ -758,6 +760,27 @@ add_custom_target(
# todo: Add manpages and onlinedocs and generate them
)
set(CLEAN_FILES
${wireshark_FILES}
${tshark_FILES}
${rawshark_FILES}
${dftest_FILES}
${randpkt_FILES}
${text2pcap_CLEAN_FILES}
${mergecap_FILES}
${capinfos_FILES}
${editcap_FILES}
${dumpcap_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
install(
FILES
${INSTALL_FILES}

View File

@ -80,8 +80,7 @@ What needs to be done?
- Fix places in the cmake files marked as todo.
- Add back (working) install target.
Currently, directories are created with user umask
- Add back -Werror
- Add back compiler flags test
- Add back linker flags test
- Build source package (using CPack).
- Build rpm package (using CPack).
- Build dpkg package (using CPack).

View File

@ -84,6 +84,10 @@ set(DFILTER_FILES
dfilter/syntax-tree.c
)
set(DFILTER_CLEAN_FILES
${DFILTER_FILES}
)
add_lex_files(DFILTER_FILES
dfilter/scanner.l
)
@ -1075,16 +1079,6 @@ set(DISSECTOR_FILES
${DIRTY_ASN1_DISSECTOR_SRC}
)
set_source_files_properties(
${DISSECTOR_SRC}
${PIDL_DISSECTOR_SRC}
${PIDL_DISSECTOR_AUTOGEN_SRC}
${ASN1_DISSECTOR_SRC}
PROPERTIES
# FIXME: -Werror and -pedantic exclude each other: test for -pedantic
# COMPILE_FLAGS -Werror
)
register_dissector_files(register.c
dissectors
${DISSECTOR_FILES}
@ -1190,6 +1184,10 @@ set(LIBWIRESHARK_FILES
xdlc.c
)
set(LIBWIRESHARK_CLEAN_FILES
${LIBWIRESHARK_FILES}
)
add_lex_files(LIBWIRESHARK_FILES
diam_dict.l
dtd_parse.l
@ -1225,6 +1223,33 @@ set(epan_LIBS
${M_LIBRARIES}
)
set(CLEAN_FILES
# Needed to trigger build of the include files for x11
#x11-declarations.h
#x11-register-info.h
${LIBWIRESHARK_CLEAN_FILES}
${CRC_FILES}
${CRYPT_FILES}
${DFILTER_CLEAN_FILES}
${FTYPE_FILES}
# ${DISSECTOR_FILES} contains dirty files
${DISSECTOR_SRC}
${PIDL_DISSECTOR_SRC}
${PIDL_DISSECTOR_AUTOGEN_SRC}
${ASN1_DISSECTOR_SRC}
# ${DISSECTOR_FILES } end
${DISSECTOR_SUPPORT_SRC}
${LIBWIRESHARK_ASM_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
add_library(epan SHARED
# Needed to trigger build of the include files for x11
#x11-declarations.h
@ -1238,6 +1263,7 @@ add_library(epan SHARED
${DISSECTOR_SUPPORT_SRC}
${LIBWIRESHARK_ASM_FILES}
)
# In case we want the libwireshark name back
# SET_TARGET_PROPERTIES(epan PROPERTIES OUTPUT_NAME "wireshark")

View File

@ -1,26 +1,26 @@
# CMakeLists.txt
#
# $Id$
#
# Wireshark - Network traffic analyzer
# By Gerald Combs <gerald@wireshark.org>
# Copyright 1998 Gerald Combs
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# CMakeLists.txt
#
# $Id: $
#
# Wireshark - Network traffic analyzer
# By Gerald Combs <gerald@wireshark.org>
# Copyright 1998 Gerald Combs
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
set(PIDL_DISSECTOR_AUTOGEN_NAMES
budb
butc
@ -28,4 +28,20 @@ set(PIDL_DISSECTOR_AUTOGEN_NAMES
PARENT_SCOPE
)
add_executable(idl2wrs idl2wrs.c)
set(IDL2WRS_FILES
idl2wrs.c
)
set(CLEAN_FILES
${IDL2WRS_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
add_executable(idl2wrs ${IDL2WRS_FILES})

View File

@ -46,6 +46,18 @@ set(WSLUA_FILES
init_wslua.c
)
set(CLEAN_FILES
${WSLUA_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
# Used with untypical CWD
set(WSLUA_TAPS_USED
${CMAKE_SOURCE_DIR}/epan/dissectors/packet-http.h

View File

@ -31,6 +31,18 @@ set(WSPYTHON_FILES
wspy_proto.c
)
set(CLEAN_FILES
${WSPYTHON_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
set(wspython_LIBS
${PYTHON_LIBRARIES}
)
@ -54,6 +66,6 @@ install(DIRECTORY
wspy_dissectors
DESTINATION
${CMAKE_INSTALL_DATADIR}/${CPACK_PACKAGE_NAME}/python/${CPACK_PACKAGE_VERSION}
PATTERN ".svn" EXCLUDE
PATTERN ".svn" EXCLUDE
)

View File

@ -200,6 +200,19 @@ set(WIRESHARK_TAP_SRC
# todo
# about_dlg.c main_welcome.c: ../image/wssplash.xpm ../image/wssplash-dev.xpm
set(CLEAN_FILES
${WIRESHARK_GTK_SRC}
${WIRESHARK_TAP_SRC}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
register_tap_files(wireshark-tap-register.c
${WIRESHARK_TAP_SRC}
)

View File

@ -35,6 +35,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -53,8 +65,8 @@ add_library(asn1 MODULE
target_link_libraries(asn1 epan)
install(TARGETS asn1
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -64,6 +64,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -82,8 +94,8 @@ add_library(docsis MODULE
target_link_libraries(docsis epan)
install(TARGETS docsis
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -36,6 +36,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -54,8 +66,8 @@ add_library(ethercat MODULE
target_link_libraries(ethercat epan)
install(TARGETS ethercat
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -36,6 +36,21 @@ set(PARLAY_SRC
packet-parlay.c
)
set(CLEAN_FILES
${COSNAMING_SRC}
${COSEVENTCOMM_SRC}
# Not clean ${TANGO_SRC}
# Not clean ${PARLAY_SRC}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
# todo
@ -49,9 +64,9 @@ add_library(cosnaming MODULE
target_link_libraries(cosnaming epan)
install(TARGETS cosnaming
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)
add_library(coseventcomm MODULE
@ -61,9 +76,9 @@ add_library(coseventcomm MODULE
target_link_libraries(coseventcomm epan)
install(TARGETS coseventcomm
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)
add_library(tango MODULE
@ -73,9 +88,9 @@ add_library(tango MODULE
target_link_libraries(tango epan)
install(TARGETS tango
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)
add_library(parlay MODULE
@ -85,8 +100,8 @@ add_library(parlay MODULE
target_link_libraries(parlay epan)
install(TARGETS parlay
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -30,6 +30,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -48,8 +60,8 @@ add_library(gryphon MODULE
target_link_libraries(gryphon epan)
install(TARGETS gryphon
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -32,6 +32,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -50,8 +62,8 @@ add_library(irda MODULE
target_link_libraries(irda epan)
install(TARGETS irda
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -26,7 +26,7 @@ set(DISSECTOR_SRC
)
set(DISSECTOR_SUPPORT_SRC
wimax_tlv.c
wimax_tlv.c
)
set(PLUGIN_FILES
@ -35,6 +35,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -53,8 +65,8 @@ add_library(m2m MODULE
target_link_libraries(m2m epan)
install(TARGETS m2m
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -33,12 +33,12 @@ set(DISSECTOR_SUPPORT_SRC
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
#mate_grammar.c : mate_grammar.lemon mate.h mate_util.h $(LEMON)/lemon$(EXEEXT)
# $(LEMON)/lemon$(EXEEXT) t=$(srcdir)/$(LEMON)/lempar.c $(srcdir)/mate_grammar.lemon || \
# (rm -f grammar.c grammar.h ; false)
set(DISSECTOR_SUPPORT_CLEAN_SRC
${DISSECTOR_SUPPORT_SRC}
)
add_lemon_files(DISSECTOR_SUPPORT_SRC
mate_grammar.lemon
mate_grammar.lemon
)
add_lex_files(DISSECTOR_SUPPORT_SRC
@ -51,6 +51,20 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
plugin.c
${DISSECTOR_SRC}
${DISSECTOR_SUPPORT_CLEAN_SRC}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
register_dissector_files(plugin.c
plugin
${DISSECTOR_SRC}
@ -67,8 +81,8 @@ add_library(mate MODULE
target_link_libraries(mate epan)
install(TARGETS mate
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -43,6 +43,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -61,8 +73,8 @@ add_library(opcua MODULE
target_link_libraries(opcua epan)
install(TARGETS opcua
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -42,6 +42,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -60,8 +72,8 @@ add_library(profinet MODULE
target_link_libraries(profinet epan)
install(TARGETS profinet
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -41,6 +41,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -59,8 +71,8 @@ add_library(sercosiii MODULE
target_link_libraries(sercosiii epan)
install(TARGETS sercosiii
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -26,6 +26,18 @@ set(TAP_SRC
pinfo_stats_tree.c
)
set(CLEAN_FILES
${TAP_SRC}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
# todo
# Do I need any of this or is this handled by type MODULE?
# asn1_la_LDFLAGS = -module -avoid-version
@ -37,8 +49,8 @@ add_library(stats_tree MODULE
target_link_libraries(stats_tree epan)
install(TARGETS stats_tree
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -26,6 +26,18 @@ set(PLUGIN_FILES
packet-http.c
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_BINARY_DIR})
set(_tpg ${CMAKE_SOURCE_DIR}/tools/tpg)
@ -69,8 +81,8 @@ add_library(tpg MODULE
target_link_libraries(tpg epan)
install(TARGETS tpg
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -30,6 +30,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -48,8 +60,8 @@ add_library(unistim MODULE
target_link_libraries(unistim epan)
install(TARGETS unistim
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -75,6 +75,18 @@ set(PLUGIN_FILES
${DISSECTOR_SUPPORT_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
register_dissector_files(plugin.c
@ -93,8 +105,8 @@ add_library(wimax MODULE
target_link_libraries(wimax epan)
install(TARGETS wimax
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -30,6 +30,18 @@ set(PLUGIN_FILES
${DISSECTOR_SRC}
)
set(CLEAN_FILES
${PLUGIN_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
add_lex_files(PLUGIN_FILES
wimaxasncp_dict.l
)
@ -52,8 +64,8 @@ add_library(wimaxasncp MODULE
target_link_libraries(wimaxasncp epan)
install(TARGETS wimaxasncp
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/@CPACK_PACKAGE_NAME@/plugins/${CPACK_PACKAGE_VERSION}
)

View File

@ -25,6 +25,18 @@ set(lemon_FILES
lemon.c
)
set(CLEAN_FILES
${lemon_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
set(lemon_LIBS
# Do we need something here on any platform?
)

View File

@ -71,6 +71,18 @@ set(WIRETAP_FILES
wtap.c
)
set(CLEAN_FILES
${WIRETAP_FILES}
)
if (WERROR)
set_source_files_properties(
${CLEAN_FILES}
PROPERTIES
COMPILE_FLAGS -Werror
)
endif()
add_lex_files(WIRETAP_FILES
ascend_scanner.l
k12text.l