summaryrefslogtreecommitdiff
path: root/Cmds
AgeCommit message (Collapse)AuthorFilesLines
2017-02-09make: Fix spelling yaac -> yaccTobias Klauser1-1/+1
The parser generator's name is yacc, not yaac. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2016-10-04build: Simplify checking for PREFIX originTobias Klauser1-7/+3
Use the $(filter ...) make function to simplify the detection of the origin of the PREFIX variable. This allows to merge two duplicate definitions for the INSTX command. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2016-09-15build: configure: Add option to specify install path for binary filesVadim Kochan1-1/+6
Add new --prefix=PREFIX configure commandline option to specify installation directory for binaries. Add additional check in 'Cmds' file if --prefix was specified from 'configure' script, in that case required installation path components will be created automatically as it is done for 'make PREFIX=...' option. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2016-04-22build: Always silence the no-op check commandTobias Klauser1-1/+1
There is no point in outputing the true no-op command, as it will only clutter the logs. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-12-27build: Use busybox compatible gzip command line optionTobias Klauser1-1/+1
gzip from busybox does not understand the '--best' command line option. Use '-9' instead which is understood by all gzip flavours (checked with GNU, BSD and busybox). Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-08-19build: Don't strip generated binariesTobias Klauser1-5/+0
Except for some minor saving in disk space, stripping the binaries doesn't bring any benefits and it might prevent us from getting usable debugging information even from binaries build with DEBUG not set. Most distributions will strip the binaries as part of their packaging process anyhow. If someone really wants stripped binaries as a result of the netsniff-ng build, they could still add '-s' to CFLAGS or call strip manually. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-04-23build: Restore support for cross-compiling the netsniff-ng toolkitTobias Klauser1-5/+4
Ever since we switched to the hand-crafted ./configure script, support for cross-compiling the netsniff-ng toolkit was basically broken. Restore the abaility to cross-compile our tools by making ./configure consider the CROSS_COMPILE and SYSROOT variables. Example for cross-compiling on arm: $ CROSS_COMPILE=arm-linux-gnueabihf- \ SYSROOT=/usr/arm-linux-gnueabihf \ ./configure $ make assuming the cross-compiled libraries (and their respective pkg-config information) are in /usr/arm-linux-gnueabihf. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-04-23build: Rename LD command variable to LDQTobias Klauser1-1/+1
In order to be able to set the (sort of) standard command variables CC, LD etc. from configure via Config, rename the silent LD command variable to LDQ, in accordance with the existing CCQ. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-03-31build: Initialize value of $C (sparse checker enable/disable)Tobias Klauser1-0/+1
Otherwise we get Cmds:19: warning: undefined variable `C' during `make coverity'. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-09-09build: Don't overwrite CC variableTobias Klauser1-5/+6
Don't reset the variable CC in the Makefile, but set it to gcc by default (can be overriden when e.g. compiling with `make CC=clang'). This way we can also have non-verbose compiles with compilers other than gcc. Furthermore make sure that the CC variable is also respected for LD. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-08-15build: Add build flag to enable sparse checking of C source filesTobias Klauser1-0/+7
Similar to the 'make C=1' for the Linux kernel, wire up the sparse command for our build system in a similar fashion. Use 'make C=1 [tool]' to check the source files using sparse. Of course, the sparse tool needs to be installed and available in your $PATH for this to work. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-04-27build: Also use proper previous tag for people listTobias Klauser1-2/+3
Follow up for commit 311d4376 ("build: Make sure we get the correct previous tag for the changelog"). Move getting the previous tag into an own command and use it where appropriate. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-04-27build: Make sure we get the correct previous tag for the changelogTobias Klauser1-1/+1
When going from an -rc release to a stable release (e.g. v0.5.8 ;-) the generated shortlog will not be generated from the latest -rc tag but from the second to last due to the sort order of the tag list: 0.5.5 0.5.6 0.5.7 v0.5.8 <-- newest tag v0.5.8-rc1 v0.5.8-rc2 v0.5.8-rc3 v0.5.8-rc4 v0.5.8-rc5 <-- second newest tag Thus use 'git describe' to get the proper previous tag. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-02-27build: fix syntax error when detecting SHELL make variableJesper Dangaard Brouer1-1/+1
Fix the shell syntax error, introduced in: commit 11c34c86ca4 (build: Set SHELL make variable to bash if possible) Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
2014-02-24build: Set SHELL make variable to bash if possibleTobias Klauser1-0/+3
On Debian/Ubuntu systems, /bin/sh is /bin/dash which doesn't understand the -e option to the `echo' builtin. Thus the build output looks something like the following: Building netsniff-ng toolkit (0.5.8-rc5+) for x86_64-linux-gnu: Building netsniff-ng: -e CC dissector.c -e CC dissector_eth.c -e CC dissector_80211.c ... Prevent this by setting SHELL to /bin/bash if it exists on the system, otherwise stick to /bin/sh. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-10-07build: Create GPG signatures as part of release targetTobias Klauser1-0/+4
Create detached ASCII format GPG signatures for the to be released tarballs. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-08-12build: Add Makefile target for Coverity scannerTobias Klauser1-0/+3
Add a Makefile target to build and upload a snapshot of netsniff-ng to the Coverity scanner. The variables COV_EMAIL and COV_PASSWD need to be set accordingly: make coverity COV_EMAIL=tklauser@distanz.ch COV_PASSWD=... Currently the sub-make which is part of the cov-built call issues warnings about undefined variables from the template. This can be ignored, the build works just fine. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-07-30build: Use -n option to head commandTobias Klauser1-2/+2
Make the call to `head' equivalent to the one to `tail'. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-07-29build: fix up GIT_PEOPLE and GIT_LOG macrosDaniel Borkmann1-2/+2
Fix them up so that a proper changelog can be generated automatically. Also while at it, add two "hidden" targets that can be used to test their output. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-07-29build: tag: add 'v' prefix for tag nameDaniel Borkmann1-1/+1
We need to add a 'v' prefix to the actual version for the tag name. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-07-29build: use VERSION_SHORT instead of VERSION_STRINGDaniel Borkmann1-4/+4
We have recently changed VERSION_STRING to append CONFIG_RC at the end of the string. Thus, for the build system, change it to VERSION_SHORT where needed, e.g. in release targets where the "+" appendix is not wished. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-07-24build: split build system into smaller manageable piecesDaniel Borkmann1-0/+41
Split the build system into smaller manageable pieces, grouped by context. In that sense, we can keep the most important information within the Makefile itself, and group out misc bits and pieces that we just include into it. E.g. 'Cmds' contains all defined commands that we call from other locations, 'Template' contains the generic build template for all tools, 'Extra' has pieces that need special treatment for the tools to build and 'Misc' contains help and release code. This makes it more manageable on the long run. While at it, I also simplified some code and removed all Wflags expect "-Wall" as we want to convert into "-Wall -Wextra -W" anyway. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>