lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master 613f9fcf 3/6: Make ccache ignore date and tim


From: Greg Chicares
Subject: [lmi-commits] [lmi] master 613f9fcf 3/6: Make ccache ignore date and time macros
Date: Tue, 21 Feb 2023 13:13:19 -0500 (EST)

branch: master
commit 613f9fcfa81b80649388587125c51c504e85b8e2
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>

    Make ccache ignore date and time macros
    
    * gwc/.zshrc: Ignore such macros for caching.
    * test_coding_rules.cpp: Disallow such macros in lmi code.
---
 gwc/.zshrc            | 11 +++++++++++
 test_coding_rules.cpp |  1 -
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/gwc/.zshrc b/gwc/.zshrc
index 2bb62241..89f1e105 100644
--- a/gwc/.zshrc
+++ b/gwc/.zshrc
@@ -26,6 +26,17 @@ fi
 # Use a common ccache directory for all users and all chroots.
 export CCACHE_DIR=/srv/cache_for_lmi/ccache
 
+# Make ccache ignore date and time macros, which are not allowed
+# by 'make check_concinnity' anyway in lmi code. Consequently, it
+# ignores those macros for third-party libraries as well; as this
+# is written in 2023-02, only
+#   /opt/lmi/third_party/src/cgicc/Cgicc.cpp
+# is affected (its getCompileTime() and getCompileDate() functions
+# still do the right thing when cached), and it is blithely assumed
+# that no other third-party library will ever use these macros in a
+# ccache-unfriendly way.
+export CCACHE_SLOPPINESS=time_macros
+
 # Something like
 #  "--jobs=$(nproc || sysctl -n hw.ncpu || getconf _NPROCESSORS_ONLN)"
 # could be used instead for other *nix systems:
diff --git a/test_coding_rules.cpp b/test_coding_rules.cpp
index e98caa0c..e2b55456 100644
--- a/test_coding_rules.cpp
+++ b/test_coding_rules.cpp
@@ -929,7 +929,6 @@ bool check_reserved_name_exception(std::string const& s)
         ,"_IOFBF"
         ,"_IOLBF"
         ,"_IONBF"
-        ,"__DATE__"
         ,"__FILE__"
         ,"__LINE__"
         ,"__STDC_IEC_559__"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]