Author: cazfi
Date: Tue Mar  1 04:16:16 2016
New Revision: 32141

URL: http://svn.gna.org/viewcvs/freeciv?rev=32141&view=rev
Log:
Made TESTMATIC_ENABLED public in freeciv_config.h under name FREECIV_TESTMATIC

See patch #6950

Modified:
    trunk/common/dataio.c
    trunk/gen_headers/freeciv_config.h.in
    trunk/m4/testmatic.m4
    trunk/server/generator/mapgen.c
    trunk/server/srv_main.c
    trunk/utility/fcbacktrace.c
    trunk/utility/log.h
    trunk/utility/registry_ini.c
    trunk/utility/shared.h

Modified: trunk/common/dataio.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/common/dataio.c?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/common/dataio.c       (original)
+++ trunk/common/dataio.c       Tue Mar  1 04:16:16 2016
@@ -1,4 +1,4 @@
-/********************************************************************** 
+/**********************************************************************
  Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -75,7 +75,7 @@
 /* Uncomment to make field range tests to asserts, fatal with -F */
 #define FIELD_RANGE_ASSERT */
 
-#if defined(TESTMATIC_ENABLED) && !defined(FIELD_RANGE_ASSERT)
+#if defined(FREECIV_TESTMATIC) && !defined(FIELD_RANGE_ASSERT)
 #define FIELD_RANGE_ASSERT
 #endif
 

Modified: trunk/gen_headers/freeciv_config.h.in
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/gen_headers/freeciv_config.h.in?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/gen_headers/freeciv_config.h.in       (original)
+++ trunk/gen_headers/freeciv_config.h.in       Tue Mar  1 04:16:16 2016
@@ -1,4 +1,4 @@
-/********************************************************************** 
+/**********************************************************************
  Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -22,6 +22,9 @@
 
 /* Is this freeciv-web instead of regular build */
 #undef FREECIV_WEB
+
+/* Testmatic integration enabled */
+#undef FREECIV_TESTMATIC
 
 /* Metaserver URL */
 #undef FREECIV_META_URL

Modified: trunk/m4/testmatic.m4
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/m4/testmatic.m4?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/m4/testmatic.m4       (original)
+++ trunk/m4/testmatic.m4       Tue Mar  1 04:16:16 2016
@@ -14,6 +14,6 @@
 esac], [enable_testmatic=no])
 
   if test x$enable_testmatic = xyes ; then
-    AC_DEFINE([TESTMATIC_ENABLED], [1], [Testmatic integration enabled])
+    AC_DEFINE([FREECIV_TESTMATIC], [1], [Testmatic integration enabled])
   fi
 ])

Modified: trunk/server/generator/mapgen.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/server/generator/mapgen.c?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/server/generator/mapgen.c     (original)
+++ trunk/server/generator/mapgen.c     Tue Mar  1 04:16:16 2016
@@ -1261,12 +1261,12 @@
   if (game.map.server.seed_setting == 0) {
     /* Create a "random" map seed. */
     game.map.server.seed = seed_rand & (MAX_UINT32 >> 1);
-#ifdef TESTMATIC_ENABLED
+#ifdef FREECIV_TESTMATIC
     /* Log command to reproduce the mapseed */
     log_testmatic("set mapseed %d", game.map.server.seed);
-#else /* TESTMATICE_ENABLED */
+#else /* FREECIV_TESTMATICE */
     log_debug("Setting map.seed:%d", game.map.server.seed);
-#endif /* TESTMATIC_ENABLED */
+#endif /* FREECIV_TESTMATIC */
   } else {
     game.map.server.seed = game.map.server.seed_setting;
   }

Modified: trunk/server/srv_main.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/server/srv_main.c?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/server/srv_main.c     (original)
+++ trunk/server/srv_main.c     Tue Mar  1 04:16:16 2016
@@ -203,12 +203,12 @@
     /* We strip the high bit for now because neither game file nor
        server options can handle unsigned ints yet. - Cedric */
     game.server.seed = time(NULL) & (MAX_UINT32 >> 1);
-#ifdef TESTMATIC_ENABLED
+#ifdef FREECIV_TESTMATIC
      /* Log command to reproduce the gameseed */
     log_testmatic("set gameseed %d", game.server.seed);
-#else  /* TESTMATIC_ENABLED */
+#else  /* FREECIV_TESTMATIC */
     log_debug("Setting game.seed:%d", game.server.seed);
-#endif /* TESTMATIC_ENABLED */
+#endif /* FREECIV_TESTMATIC */
   } else {
     game.server.seed = game.server.seed_setting;
   }

