Skip to content

Commit b92254b

Browse files
committed
Commit 38
- Code review (macros `NR_HISTORY_ROOT_VSTATE()` and `NR_BUMP_VSTATE()` in `not-autoversion.m4` – made sure that the default `NR_PROJECT_MINVER` is set to `1` when `NR_PROJECT_MAJVER` is `0`)
1 parent a94575e commit b92254b

File tree

5 files changed

+68
-49
lines changed

5 files changed

+68
-49
lines changed

ChangeLog.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,16 @@ Change Log
22
==========
33

44

5+
2.2.2
6+
-----
7+
8+
Changes:
9+
10+
* Code review (macros `NR_HISTORY_ROOT_VSTATE()` and `NR_BUMP_VSTATE()` in
11+
`not-autoversion.m4` – made sure that the default `NR_PROJECT_MINVER` is set
12+
to `1` when `NR_PROJECT_MAJVER` is `0`)
13+
14+
515
2.2.1
616
-----
717

@@ -135,7 +145,7 @@ Changes:
135145
* File † `not-multiversion.m4`, containing the † `NR_SET_VERSION_ENVIRONMENT()`
136146
macro, has been removed
137147
* Macros † `NS_ECHO_IF()` and † `NS_ECHO_IF_UNQUOTED()` have been removed from
138-
`not-autoshell.m4` -- you can use `NS_PP_IF([NS_STDOUT], ...)` and
148+
`not-autoshell.m4` you can use `NS_PP_IF([NS_STDOUT], ...)` and
139149
`NS_PP_IF([NS_STDOUT_UNQUOTED], ...)` to obtain the same result
140150
* Code review (macros `NC_MSG_ERRORBOX()` and `NC_MSG_FAILUREBOX()` in
141151
`not-ac-messages.m4`)
@@ -209,7 +219,7 @@ Changes:
209219
feature this macro was adding to the native `AC_CHECK_HEADERS()` was the
210220
possibility to give custom names to the shell variables created for each
211221
header)
212-
* Macro `n4_repeat()` has been simplified -- for complex cases please use
222+
* Macro `n4_repeat()` has been simplified for complex cases please use
213223
`m4_for()`
214224
* Code review (macro `NC_CONFIG_SHADOW_DIR()` in `not-extended-config.m4`;
215225
macros `NS_TEXT_WRAP()` in `not-autoshell.m4`; macros `NC_GET_PROGS()` and
@@ -414,8 +424,8 @@ Changes:
414424
been renamed to `NC_REQ_PROGS()` and `NC_GET_PROGS()`
415425
* Code review (macros † `NM_ENVIRONMENT_KEYS` and † `NM_LOAD_ENVIRONMENT` in
416426
`not-automake.m4`; macro † `NM_SET_VERSION_ENVIRONMENT()` in
417-
`not-misc.m4` -- the new version of the latter is incompatible with
418-
previous versions)
427+
`not-misc.m4` the new version of the latter is incompatible with previous
428+
versions)
419429
* Documentation
420430

421431

@@ -469,8 +479,8 @@ Changes:
469479

470480
Changes:
471481

472-
* Macro † `nm4_unlambda` has been removed from `not-m4sugar.m4` -- lambda
473-
macros are now safely created without polluting the global scope
482+
* Macro † `nm4_unlambda` has been removed from `not-m4sugar.m4` lambda macros
483+
are now safely created without polluting the global scope
474484
* M4sugar clones † `nm4_switch()` and † `nm4_case()` have been removed from
475485
`not-m4sugar.m4` (they were clones of `m4_case()` and `m4_bmatch()`
476486
respectively)

