Commit Graph

42 Commits

Author SHA1 Message Date
Joerg Mayer a0e1d282f2 Do not update register.c's timestamp if it is unchanged, otherwise it gets recompiled
every time one of its dependencies is touched.

Change-Id: I8c0c4caea8355748e5abf9b9fe3804834353075f
Reviewed-on: https://code.wireshark.org/review/18304
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-10-19 08:51:27 +00:00
Joerg Mayer 7b73a04116 $Id$ is useless with git - treat it exaclty like this
Change-Id: I607ce7ded40864c1b4dcc0a2d577a65923af4225
Reviewed-on: https://code.wireshark.org/review/18248
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-10-17 19:09:45 +00:00
Pascal Quantin 6baa1b544c Remove Nmake build system
Change-Id: I3bd474f3cda9667dec66426b5729449953df3e61
Reviewed-on: https://code.wireshark.org/review/15777
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2016-06-15 19:21:57 +00:00
João Valverde 88f437417d Indent register.c and other cosmetic changes
Change-Id: I06e863e0b87118047f4c3b7618df02b9c7384a34
Reviewed-on: https://code.wireshark.org/review/15836
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-13 13:12:45 +00:00
Jeff Morriss 82e2865739 Remove $Id$ and other Subversion leftovers from the tools.
There are a few things in here which could still use attention.

Don't regenerate anything now.

Change-Id: I283c224d3523212144707fca3d6265916cb11792
Reviewed-on: https://code.wireshark.org/review/205
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2014-02-14 01:35:57 +00:00
Jakub Zawadzki 6bb97fa327 Generate prototype for plugin_reg_handoff()
This should fix warnings:
 plugin.c:XX:1: warning: no previous prototype for 'plugin_reg_handoff' [-Wmissing-prototypes]

svn path=/trunk/; revision=54475
2013-12-27 15:46:50 +00:00
Anders Broman d0915cabb3 Fix [-Wmissing-prototypes]
svn path=/trunk/; revision=54473
2013-12-27 10:49:35 +00:00
Gerald Combs c02bbf9883 Use indentation recommended by PEP 8.
svn path=/trunk/; revision=53684
2013-12-01 01:46:45 +00:00
Gerald Combs 80b4bc004a Fix compatibility with Python 2.5. Tested with 2.5, 2.6, 2.7, and 3.3.
svn path=/trunk/; revision=53683
2013-12-01 01:35:13 +00:00
Jörg Mayer fb22ecce8d Graham Bloice
I've now got tshark to build from a VS solution file, had to do some hacks
to get there though, patch files attached for others to peruse, as I'm not
sure if they are the optimal solutions:

   3. As mentioned in my previous message, the VS solution chops out every
   8192nd byte from the command line passed to make-dissector-reg.py.  My
   patch (make-reg.patch) gets CMake to write out the required source file
   list to a file and modifies the python script to read in the file.  The
   python changes *should* be backwards compatible.

Me: Small fix to UseMakeDissectorReg.cmake (elseif() -> else())

svn path=/trunk/; revision=53654
2013-11-29 19:57:00 +00:00
Gerald Combs 4111941a75 Fix compatibility with older versions of Python. Tested with 2.5, 2.6,
and 3.3.

svn path=/trunk/; revision=51079
2013-07-31 23:32:45 +00:00
Gerald Combs ee9c3082a8 Add support for Python 3. Make sure we pass bytes to hashlib.sha1 as
suggested in bug 8995. Call print as a function instead of a builtin as
suggested by 2to3.

svn path=/trunk/; revision=51073
2013-07-31 20:14:35 +00:00
Guy Harris 5d87a8c461 WS_DLL_PUBLIC is now always WS_DLL_PUBLIC_NOEXTERN with "extern" added;
just define WS_DLL_PUBLIC_NOEXTERN inside the ifdefs, and define
WS_DLL_PUBLIC as WS_DLL_PUBLIC_NOEXTERN followed by "extern".

