aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/modules/UseAsn2Wrs.cmake
AgeCommit message (Collapse)AuthorFilesLines
2016-03-24CMake: Find asn2wrs.py once.Gerald Combs1-3/+3
Load LocatePythonModule and use it to find asn2wrs once instead of every time we cal the ASN2WRS function. This reduces the cmake run time by about 3 to 4 seconds here. Change-Id: I85f7dcca0b5891c9b4b23a76d017f8e504d6af60 Reviewed-on: https://code.wireshark.org/review/14614 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-11-26cmake: add asn1 target, avoid unnecessary rebuildsPeter Wu1-44/+74
Add an "asn1" build target that rebuilds all ASN.1 dissectors. Do not always generate the ASN.1 dissector when invoking the "generate_dissector-PROTO" target. Use a special "packet-PROTO-stamp" file to detect whether the dissector is out of date. This indirection is needed because cmake removes output files from add_custom_command in the clean target, but we would like to keep the generated packet-PROTO.c files. Make all EXTRA_CNF and EXPORT_DEPENDS point to absolute paths for generated exported configs (PROTO-exp.cnf). This is done by automake too and is needed for proper dependency tracking. Example: when h225.cnf is updated, h225-exp.cnf needs to be generated. That is the purpose of the "generate-h225-exp.cnf" target. Now h235 (and other) dissectors need to be regenerated as well because the h225-exp.cnf is updated. This is why there is a separate add_custom_command and add_custom_target. Change-Id: I8cfc1f8f43cea595267b21eae30b4548f3407c0b Reviewed-on: https://code.wireshark.org/review/12080 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-25Revert commit cc8ed845ed53ed60fa776728f1d7f2659dd311a3Joerg Mayer1-4/+3
Author: Maarten Bezemer <maarten.bezemer@gmail.com> Date: Wed Nov 12 13:39:07 2014 +0100 Invoke asn2wrs.py using a custom command Fixes bugid 11304 Once there is a better solution feel free to revert the revert. Change-Id: Id64b621c5f3b8a934ce9ec5c3c127326efab46f2 Reviewed-on: https://code.wireshark.org/review/9122 Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2014-12-18Use LocatePythonModule to locate asn2wrs.pyMaarten Bezemer1-5/+6
This reuses existing functionality and thereby making FindAsn2Wrs.cmake obsolete, resulting in a reduction of the cmake module maintaince load Change-Id: Ic6ae53e65236246c0cbe86f8c2f066a2d034e0b9 Reviewed-on: https://code.wireshark.org/review/5805 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-17Invoke asn2wrs.py using a custom commandMaarten Bezemer1-3/+4
A custom target is defined to be always invalid, so asn2wrs.py is always invoked. A custom command is able to convert input file(s) into output file(s), the actual command is only invoked in the provided dependencies are changed. As an advantage the dependencies are correct, so cmake is able to determine when the output file is required, so it can be build in time. Change-Id: I84be5d408cfc87cf88d67b6073bea439febbe712 Reviewed-on: https://code.wireshark.org/review/5255 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-17Do not force the output directoryMaarten Bezemer1-2/+11
For out of source builds, the output directory should not point to wireshark source locations. By default it does point to the wireshark source directory (to stay compatible with the build in dissectors). When the A2W_OUTPUT_DIR variable is set to "_EMPTY_" the output lcoation argument (-O) is not invoked. Use A2W_FLAGS to set an output location for out of source builds (or use A2W_OUTPUT_DIR, which has the same result) Change-Id: I48b7486fcda982f0dce57cde3beacb99f946abd9 Reviewed-on: https://code.wireshark.org/review/5254 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-17Use FindAsn2Wrs to find asn2wrs.pyMaarten Bezemer1-4/+6
A first step to make it possible to reuse the UseAsn2Wrs for out of source builds. Change-Id: Iefb34f943e06db3d6afed55ab69d3f26aa9d633d Reviewed-on: https://code.wireshark.org/review/5253 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-03-31Continue to remove $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^\# \$Id\$/,+1 d') (start with dash) Change-Id: Ia4b5a6c2302f6a531f6a86c1ec3a2f8205c8c2dd Reviewed-on: https://code.wireshark.org/review/881 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2013-09-17When building packet-dap.c on an empty build tree, packet-dap.c wouldJörg Mayer1-0/+1
be incorrect on the first pass and only be correct when remade. The reason was that disp-exp.cnf was created incorrectly on first pass. disp-exp.cnf required dop-exp.cnf to build correctly, so add a mechanism to add dependencies for export files. Note: Only the cmake change has been tested, the autofoo stuff requires testing. svn path=/trunk/; revision=52120
2013-05-11Remove generating .cnf files from all target. They willJörg Mayer1-1/+2
be generated when needed. svn path=/trunk/; revision=49241
2013-05-07Make exports actaully workJörg Mayer1-13/+15
Add ansi_map as first generated file that uses exports (from gsm_map in this case). svn path=/trunk/; revision=49195
2013-05-07Move common code into UseAsn2Wrs.cmake.Jörg Mayer1-0/+44
Include the new file. Use the new file. Add cmake support to rebuild the gsm_map dissector. svn path=/trunk/; revision=49194