aboutsummaryrefslogtreecommitdiffstats
path: root/meta-agl-profile-graphical/recipes-graphics/wayland/waltham/0001-waltham-Fix-compile-build-error.patch
blob: 354bcbc1570fcb10f4b7edbae817165d7e71cce0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
From cc87dddc2cdc0c20b053e3da1197efd671b4f50c Mon Sep 17 00:00:00 2001
From: Marius Vlad <marius.vlad@collabora.com>
Date: Wed, 23 Sep 2020 22:33:50 +0300
Subject: [PATCH 1/2] waltham: Fix compile build error

Newer compilers will complain about the fact debug_message is declared
multiple times:

multiple definition of `debug_message';
.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35:
first defined here multiple definition of `debug_message';
.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35:
first defined here /usr/bin/ld:
.libs/client-serialice.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35:
multiple definition of `debug_message';
.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35:
first defined here

Bug-AGL: SPEC-3649

Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
---
 src/waltham/marshaller_log.h | 2 +-
 src/waltham/waltham-util.c   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/waltham/marshaller_log.h b/src/waltham/marshaller_log.h
index 8254914..ffa87c1 100644
--- a/src/waltham/marshaller_log.h
+++ b/src/waltham/marshaller_log.h
@@ -32,7 +32,7 @@
 /* Comment/uncomment to disable/enable debugging log */
 #define DEBUG
 //#define PROFILE
-int debug_message;
+extern int debug_message;
 
 #ifdef DEBUG
 static inline void DEBUG_STAMP (void) {
diff --git a/src/waltham/waltham-util.c b/src/waltham/waltham-util.c
index 410b114..8f898f8 100644
--- a/src/waltham/waltham-util.c
+++ b/src/waltham/waltham-util.c
@@ -34,7 +34,7 @@
 #include "waltham-connection.h"
 #include "waltham-private.h"
 
-int debug_message;
+extern int debug_message;
 
 static void
 wth_pfx_print(const char *pfx, const char *fmt, va_list argp)
-- 
2.28.0