Then rename WS_DLL_PUBLIC_NOEXTERN to WS_DLL_PUBLIC_DEF, to clarify that
it's what should be used for definitions; at least on Windows, you
*have* to use it when declaring arrays without a size, and, whilst you
might be able to use WS_DLL_PUBLIC for definitions of functions and
perhaps data definitions other than no-size arrays, it might be clearer
to rename WS_DLL_PUBLIC to WS_DLL_PUBLIC_DECL and use it only for
declarations.

svn path=/trunk/; revision=50334
2013-07-03 01:43:39 +00:00
Gerald Combs 267a89b1f4 Make boilerplate consistent with other generated files and recognizable
by licensecheck.

svn path=/trunk/; revision=48826
2013-04-11 20:03:16 +00:00
Balint Reczey 1ebdb2e521 Export libwireshark symbols using WS_DLL_PUBLIC define
Also remove old WS_VAR_IMPORT define and related Makefile magic
everywhere in the project.

svn path=/trunk/; revision=47992
2013-03-01 23:53:11 +00:00
Evan Huus b409efefce Touch the file in make-dissector-reg.py if it hasn't changed, so that
we don't try and regenerate it every single subsequent build.

Also, add modelines.

svn path=/trunk/; revision=45117
2012-09-25 01:06:13 +00:00
Gerald Combs c3f2dbdb8d Update make-dissector-reg.py to match r45083. Instead of writing the new
plugin.c or register.c content to a temporary file build a giant string
in memory and only write it if the current and new hashes differ.

This requires hashlib which was added in Python 2.5; hopefully that's
not a problem.

svn path=/trunk/; revision=45104
2012-09-24 16:21:56 +00:00
Jörg Mayer a9ddd42c28 make-dissector-reg
Only update outfile if it differs from newly created outfile
make-dissector-reg.py
	Add a comment that we should do the same here (probably a small
	task for python knowledeable people).

svn path=/trunk/; revision=45083
2012-09-24 05:59:56 +00:00
Jeff Morriss 22b7086fb9 We always HAVE_CONFIG_H so don't bother checking whether we have it or not.
svn path=/trunk/; revision=44997
2012-09-19 01:37:13 +00:00
Jeff Morriss 06499e6dd0 Put back the part of the regexp's that avoids finding function prototypes.
svn path=/trunk/; revision=44955
2012-09-17 21:56:52 +00:00
Jeff Morriss 211f791c6c Rather than reading the dissectors line by line and searching for the
registration and handoff routines in each line, read the whole file into
memory and then do one findall() search. Store the matches in sets to avoid
duplication.