examples/not-autoversion/extended-example/autostuff/m4/not-autotools.m4

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,10 @@ dnl The initial version state expanded from the `root` argument passed to
194194
dnl `NR_RECORD_HISTORY()`
195195
m4_define([NR_HISTORY_ROOT_VSTATE],
196196
m4_dquote(m4_default_nblank_quoted(m4_argn([1], $1), [0]),
197-
m4_default_nblank_quoted(m4_argn([2], $1), [0]),
197+
m4_default_nblank(m4_quote(m4_argn([2], $1)),
198+
[m4_if(m4_eval(m4_argn([1], $1)[ + 0 > 0]), [1],
199+
[0],
200+
[1])]),
198201
m4_default_nblank_quoted(m4_argn([3], $1), [0]),
199202
m4_default_nblank_quoted(m4_argn([4], $1), [0]),
200203
m4_default_nblank_quoted(m4_argn([5], $1), [0]),
@@ -342,7 +345,7 @@ m4_define([NR_BUMP_VSTATE],
342345
[n4_has([$8],
343346
[LAUNCH],
344347
[1, 0, 0, 0, 0, 0, 0],
345-
[0, 0, 0, 0, 0, 0, 0])],
348+
[0, 1, 0, 0, 0, 0, 0])],
346349
[m4_if(m4_eval([$1 > 0]), [1],
347350
[n4_has([$8],
348351
[DEPARTURE],

examples/not-autoversion/simple-example/autostuff/m4/not-autotools.m4

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,10 @@ dnl The initial version state expanded from the `root` argument passed to
6161
dnl `NR_RECORD_HISTORY()`
6262
m4_define([NR_HISTORY_ROOT_VSTATE],
6363
m4_dquote(m4_default_nblank_quoted(m4_argn([1], $1), [0]),
64-
m4_default_nblank_quoted(m4_argn([2], $1), [0]),
64+
m4_default_nblank(m4_quote(m4_argn([2], $1)),
65+
[m4_if(m4_eval(m4_argn([1], $1)[ + 0 > 0]), [1],
66+
[0],
67+
[1])]),
6568
m4_default_nblank_quoted(m4_argn([3], $1), [0]),
6669
m4_default_nblank_quoted(m4_argn([4], $1), [0]),
6770
m4_default_nblank_quoted(m4_argn([5], $1), [0]),
@@ -209,7 +212,7 @@ m4_define([NR_BUMP_VSTATE],
209212
[n4_has([$8],
210213
[LAUNCH],
211214
[1, 0, 0, 0, 0, 0, 0],
212-
[0, 0, 0, 0, 0, 0, 0])],
215+
[0, 1, 0, 0, 0, 0, 0])],
213216
[m4_if(m4_eval([$1 > 0]), [1],
214217
[n4_has([$8],
215218
[DEPARTURE],

m4/not-autoversion.m4

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ dnl shell expansions here, you must use only literals.
383383
dnl
384384
dnl Expansion type: literal (void)
385385
dnl Requires: `NR_BUMP_VSTATE()`, `NR_GET_EVENT_VSTATE()`
386-
dnl Version: 1.0.0
386+
dnl Version: 1.0.1
387387
dnl Author: madmurphy
388388
dnl
389389
dnl **************************************************************************
@@ -396,7 +396,10 @@ dnl The initial version state expanded from the `root` argument passed to
396396
dnl `NR_RECORD_HISTORY()`
397397
m4_define([NR_HISTORY_ROOT_VSTATE],
398398
m4_dquote(m4_default_nblank_quoted(m4_argn([1], $1), [0]),
399-
m4_default_nblank_quoted(m4_argn([2], $1), [0]),
399+
m4_default_nblank(m4_quote(m4_argn([2], $1)),
400+
[m4_if(m4_eval(m4_argn([1], $1)[ + 0 > 0]), [1],
401+
[0],
402+
[1])]),
400403
m4_default_nblank_quoted(m4_argn([3], $1), [0]),
401404
m4_default_nblank_quoted(m4_argn([4], $1), [0]),
402405
m4_default_nblank_quoted(m4_argn([5], $1), [0]),
@@ -570,7 +573,7 @@ dnl This macro may be invoked before `AC_INIT()`.
570573
dnl
571574
dnl Expansion type: literal
572575
dnl Requires: `n4_has()` from `not-m4sugar.m4`
573-
dnl Version: 1.0.0
576+
dnl Version: 1.0.1
574577
dnl Author: madmurphy
575578
dnl
576579
dnl **************************************************************************
@@ -580,7 +583,7 @@ m4_define([NR_BUMP_VSTATE],
580583
[n4_has([$8],
581584
[LAUNCH],
582585
[1, 0, 0, 0, 0, 0, 0],
583-
[0, 0, 0, 0, 0, 0, 0])],
586+
[0, 1, 0, 0, 0, 0, 0])],
584587
[m4_if(m4_eval([$1 > 0]), [1],
585588
[n4_has([$8],
586589
[DEPARTURE],

macro-index.md

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -85,41 +85,41 @@ This is the complete list of macros released by the **Not Autotools** project.
8585

8686
* [`NR_RECORD_HISTORY()`](m4/not-autoversion.m4#L24)
8787
* [`NR_HISTORY_ROOT_VSTATE()`](m4/not-autoversion.m4#L393)
88-
* [`NR_HISTORY_EVENTS`](m4/not-autoversion.m4#L407)
89-
* [`NR_HISTORY_GET_EVENT_VSTATE()`](m4/not-autoversion.m4#L414)
90-
* [`NR_HISTORY_CURRENT_EVENT_NAME`](m4/not-autoversion.m4#L448)
91-
* [`NR_HISTORY_CURRENT_VSTATE`](m4/not-autoversion.m4#L455)
92-
* [`NR_PROJECT_MAJVER`](m4/not-autoversion.m4#L462)
93-
* [`NR_PROJECT_MINVER`](m4/not-autoversion.m4#L469)
94-
* [`NR_PROJECT_MICVER`](m4/not-autoversion.m4#L476)
95-
* [`NR_PROJECT_VERSION`](m4/not-autoversion.m4#L483)
96-
* [`NR_BINARY_MAJVER`](m4/not-autoversion.m4#L490)
97-
* [`NR_BINARY_MINVER`](m4/not-autoversion.m4#L498)
98-
* [`NR_BINARY_MICVER`](m4/not-autoversion.m4#L505)
99-
* [`NR_BINARY_VERSION`](m4/not-autoversion.m4#L512)
100-
* [`NR_INTERFACE_NUM`](m4/not-autoversion.m4#L519)
101-
* [`NR_INTERFACES_SUPPORTED`](m4/not-autoversion.m4#L526)
102-
* [`NR_IMPLEMENTATION_NUM`](m4/not-autoversion.m4#L533)
103-
* [`NR_LIBTOOL_VERSION_INFO`](m4/not-autoversion.m4#L540)
104-
* [`NR_SOURCE_AGE`](m4/not-autoversion.m4#L547)
105-
* [`NR_BUMP_VSTATE()`](m4/not-autoversion.m4#L556)
106-
* [`NR_GET_EVENT_VSTATE()`](m4/not-autoversion.m4#L622)
107-
* [`NR_FOR_EACH_EVENT()`](m4/not-autoversion.m4#L673)
108-
* [`NR_HISTORY_FOR_EACH_EVENT()`](m4/not-autoversion.m4#L791)
109-
* [`NR_VSTATE_GET_PROJECT_VERSION()`](m4/not-autoversion.m4#L899)
110-
* [`NR_VSTATE_GET_PROJECT_MAJVER()`](m4/not-autoversion.m4#L921)
111-
* [`NR_VSTATE_GET_PROJECT_MINVER()`](m4/not-autoversion.m4#L943)
112-
* [`NR_VSTATE_GET_PROJECT_MICVER()`](m4/not-autoversion.m4#L965)
113-
* [`NR_VSTATE_GET_BINARY_VERSION()`](m4/not-autoversion.m4#L987)
114-
* [`NR_VSTATE_GET_BINARY_MAJVER()`](m4/not-autoversion.m4#L1007)
115-
* [`NR_VSTATE_GET_BINARY_MINVER()`](m4/not-autoversion.m4#L1031)
116-
* [`NR_VSTATE_GET_BINARY_MICVER()`](m4/not-autoversion.m4#L1053)
117-
* [`NR_VSTATE_GET_LIBTOOL_VERSION_INFO()`](m4/not-autoversion.m4#L1075)
118-
* [`NR_VSTATE_GET_INTERFACE_NUM()`](m4/not-autoversion.m4#L1096)
119-
* [`NR_VSTATE_GET_INTERFACES_SUPPORTED()`](m4/not-autoversion.m4#L1119)
120-
* [`NR_VSTATE_GET_IMPLEMENTATION_NUM()`](m4/not-autoversion.m4#L1144)
121-
* [`NR_VSTATE_GET_SOURCE_AGE()`](m4/not-autoversion.m4#L1168)
122-
* [`NC_AUTOVERSION_SUBSTITUTIONS`](m4/not-autoversion.m4#L1190)
88+
* [`NR_HISTORY_EVENTS`](m4/not-autoversion.m4#L410)
89+
* [`NR_HISTORY_GET_EVENT_VSTATE()`](m4/not-autoversion.m4#L417)
90+
* [`NR_HISTORY_CURRENT_EVENT_NAME`](m4/not-autoversion.m4#L451)
91+
* [`NR_HISTORY_CURRENT_VSTATE`](m4/not-autoversion.m4#L458)
92+
* [`NR_PROJECT_MAJVER`](m4/not-autoversion.m4#L465)
93+
* [`NR_PROJECT_MINVER`](m4/not-autoversion.m4#L472)
94+
* [`NR_PROJECT_MICVER`](m4/not-autoversion.m4#L479)
95+
* [`NR_PROJECT_VERSION`](m4/not-autoversion.m4#L486)
96+
* [`NR_BINARY_MAJVER`](m4/not-autoversion.m4#L493)
97+
* [`NR_BINARY_MINVER`](m4/not-autoversion.m4#L501)
98+
* [`NR_BINARY_MICVER`](m4/not-autoversion.m4#L508)
99+
* [`NR_BINARY_VERSION`](m4/not-autoversion.m4#L515)
100+
* [`NR_INTERFACE_NUM`](m4/not-autoversion.m4#L522)
101+
* [`NR_INTERFACES_SUPPORTED`](m4/not-autoversion.m4#L529)
102+
* [`NR_IMPLEMENTATION_NUM`](m4/not-autoversion.m4#L536)
103+
* [`NR_LIBTOOL_VERSION_INFO`](m4/not-autoversion.m4#L543)
104+
* [`NR_SOURCE_AGE`](m4/not-autoversion.m4#L550)
105+
* [`NR_BUMP_VSTATE()`](m4/not-autoversion.m4#L559)
106+
* [`NR_GET_EVENT_VSTATE()`](m4/not-autoversion.m4#L625)
107+
* [`NR_FOR_EACH_EVENT()`](m4/not-autoversion.m4#L676)
108+
* [`NR_HISTORY_FOR_EACH_EVENT()`](m4/not-autoversion.m4#L794)
109+
* [`NR_VSTATE_GET_PROJECT_VERSION()`](m4/not-autoversion.m4#L902)
110+
* [`NR_VSTATE_GET_PROJECT_MAJVER()`](m4/not-autoversion.m4#L924)
111+
* [`NR_VSTATE_GET_PROJECT_MINVER()`](m4/not-autoversion.m4#L946)
112+
* [`NR_VSTATE_GET_PROJECT_MICVER()`](m4/not-autoversion.m4#L968)
113+
* [`NR_VSTATE_GET_BINARY_VERSION()`](m4/not-autoversion.m4#L990)
114+
* [`NR_VSTATE_GET_BINARY_MAJVER()`](m4/not-autoversion.m4#L1010)
115+
* [`NR_VSTATE_GET_BINARY_MINVER()`](m4/not-autoversion.m4#L1034)
116+
* [`NR_VSTATE_GET_BINARY_MICVER()`](m4/not-autoversion.m4#L1056)
117+
* [`NR_VSTATE_GET_LIBTOOL_VERSION_INFO()`](m4/not-autoversion.m4#L1078)
118+
* [`NR_VSTATE_GET_INTERFACE_NUM()`](m4/not-autoversion.m4#L1099)
119+
* [`NR_VSTATE_GET_INTERFACES_SUPPORTED()`](m4/not-autoversion.m4#L1122)
120+
* [`NR_VSTATE_GET_IMPLEMENTATION_NUM()`](m4/not-autoversion.m4#L1147)
121+
* [`NR_VSTATE_GET_SOURCE_AGE()`](m4/not-autoversion.m4#L1171)
122+
* [`NC_AUTOVERSION_SUBSTITUTIONS`](m4/not-autoversion.m4#L1193)
123123

124124

125125
## [`m4/not-autoreconf.m4`](m4/not-autoreconf.m4)

0 commit comments

Comments
 (0)