Modified: trunk/utility/fcbacktrace.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/utility/fcbacktrace.c?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/utility/fcbacktrace.c (original)
+++ trunk/utility/fcbacktrace.c Tue Mar  1 04:16:16 2016
@@ -1,4 +1,4 @@
-/********************************************************************** 
+/**********************************************************************
  Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -28,7 +28,7 @@
 #include "fcbacktrace.h"
 
 /* We don't want backtrace-spam to testmatic logs */
-#if defined(DEBUG) && defined(HAVE_BACKTRACE) && !defined(TESTMATIC_ENABLED)
+#if defined(DEBUG) && defined(HAVE_BACKTRACE) && !defined(FREECIV_TESTMATIC)
 #define BACKTRACE_ACTIVE 1
 #endif
 

Modified: trunk/utility/log.h
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/utility/log.h?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/utility/log.h (original)
+++ trunk/utility/log.h Tue Mar  1 04:16:16 2016
@@ -107,16 +107,16 @@
 #else
 #  define log_debug(message, ...) /* Do nothing. */
 #endif /* FREECIV_DEBUG */
-#ifdef TESTMATIC_ENABLED
+#ifdef FREECIV_TESTMATIC
 #define log_testmatic(message, ...)                                         \
   log_base(LOG_ERROR, message, ## __VA_ARGS__)
 #define log_testmatic_alt(altlvl, message, ...)                             \
   log_base(LOG_ERROR, message, ## __VA_ARGS__)
-#else  /* TESTMATIC_ENABLED */
+#else  /* FREECIV_TESTMATIC */
 #define log_testmatic(message, ...) /* Do nothing. */
 #define log_testmatic_alt(altlvl, message, ...)                             \
   log_base(altlvl, message, ## __VA_ARGS__)
-#endif /* TESTMATIC_ENABLED */
+#endif /* FREECIV_TESTMATIC */
 
 #define log_va_list(level, msg, args)                                       \
   if (log_do_output_for_level(level)) {                                     \

Modified: trunk/utility/registry_ini.c
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/utility/registry_ini.c?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/utility/registry_ini.c        (original)
+++ trunk/utility/registry_ini.c        Tue Mar  1 04:16:16 2016
@@ -913,14 +913,14 @@
                                  secfile->name != NULL ? secfile->name : 
"nameless",
                                  section_name(psection), entry_name(pentry));
         } else {
-#ifdef TESTMATIC_ENABLED
+#ifdef FREECIV_TESTMATIC
           log_testmatic("%s: unused entry: %s.%s",
                         secfile->name != NULL ? secfile->name : "nameless",
                         section_name(psection), entry_name(pentry));
-#else  /* TESTMATIC_ENABLED */
+#else  /* FREECIV_TESTMATIC */
           log_verbose("  unused entry: %s.%s",
                       section_name(psection), entry_name(pentry));
-#endif /* TESTMATIC_ENABLED */
+#endif /* FREECIV_TESTMATIC */
         }
       }
     } entry_list_iterate_end;

Modified: trunk/utility/shared.h
URL: 
http://svn.gna.org/viewcvs/freeciv/trunk/utility/shared.h?rev=32141&r1=32140&r2=32141&view=diff
==============================================================================
--- trunk/utility/shared.h      (original)
+++ trunk/utility/shared.h      Tue Mar  1 04:16:16 2016
@@ -1,4 +1,4 @@
-/********************************************************************** 
+/**********************************************************************
  Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -33,13 +33,13 @@
    another unreachable condition. */
 #define FC_INFINITY            (1000 * 1000 * 1000)
 
-#ifndef TESTMATIC_ENABLED
+#ifndef FREECIV_TESTMATIC
 /* Initialize something for the sole purpose of silencing false compiler 
warning
  * about variable possibly used uninitialized. */
 #define BAD_HEURISTIC_INIT(_ini_val_) = _ini_val_
-#else  /* TESTMATIC_ENABLED */
+#else  /* FREECIV_TESTMATIC */
 #define BAD_HEURISTIC_INIT(_ini_val_)
-#endif /* TESTMATIC_ENABLED */
+#endif /* FREECIV_TESTMATIC */
 
 enum fc_tristate { TRI_NO, TRI_YES, TRI_MAYBE };
 #define BOOL_TO_TRISTATE(tri) ((tri) ? TRI_YES : TRI_NO)


_______________________________________________
Freeciv-commits mailing list
Freeciv-commits@gna.org
https://mail.gna.org/listinfo/freeciv-commits

Reply via email to