(This also simplifies the number of regexps we're looking for.)

This speeds up the generation of register.c (when there is no cache)
significantly (on my system the time taken drops from ~32 seconds to ~5
seconds).

svn path=/trunk/; revision=44954
2012-09-17 21:30:24 +00:00
Jeff Morriss 73c0fa86f9 Unique-ify the list of dissector registration and handoff functions while we
sort them.  Avoids the double registration problem discussed on -dev today.

Note: the sorted() call requires Python 2.4+ but I think that's OK now.

svn path=/trunk/; revision=44952
2012-09-17 20:37:39 +00:00
Gerald Combs 3080352f4f make-dissector-reg.py doesn't always open its cache file.
svn path=/trunk/; revision=40736
2012-01-26 21:38:53 +00:00
Gerald Combs 6981aa2c2a Apply changes from the "2to3" conversion utility. Print cache information.
svn path=/trunk/; revision=40734
2012-01-26 19:38:27 +00:00
Kovarththanan Rajaratnam 7fd5cf604f Split register_count() into proto_reg_count() and handoff_reg_count()
svn path=/trunk/; revision=30447
2009-10-09 20:47:18 +00:00
Kovarththanan Rajaratnam adf31b356e Concatenate path in a more portable fashion
svn path=/trunk/; revision=30446
2009-10-09 20:38:51 +00:00
Gerald Combs 4968b876cd Add more information to the comments at the top of the files we generate.
svn path=/trunk/; revision=29550
2009-08-25 17:55:55 +00:00
Gerald Combs e18f0f79da Fix our keyword anchor.
svn path=/trunk/; revision=27578
2009-03-02 18:40:56 +00:00
Gerald Combs 0028a06052 Add a version to register-cache.pkl and use it to rebuild the cache from
scratch when needed.

svn path=/trunk/; revision=27577
2009-03-02 18:30:16 +00:00
Anders Broman 0e38ede281 From Vincent Helfre:
Build the register routines for wtap plugins.

svn path=/trunk/; revision=27532
2009-02-24 07:04:41 +00:00
Anders Broman 7c48128948 Revert previous checkin.
svn path=/trunk/; revision=27356
2009-02-02 22:16:46 +00:00
Anders Broman d92ab193f5 Use Python to build tshark-tap-register.c
svn path=/trunk/; revision=27355
2009-02-02 21:22:01 +00:00
Bill Meier 936381623d Add 'executable' property to a few .pl and .py files
svn path=/trunk/; revision=24390
2008-02-19 13:44:02 +00:00
Graeme Lunt cf56e76be9 Updated splash screen for Wireshark that shows the initialisation progress.
The splash screen shows a progress bar and a percentage complete - like the progress dialog.
As dissectors are initialised and handed off the name is shown. However, the names of plugin dissectors are not shown.
The update to the make-dissector-reg shell script has been tested, though I think generally the python version is used.


svn path=/trunk/; revision=21716
2007-05-07 17:55:42 +00:00
Gerald Combs fc2e2a7c3b Use the older-style ST_MTIME instead of st_mtime. This should fix backward
compatibility.

svn path=/trunk/; revision=21459
2007-04-17 17:13:55 +00:00
Gerald Combs b190b5e759 Fixup whitespace.
svn path=/trunk/; revision=21419
2007-04-13 22:49:54 +00:00
Gerald Combs a0afc5d832 Add a registration symbol cache to make-dissector-reg.py. When you
update a dissector and recompile, make-dissector-reg.py can now pull
its list of registration routines from a cache instead of having to
scan through every dissector.  The time to create register.c has gone
from 20 to 30 seconds down to 2 on my desktop machine.

The cache file is a Python pickle data stream.  It should be portable
across architectures, so we may be able to add it to the distribution
at some point.

svn path=/trunk/; revision=21348
2007-04-06 16:15:36 +00:00
Gerald Combs 90a9317e4e Loosen up our restrictions so that plugins can compile.
svn path=/trunk/; revision=21340
2007-04-05 22:42:34 +00:00
Gerald Combs fdbcca2123 In epan/dissectors/Makefile.nmake, fix a typo.
In make-dissector-reg.py, throw an error if we don't have enough files
to process, or if we don't generate enough registrations.  "Enough"
is arbitrarily set to 100.

This should de-purple the buildbot.  (I'm sure there's a "smoke on the
water" joke in there somewhere.)

svn path=/trunk/; revision=21338
2007-04-05 21:38:39 +00:00
Gerald Combs b15974d094 libethereal -> libwireshark. idl2eth -> idl2wrs. There are a _lot_ of
changes here.  It compiles OK on OS X, but hasn't been tested anywhere else.

svn path=/trunk/; revision=18260
2006-05-31 00:23:01 +00:00
Guy Harris 7866389ea4 Put a newline at the end of plugin.c files.
svn path=/trunk/; revision=18185
2006-05-18 11:37:32 +00:00
Guy Harris fd1cec8917 Rename "make-reg-dotc" to "make-dissector-reg", and do the same for the
Python versions, as it no longer makes only "register.c", it can also
make a "plugin.c" file for a plugin.

When making "plugin.c", there's no need to include "register.h", as it's
not defining any functions declared there.

svn path=/trunk/; revision=17919
2006-04-20 02:21:28 +00:00