Source: gnome-system-tools
Version: 3.0.0-9.1ubuntu4
Severity: wishlist
Dear Maintainer,
When building package in Ubuntu it fails to build due to the enabled
-Wincompatible-pointer-types:
shares-tool.c: In function ‘install_packages’:
shares-tool.c:157:72: error: passing argument 2 of ‘gst_packages_install’ from
incompatible pointer type [-Wincompatible-pointer-types]
157 | retval = gst_packages_install (GTK_WINDOW (tool->main_dialog),
packages);
|
^~~~~~~~
|
|
|
gchar ** {aka char **}
In file included from ../../src/common/gst.h:3,
from users-table.h:27,
from shares-tool.c:23:
../../src/common/gst-package.h:31:64: note: expected ‘const char **’ but
argument is of type ‘gchar **’ {aka ‘char **’}
31 | gboolean gst_packages_install (GtkWindow *window, const char
**packages);
| ~~~~~~~~~~~~~^~~~~~~~
make[5]: *** [Makefile:571: shares-tool.o] Error 1
make[5]: Leaving directory '/<<PKGBUILDDIR>>/src/shares'
make[4]: *** [Makefile:621: all-recursive] Error 1
make[4]: Leaving directory '/<<PKGBUILDDIR>>/src/shares'
make[3]: *** [Makefile:408: all-recursive] Error 1
make[3]: Leaving directory '/<<PKGBUILDDIR>>/src'
make[2]: *** [Makefile:538: all-recursive] Error 1
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
make[1]: *** [Makefile:447: all] Error 2
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [/usr/share/cdbs/1/class/makefile.mk:77: debian/stamp-makefile-build]
Error 2
dpkg-buildpackage: error: debian/rules build subprocess returned exit status 2
Would it be possible to consider adding the attached patch to resolve the
issue?
Thank you for considering the patch.
-- System Information:
Debian Release: trixie/sid
APT prefers noble-updates
APT policy: (500, 'noble-updates'), (500, 'noble-security'), (500, 'noble'),
(100, 'noble-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 6.8.0-48-generic (SMP w/32 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_WARN, TAINT_OOT_MODULE,
TAINT_UNSIGNED_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Description: cast char** to const char**
Ubuntu enabled -Wincompatible-pointer-types warning as error causing
the ftbfs.
Author: [email protected]
Bug-Ubuntu:
https://bugs.launchpad.net/ubuntu/+source/gnome-system-tools/+bug/2088127
Forwarded: no
Last-Update: 2024-11-14
--- a/src/shares/shares-tool.c
+++ b/src/shares/shares-tool.c
@@ -154,7 +154,7 @@
if (install_smb)
packages[i++] = g_strdup ("samba");
- retval = gst_packages_install (GTK_WINDOW (tool->main_dialog),
packages);
+ retval = gst_packages_install (GTK_WINDOW (tool->main_dialog), (const
gchar**) packages);
g_strfreev (packages);
return retval;