Skip to content

Commit

Permalink
Refactor the versioning info to a single location.
Browse files Browse the repository at this point in the history
Coalesce all versioning information to a single location controlled
by Autotools, the `configure.ac` file.
  • Loading branch information
jbenden committed Feb 27, 2019
1 parent 1464ea8 commit 10a31bb
Show file tree
Hide file tree
Showing 34 changed files with 163 additions and 121 deletions.
64 changes: 44 additions & 20 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,21 @@
src/*-ng
src/besside-ng-crawler
src/ivstools
src/kstats
src/wpaclean
/*-ng
/besside-ng-crawler
/ivstools
/kstats
/wpaclean
src/osdep/.os.Linux
src/osdep/libosdep.a
src/tags
tags
*.a
*.so
*.dll
*.o
*.exe
*.log
*.trs
*.zip
*.tar.*
common.cfg
Makefile.in
aclocal.m4
Expand All @@ -23,6 +30,7 @@ install-sh
libtool
ltmain.sh
missing
/stamp-*
reautogen.sh
src/Makefile.in
*.lo
Expand All @@ -41,14 +49,14 @@ src/Makefile.in
/test/**/*.trs
/scripts/airdrop-ng/build
/scripts/airgraph-ng/build
test/cryptounittest/test-calc-4pmk
test/cryptounittest/test-calc-mic
test/cryptounittest/test-calc-pmk
test/cryptounittest/test-calc-ptk
test/cryptounittest/test-decrypt-ccmp
test/cryptounittest/test-encrypt-ccmp
test/cryptounittest/test-encrypt-wep
test/test-hex_string_to_array
/test-calc-4pmk
/test-calc-mic
/test-calc-pmk
/test-calc-ptk
/test-decrypt-ccmp
/test-encrypt-ccmp
/test-encrypt-wep
/test-hex_string_to_array
/build/m4/stubs/*
!/build/m4/stubs/.gitkeep
/test/test-env.sh
Expand All @@ -65,19 +73,35 @@ Makefile
!/contrib/peek/Makefile
!/scripts/airgraph-ng/lib/Makefile
/scripts/airmon-ng
/src/aircrack-ng--*
/benchmark.csv
/.cccc
/cccc.opt
/.scannerwork
/.bash_history
/.cproject
/.lesshst
/.project
/.rpmdb
/.settings
benchmark*.csv
/bw-output
compile_commands.json
coverage*.info
/test/cryptounittest/default.profraw
/test/unit/test-calc-one-pmk
/test/unit/test-string-has-suffix
/test/unit/test-wpapsk
/test/unit/test-wpapsk-cmac
/test/unit/test-circular-buffer
/test/unit/test-circular-queue
/test-calc-one-pmk
/test-string-has-suffix
/test-wpapsk
/test-wpapsk-cmac
/test-circular-buffer
/test-circular-queue
/GPATH
/GRTAGS
/GSYMS
/GTAGS
/VERSION
/aminclude_static.am
/config.h
/config.h.in
/src/version.h
/manpages/*.1
/manpages/*.8
1 change: 0 additions & 1 deletion VERSION

This file was deleted.

1 change: 1 addition & 0 deletions VERSION.in
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@_MAJ@.@_MIN@.@_SUB_MIN@
45 changes: 0 additions & 45 deletions build/m4/aircrack_ng_revision.m4

This file was deleted.

56 changes: 55 additions & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,19 @@
# If you delete this exception statement from all source files in the
# program, then also delete it here.

m4_define([version_date], "December 2018")
m4_define([version_major], 1)
m4_define([version_minor], 5)
m4_define([version_micro], 2)
m4_define([version_beta], 0)
m4_define([version_rc], 0)
m4_define([version_scm],[m4_translit(m4_esyscmd([$(pwd)/evalrev . scm || echo]),m4_newline)])
m4_define([version_triplet],version_major.version_minor.version_micro)
m4_append([version_triplet],version_scm)

AC_PREREQ(2.52)
AC_INIT([aircrack-ng],
[m4_translit(m4_esyscmd([$(pwd)/evalrev || cat $(pwd)/VERSION]),m4_newline)],
[version_triplet],
[https://forum.aircrack-ng.org])

#
Expand Down Expand Up @@ -79,6 +89,24 @@ AM_PROG_AS
PKG_PROG_PKG_CONFIG
AM_PROG_CC_C_O

#
# Set versioning detail
#
AC_SUBST([_MAJ], [version_major])
AC_SUBST([_MIN], [version_minor])
AC_SUBST([_SUB_MIN], [version_micro])
AC_SUBST([_BETA], [version_beta])
AC_SUBST([_RC], [version_rc])
AC_SUBST([_SCM], [version_scm])
AC_SUBST([LT_VER], [version_major.version_minor.version_micro])
AC_SUBST([MAN_RELEASE_DATE], [version_date])
AC_SUBST([MAN_RELEASE_VERSION], ["Version version_triplet"])
AC_DEFINE([_REVISION], ["version_triplet"], [The version information of the project])
AC_DEFINE([LT_CYGWIN_VER], ["-version_major-version_minor-version_micro.dll"], [The Cygwin DLL version string suffix])

#
# Initialize libtool
#
LT_INIT([win32-dll disable-static shared])

#
Expand Down Expand Up @@ -194,9 +222,35 @@ LIBS="$opt_libs $LIBS"
# Generate all build files
#
AC_OUTPUT([
VERSION
src/version.h
Makefile
manpages/airbase-ng.8
manpages/aircrack-ng.1
manpages/airdecap-ng.1
manpages/airdecloak-ng.1
manpages/aireplay-ng.8
manpages/airmon-ng.8
manpages/airodump-ng.8
manpages/airodump-ng-oui-update.8
manpages/airolib-ng.1
manpages/airserv-ng.8
manpages/airtun-ng.8
manpages/airventriloquist-ng.8
manpages/besside-ng.8
manpages/besside-ng-crawler.1
manpages/buddy-ng.1
manpages/easside-ng.8
manpages/ivstools.1
manpages/kstats.1
manpages/Makefile
manpages/makeivs-ng.1
manpages/packetforge-ng.1
manpages/tkiptun-ng.8
manpages/wesside-ng.8
manpages/wpaclean.1
scripts/Makefile
scripts/airdrop-ng/Makefile
Expand Down
9 changes: 8 additions & 1 deletion evalrev
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ set -euf
DIR=${1:-}
CMD=${2:-}

SCM=""

if [ x$DIR = "x" ]
then
DIR="."
Expand All @@ -24,6 +26,7 @@ if test -d "${DIR}/.git"; then

if test -z "$EXACTLY"; then
REVISION="${REVISION}_rev-$(git rev-parse --verify --short HEAD)"
SCM="_rev-$(git rev-parse --verify --short HEAD)"
fi
elif test -d "${DIR}/.svn"; then
REVISION="_r$(svnversion $DIR 2> /dev/null | sed 's/[^0-9]*//g')"
Expand All @@ -35,17 +38,21 @@ elif test -d "${DIR}/.svn"; then
if test x$REVISION = "x"; then
if test -f "${DIR}/.svn/entries"; then
REVISION="_r$(cat ${DIR}/.svn/entries | grep -i revision | head -n 1 | sed 's/[^0-9]*//g')"
SCM="_r$(cat ${DIR}/.svn/entries | grep -i revision | head -n 1 | sed 's/[^0-9]*//g')"
fi
fi

