]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
dbus: Move DBUS_PRIVATE_EXPORT to private header
authorSimon McVittie <smcv@collabora.com>
Thu, 21 Apr 2022 13:38:55 +0000 (14:38 +0100)
committerRalf Habacker <ralf.habacker@freenet.de>
Sun, 1 May 2022 16:28:51 +0000 (16:28 +0000)
Unlike the rest of the macros in dbus-macros.h, this one would never
have made sense to use in a public header.

Signed-off-by: Simon McVittie <smcv@collabora.com>
dbus/dbus-macros-internal.h
dbus/dbus-macros.h
dbus/dbus-uuidgen.h

index d98891a8e41b05ad60979324059eb5dea15cb7be..5da73c26ef9d11380a919e38ceb5b5087c28b028 100644 (file)
@@ -1,5 +1,6 @@
 /*
- * Copyright © 2019 Collabora Ltd.
+ * Copyright © 2010-2015 Ralf Habacker
+ * Copyright © 2015-2019 Collabora Ltd.
  * SPDX-License-Identifier: AFL-2.1 or GPL-2.0-or-later
  *
  * Licensed under the Academic Free License version 2.1
 # define DBUS_EMBEDDED_TESTS_EXPORT /* nothing */
 #endif
 
+#if defined(DBUS_PRIVATE_EXPORT)
+  /* value forced by compiler command line, don't redefine */
+#elif defined(_WIN32)
+#  if defined(DBUS_STATIC_BUILD)
+#    define DBUS_PRIVATE_EXPORT /* no decoration */
+#  elif defined(dbus_1_EXPORTS)
+#    define DBUS_PRIVATE_EXPORT __declspec(dllexport)
+#  else
+#    define DBUS_PRIVATE_EXPORT __declspec(dllimport)
+#  endif
+#elif defined(__GNUC__) && __GNUC__ >= 4
+#  define DBUS_PRIVATE_EXPORT __attribute__ ((__visibility__ ("default")))
+#else
+#  define DBUS_PRIVATE_EXPORT /* no decoration */
+#endif
+
 #endif
index 80faed294cab9b0bf920d8d13b61856f3867ffbc..2dd9fcd38812b10aaa3d941dec76af730185c249 100644 (file)
 #define DBUS_EXPORT
 #endif
 
-#if defined(DBUS_PRIVATE_EXPORT)
-  /* value forced by compiler command line, don't redefine */
-#elif defined(_WIN32)
-#  if defined(DBUS_STATIC_BUILD)
-#    define DBUS_PRIVATE_EXPORT /* no decoration */
-#  elif defined(dbus_1_EXPORTS)
-#    define DBUS_PRIVATE_EXPORT __declspec(dllexport)
-#  else
-#    define DBUS_PRIVATE_EXPORT __declspec(dllimport)
-#  endif
-#elif defined(__GNUC__) && __GNUC__ >= 4
-#  define DBUS_PRIVATE_EXPORT __attribute__ ((__visibility__ ("default")))
-#else
-#  define DBUS_PRIVATE_EXPORT /* no decoration */
-#endif
-
 /* Implementation for dbus_clear_message() etc. This is not API,
  * do not use it directly.
  *
index bf07b1394928bf9fc52acf0fa13841c448f4a57e..bd098b038fed3fd81ec07c031d3eace3fde27231 100644 (file)
@@ -27,6 +27,7 @@
 #ifndef DBUS_UUIDGEN_H
 #define DBUS_UUIDGEN_H
 
+#include <dbus/dbus-macros-internal.h>
 #include <dbus/dbus-types.h>
 #include <dbus/dbus-errors.h>