summaryrefslogtreecommitdiff
path: root/glib
diff options
context:
space:
mode:
authorKjell Ahlstedt <kjell.ahlstedt@bredband.net>2015-06-17 18:28:35 +0200
committerKjell Ahlstedt <kjell.ahlstedt@bredband.net>2015-06-17 18:28:35 +0200
commitc64c404259b74898bc14fd2c06fccef9fe2cfcbf (patch)
tree68a9803f9a0cb4867c2329c7327e56c66578223f /glib
parente021103113aa73cc4016424ac028387f5834522e (diff)
downloadglibmm-c64c404259b74898bc14fd2c06fccef9fe2cfcbf.tar.gz
Glib::Thread: Don't disable more deprecation warnings than necessary
* glib/src/thread.hg: Don't define GLIB_DISABLE_DEPRECATION_WARNINGS in the .h file, only in the .cc file. If it's defined in the .h file, it disables warnings in every file that includes glibmm/thread.h or glibmm.h. Don't include <glibmmconfig.h> in the .cc file. It became unnecessary when thread.hg was added to glibmm_files_deprecated_hg in glib/src/filelist.am. Bug #750379.
Diffstat (limited to 'glib')
-rw-r--r--glib/src/thread.hg12
1 files changed, 2 insertions, 10 deletions
diff --git a/glib/src/thread.hg b/glib/src/thread.hg
index fb6f19b7..dd116c35 100644
--- a/glib/src/thread.hg
+++ b/glib/src/thread.hg
@@ -21,23 +21,16 @@ _CONFIGINCLUDE(glibmmconfig.h)
_IS_DEPRECATED // This whole file is deprecated.
#m4 _PUSH(SECTION_CC_PRE_INCLUDES)
-// Must be included in the .cc file before the generated #ifndef GLIBMM_DISABLE_DEPRECATED,
-// or else "configure --disable-deprecated-api" + "make" will fail.
-#include <glibmmconfig.h>
+//Stop the compiler warnings about using the deprecated API;
+#define GLIB_DISABLE_DEPRECATION_WARNINGS 1
#m4 _POP()
// We use GThreadFunctions in the (deprecated) API, so we must temporarily undef G_DISABLE_DEPRECATED.
// Temporarily undef G_DISABLE_DEPRECATED, redefining it later if appropriate.
#if defined(G_DISABLE_DEPRECATED) && !defined(GLIBMM_G_DISABLE_DEPRECATED_UNDEFED)
-
//Stop the deprecation ifdef guards around the API declarations:
#undef G_DISABLE_DEPRECATED
-
-//Stop the compiler warnings about using the deprecated API;
-#define GLIB_DISABLE_DEPRECATION_WARNINGS 1
-
#define GLIBMM_G_DISABLE_DEPRECATED_UNDEFED 1
-
#endif
#include <glib.h>
@@ -45,7 +38,6 @@ _IS_DEPRECATED // This whole file is deprecated.
// Redefine G_DISABLE_DEPRECATED if it was defined before we temporarily undefed it:
#if defined(GLIBMM_G_DISABLE_DEPRECATED_UNDEFED)
#define G_DISABLE_DEPRECATED 1
-#undef GLIB_DISABLE_DEPRECATION_WARNINGS
#undef GLIBMM_G_DISABLE_DEPRECATED_UNDEFED
#endif