if test x$REVISION = "x"; then
REVISION="_r1"
SCM="_r1"
fi
else
REVISION="$(cat ${DIR}/VERSION)"
fi

if test "x$CMD" = "xquoted"; then
if test "x$CMD" = "xscm"; then
echo $SCM
elif test "x$CMD" = "xquoted"; then
echo \"$REVISION\"
else
echo $REVISION
Expand Down
30 changes: 15 additions & 15 deletions manpages/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -86,18 +86,18 @@ dist_man8_MANS += airventriloquist-ng.8 \
endif
endif

EXTRA_DIST = airmon-ng.8 \
airolib-ng.1 \
besside-ng-crawler.1 \
buddy-ng.1 \
airventriloquist-ng.8 \
besside-ng.8 \
easside-ng.8 \
tkiptun-ng.8 \
wesside-ng.8 \
wpaclean.1 \
airbase-ng.8 \
aireplay-ng.8 \
airodump-ng.8 \
airserv-ng.8 \
airtun-ng.8
EXTRA_DIST = airmon-ng.8.in \
airolib-ng.1.in \
besside-ng-crawler.1.in \
buddy-ng.1.in \
airventriloquist-ng.8.in \
besside-ng.8.in \
easside-ng.8.in \
tkiptun-ng.8.in \
wesside-ng.8.in \
wpaclean.1.in \
airbase-ng.8.in \
aireplay-ng.8.in \
airodump-ng.8.in \
airserv-ng.8.in \
airtun-ng.8.in
2 changes: 1 addition & 1 deletion manpages/airbase-ng.8 → manpages/airbase-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRBASE-NG 8 "December 2018" "Version 1.5.2"
.TH AIRBASE-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airbase-ng - multi-purpose tool aimed at attacking clients as opposed to the Access Point (AP) itself
Expand Down
2 changes: 1 addition & 1 deletion manpages/aircrack-ng.1 → manpages/aircrack-ng.1.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRCRACK-NG 1 "December 2018" "Version 1.5.2"
.TH AIRCRACK-NG 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
aircrack-ng - a 802.11 WEP / WPA-PSK key cracker
Expand Down
2 changes: 1 addition & 1 deletion manpages/airdecap-ng.1 → manpages/airdecap-ng.1.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRDECAP-NG 1 "December 2018" "Version 1.5.2"
.TH AIRDECAP-NG 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airdecap-ng - decrypt a WEP/WPA crypted pcap file
Expand Down
2 changes: 1 addition & 1 deletion manpages/airdecloak-ng.1 → manpages/airdecloak-ng.1.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRDECLOAK-NG 1 "December 2018" "Version 1.5.2"
.TH AIRDECLOAK-NG 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airuncloak-ng - Removes wep cloaked framed from a pcap file.
Expand Down
2 changes: 1 addition & 1 deletion manpages/aireplay-ng.8 → manpages/aireplay-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIREPLAY-NG 8 "December 2018" "Version 1.5.2"
.TH AIREPLAY-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
aireplay-ng - inject packets into a wireless network to generate traffic
Expand Down
2 changes: 1 addition & 1 deletion manpages/airmon-ng.8 → manpages/airmon-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRMON-NG 8 "December 2018" "Version 1.5.2"
.TH AIRMON-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airmon-ng - POSIX sh script designed to turn wireless cards into monitor mode.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRODUMP-NG-OUI-UPDATE 8 "December 2018" "Version 1.5.2"
.TH AIRODUMP-NG-OUI-UPDATE 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airodump-ng-oui-updater - IEEE oui list updater for airodump-ng
Expand Down
2 changes: 1 addition & 1 deletion manpages/airodump-ng.8 → manpages/airodump-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRODUMP-NG 8 "December 2018" "Version 1.5.2"
.TH AIRODUMP-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airodump-ng - a wireless packet capture tool for aircrack-ng
Expand Down
2 changes: 1 addition & 1 deletion manpages/airolib-ng.1 → manpages/airolib-ng.1.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIROLIB-NG 1 "December 2018" "Version 1.5.2"
.TH AIROLIB-NG 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airolib-ng - manage and create a WPA/WPA2 pre-computed hashes tables
Expand Down
2 changes: 1 addition & 1 deletion manpages/airserv-ng.8 → manpages/airserv-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRSERV-NG 8 "December 2018" "Version 1.5.2"
.TH AIRSERV-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airserv-ng - a wireless card server
Expand Down
2 changes: 1 addition & 1 deletion manpages/airtun-ng.8 → manpages/airtun-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRTUN-NG 8 "December 2018" "Version 1.5.2"
.TH AIRTUN-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airtun-ng - a virtual tunnel interface creator for aircrack-ng
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH AIRVENTRILOQUIST-NG 8 "December 2018" "Version 1.5.2"
.TH AIRVENTRILOQUIST-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
airventriloquist-ng - encrypted WiFi packet injection
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH BESSIDE-NG-CRAWLER 1 "December 2018" "Version 1.5.2"
.TH BESSIDE-NG-CRAWLER 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"


.SH NAME
Expand Down
2 changes: 1 addition & 1 deletion manpages/besside-ng.8 → manpages/besside-ng.8.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH BESSIDE-NG 8 "December 2018" "Version 1.5.2"
.TH BESSIDE-NG 8 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
besside-ng - crack a WEP or WPA key without user intervention and collaborate with WPA cracking statistics
Expand Down
2 changes: 1 addition & 1 deletion manpages/buddy-ng.1 → manpages/buddy-ng.1.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH BUDDY-NG 1 "December 2018" "Version 1.5.2"
.TH BUDDY-NG 1 "@MAN_RELEASE_DATE@" "@MAN_RELEASE_VERSION@"

.SH NAME
buddy-ng - a tool to work with easside-ng
Expand Down
Loading

0 comments on commit 10a31bb

Please sign in to comment.