]> git.proxmox.com Git - mirror_frr.git/commitdiff
doc: add note and example on use of VERSION_TYPE_DEV and CONFDATE
authorLou Berger <lberger@labn.net>
Tue, 3 Apr 2018 18:04:31 +0000 (14:04 -0400)
committerLou Berger <lberger@labn.net>
Tue, 3 Apr 2018 18:04:31 +0000 (14:04 -0400)
Signed-off-by: Lou Berger <lberger@labn.net>
doc/developer/workflow.rst

index a6a950f6853d45460f2c4f0c3604b98a8c134b3c..291a277c6b687746a688bfd24c383ddf0bf34724 100644 (file)
@@ -708,7 +708,14 @@ either:
 In all cases, compatibility pieces should be marked with
 compiler/preprocessor annotations to print warnings at compile time,
 pointing to the appropriate update path. A ``-Werror`` build should fail
-if compatibility bits are used.
+if compatibility bits are used. To avoid compilation issues in released
+code, such compiler/preprocessor annotations must be ignored
+non-development branches. For example:
+
+    #if defined(VERSION_TYPE_DEV) && CONFDATE > 20180403
+    CPP_NOTICE("Use of <XYZ> is deprecated, please use <ABC>")
+    #endif
+
 
 Preferably, the shell script :file:`tools/fixup-deprecated.py` will be
 updated along with making non-backwards compatible code changes, or an