Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 932303
Collapse All | Expand All

(-)a/xfce-base/xfce4-panel/Manifest (+1 lines)
Line 0 Link Here
1
DIST xfce4-panel-4.19.4.tar.bz2 2237827 BLAKE2B 2f302a665c875cebf3d1017b13b658654bc9c0f1d498bc55e6d1fde036f2919759a9a77cbd06567796c43f34ce27d198391c10eed3c40907626a275e788e4b19 SHA512 c02d20931ec53817676a7c1c48b91075d79fbfd64ca0ecfe8d581d4206e86d7fb4893bcb8c2bd1e1bdf5040da0077e82a51988681928327fc791232af134fc8b
(-)a/xfce-base/xfce4-panel/files/math-includes.patch (+150 lines)
Line 0 Link Here
1
Gentoo bug https://bugs.gentoo.org/932303
2
3
From fcee4201e254a417f8146723b24ce0716840c96b Mon Sep 17 00:00:00 2001
4
From: Nicholas Vinson <nvinson234@gmail.com>
5
Date: Tue, 21 May 2024 01:10:10 +0200
6
Subject: [PATCH] build: Add missing math.h includes
7
8
Commit 0f786ce451297f8d26d41dc8492c10db08d8f87f added a math.h include
9
statement to libxfce4panel/xfce-panel-image.c to fix issue #833.
10
However, libm functions are used in more files than just
11
xfce-panel-image.c.
12
13
Therefore, add math.h include to other files that use math functions.
14
15
Signed-off-by: Nicholas Vinson <nvinson234 at gmail.com>
16
Fixes: https://bugs.gentoo.org/932303
17
---
18
 panel/panel-base-window.c        | 4 +++-
19
 panel/panel-itembar.c            | 4 ++++
20
 panel/panel-preferences-dialog.c | 4 +++-
21
 plugins/clock/clock-analog.c     | 4 ++++
22
 plugins/clock/clock-binary.c     | 4 +++-
23
 plugins/clock/clock-lcd.c        | 4 ++++
24
 plugins/clock/clock.c            | 4 ++++
25
 plugins/systray/systray-box.c    | 4 ++++
26
 8 files changed, 29 insertions(+), 3 deletions(-)
27
28
diff --git a/panel/panel-base-window.c b/panel/panel-base-window.c
29
index 5e0f3a688..832520be6 100644
30
--- a/panel/panel-base-window.c
31
+++ b/panel/panel-base-window.c
32
@@ -35,7 +35,9 @@
33
 #define gtk_layer_is_supported() FALSE
34
 #endif
35
 
36
-
37
+#ifdef HAVE_MATH_H
38
+#include <math.h>
39
+#endif
40
 
41
 #define PANEL_BASE_CSS ".xfce4-panel.background { border-style: solid; }" \
42
                        ".xfce4-panel.background button { background: transparent; padding: 0; }" \
43
diff --git a/panel/panel-itembar.c b/panel/panel-itembar.c
44
index 4ffcb5ba4..11ccf5d1d 100644
45
--- a/panel/panel-itembar.c
46
+++ b/panel/panel-itembar.c
47
@@ -29,6 +29,10 @@
48
 #include "libxfce4panel/libxfce4panel.h"
49
 #include "libxfce4panel/xfce-panel-plugin-provider.h"
50
 
51
+#ifdef HAVE_MATH_H
52
+#include <math.h>
53
+#endif
54
+
55
 #define IS_HORIZONTAL(itembar) ((itembar)->mode == XFCE_PANEL_PLUGIN_MODE_HORIZONTAL)
56
 #define HIGHLIGHT_SIZE 2
57
 
58
diff --git a/panel/panel-preferences-dialog.c b/panel/panel-preferences-dialog.c
59
index 9a54e9ab3..dfcc67db3 100644
60
--- a/panel/panel-preferences-dialog.c
61
+++ b/panel/panel-preferences-dialog.c
62
@@ -37,7 +37,9 @@
63
 #include <libxfce4ui/libxfce4ui.h>
64
 #include <libxfce4util/libxfce4util.h>
65
 
66
-
67
+#ifdef HAVE_MATH_H
68
+#include<math.h>
69
+#endif
70
 
71
 static void
72
 panel_preferences_dialog_finalize (GObject *object);
73
diff --git a/plugins/clock/clock-analog.c b/plugins/clock/clock-analog.c
74
index ae4ae21f4..50196352d 100644
75
--- a/plugins/clock/clock-analog.c
76
+++ b/plugins/clock/clock-analog.c
77
@@ -27,6 +27,10 @@
78
 
79
 #include <cairo/cairo.h>
80
 
81
+#ifdef HAVE_MATH_H
82
+#include <math.h>
83
+#endif
84
+
85
 #define CLOCK_SCALE 0.08
86
 #define TICKS_TO_RADIANS(x) (G_PI - (G_PI / 30.0) * (x))
87
 #define HOURS_TO_RADIANS(x, y) (G_PI - (G_PI / 6.0) * (((x) > 12 ? (x) - 12 : (x)) + (y) / 60.0))
88
diff --git a/plugins/clock/clock-binary.c b/plugins/clock/clock-binary.c
89
index 5ac4151af..36fe31c72 100644
90
--- a/plugins/clock/clock-binary.c
91
+++ b/plugins/clock/clock-binary.c
92
@@ -27,7 +27,9 @@
93
 
94
 #include <cairo/cairo.h>
95
 
