Commit Graph

7 Commits

Author SHA1 Message Date
Francois-Xavier Le Bail
f6b74c5cf2 CONTRIBUTING.md: Update about 'struct tok' usage
[skip ci]
2023-05-23 16:46:23 +02:00
Francois-Xavier Le Bail
9ca86a0927 instrument functions: Use an environment variable instead of config files
If the environment variable INSTRUMENT is
- unset or set to an empty string, print nothing, like with no
  instrumentation
- set to "all" or "a", print all the functions names
- set to "global" or "g", print only the global functions names

The configuration with --enable-instrument-functions remains.

Note that before this change, the default was to print all functions.
Now it is to print nothing. So by default 'make check' runs without errors.

This allows to run:
$ INSTRUMENT=a ./tcpdump ...
$ INSTRUMENT=g ./tcpdump ...
$ INSTRUMENT= ./tcpdump ...
or
$ export INSTRUMENT=global
$ ./tcpdump ...

This also allows to run the statically compiled binary on another host
after copying it.

It is no longer necessary to modify the configuration with:
$ make instrument_all
$ make instrument_global
$ make instrument_off
(Targets removed.)

Update .gitignore, CONTRIBUTING.md and Makefile.in accordingly.

Moreover:
Reduce the scope of a variable.
Rename a variable.
Remove '\n' in the perror() call.
Remove 2 spaces in function calls (style).

[skip ci]
2023-03-13 10:24:43 +01:00
Francois-Xavier Le Bail
9ab792b713 CONTRIBUTING: Add some tags 2022-10-17 14:51:30 +02:00
Francois-Xavier Le Bail
51d9642c0a CONTRIBUTING.md: Add information about the instrumentation of functions 2022-10-17 14:25:54 +02:00
Francois-Xavier Le Bail
91d3ed4dfb CONTRIBUTING.md: Document the use of "protocol: " in a commit summary
If the commit concerns a protocol, the summary line must start with
"protocol: ".
2022-09-03 20:46:15 +02:00
Francois-Xavier Le Bail
a0b5d87b67 Remove trailing spaces 2022-07-03 15:09:51 +02:00
Denis Ovsienko
af98bb4776 Convert CONTRIBUTING to Markdown. [skip ci] 2022-06-09 10:16:26 +01:00