96
-
97
+#ifdef HAVE_MATH_H
98
+#include <math.h>
99
+#endif
100
 
101
 static void
102
 xfce_clock_binary_set_property (GObject *object,
103
diff --git a/plugins/clock/clock-lcd.c b/plugins/clock/clock-lcd.c
104
index 97e041d58..8b7454dfd 100644
105
--- a/plugins/clock/clock-lcd.c
106
+++ b/plugins/clock/clock-lcd.c
107
@@ -27,6 +27,10 @@
108
 
109
 #include <cairo/cairo.h>
110
 
111
+#ifdef HAVE_MATH_H
112
+#include <math.h>
113
+#endif
114
+
115
 #define RELATIVE_SPACE (0.10)
116
 #define RELATIVE_DIGIT (5 * RELATIVE_SPACE)
117
 #define RELATIVE_DOTS (3 * RELATIVE_SPACE)
118
diff --git a/plugins/clock/clock.c b/plugins/clock/clock.c
119
index 472ff8f17..ee1d4402b 100644
120
--- a/plugins/clock/clock.c
121
+++ b/plugins/clock/clock.c
122
@@ -39,6 +39,10 @@
123
 #include <gtk/gtk.h>
124
 #include <libxfce4ui/libxfce4ui.h>
125
 
126
+#ifdef HAVE_MATH_H
127
+#include <math.h>
128
+#endif
129
+
130
 /* TRANSLATORS: adjust this accordingly for your locale format */
131
 #define DEFAULT_TOOLTIP_FORMAT NC_ ("Date", "%A %d %B %Y")
132
 
133
diff --git a/plugins/systray/systray-box.c b/plugins/systray/systray-box.c
134
index 1fc22c925..f808acb97 100644
135
--- a/plugins/systray/systray-box.c
136
+++ b/plugins/systray/systray-box.c
137
@@ -27,6 +27,10 @@
138
 #include "common/panel-debug.h"
139
 #include "common/panel-private.h"
140
 
141
+#ifdef HAVE_MATH_H
142
+#include <math.h>
143
+#endif
144
+
145
 #define SPACING (2)
146
 #define OFFSCREEN (-9999)
147
 
148
-- 
149
GitLab
150
(-)a/xfce-base/xfce4-panel/xfce4-panel-4.19.4.ebuild (+88 lines)
Line 0 Link Here
1
# Copyright 1999-2024 Gentoo Authors
2
# Distributed under the terms of the GNU General Public License v2
3
4
EAPI=8
5
6
inherit vala xdg-utils
7
8
DESCRIPTION="Panel for the Xfce desktop environment"
9
HOMEPAGE="
10
	https://docs.xfce.org/xfce/xfce4-panel/start
11
	https://gitlab.xfce.org/xfce/xfce4-panel/
12
"
13
SRC_URI="https://archive.xfce.org/src/xfce/${PN}/${PV%.*}/${P}.tar.bz2"
14
15
LICENSE="GPL-2+ LGPL-2.1+"
16
SLOT="0"
17
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
18
IUSE="+dbusmenu introspection vala wayland X"
19
REQUIRED_USE="
20
	|| ( wayland X )
21
	vala? ( introspection )
22
"
23
24
DEPEND="
25
	>=dev-libs/glib-2.72.0
26
	>=x11-libs/cairo-1.16.0
27
	>=x11-libs/gtk+-3.24.0:3[X?,introspection?,wayland?]
28
	>=xfce-base/exo-0.11.2:=
29
	>=xfce-base/garcon-4.17.0:=
30
	>=xfce-base/libxfce4ui-4.17.1:=
31
	>=xfce-base/libxfce4util-4.17.2:=[introspection?,vala?]
32
	>=xfce-base/libxfce4windowing-4.19.3:=[X?]
33
	>=xfce-base/xfconf-4.13.2:=
34
	dbusmenu? ( >=dev-libs/libdbusmenu-16.04.0[gtk3] )
35
	introspection? ( >=dev-libs/gobject-introspection-1.66:= )
36
	wayland? (
37
		>=dev-libs/wayland-1.15
38
		>=gui-libs/gtk-layer-shell-0.7.0
39
	)
40
	X? (
41
		>=x11-libs/libX11-1.6.7
42
		x11-libs/libwnck:3
43
	)
44
"
45
RDEPEND="
46
	${DEPEND}
47
"
48
BDEPEND="
49
	vala? ( $(vala_depend) )
50
	dev-lang/perl
51
	dev-util/gdbus-codegen
52
	dev-util/intltool
53
	sys-devel/gettext
54
	virtual/pkgconfig
55
"
56
57
PATCHES=(
58
	${FILESDIR}/math-includes.patch
59
)
60
61
src_configure() {
62
	local myconf=(
63
		$(use_enable introspection)
64
		$(use_enable dbusmenu dbusmenu-gtk3)
65
		$(use_enable vala)
66
		$(use_enable wayland)
67
		$(use_enable wayland gtk-layer-shell)
68
		$(use_enable X x11)
69
	)
70
71
	use vala && vala_setup
72
	econf "${myconf[@]}"
73
}
74
75
src_install() {
76
	default
77
	find "${D}" -name '*.la' -delete || die
78
}
79
80
pkg_postinst() {
81
	xdg_icon_cache_update
82
	xdg_desktop_database_update
83
}
84
85
pkg_postrm() {
86
	xdg_icon_cache_update
87
	xdg_desktop_database_update
88
}

Return to bug 932303