[packages/gnotify] - fixed build, release 4
qboosh
qboosh at pld-linux.org
Sun Aug 31 20:01:24 CEST 2025
commit 07fb33063fb67fd531bb27fb501f639a5eb03401
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sun Aug 31 20:03:29 2025 +0200
- fixed build, release 4
gnotify-format.patch | 11 +++++++++++
gnotify-optflags.patch | 11 +++++++++++
gnotify.spec | 27 +++++++++++++++++----------
3 files changed, 39 insertions(+), 10 deletions(-)
---
diff --git a/gnotify.spec b/gnotify.spec
index 51655d3..2923f03 100644
--- a/gnotify.spec
+++ b/gnotify.spec
@@ -2,7 +2,7 @@ Summary: GNotify - a notification-service for Desktop-Environments
Summary(pl.UTF-8): GNotify - usługa powiadamiania dla środowisk graficznych
Name: gnotify
Version: 1.2
-Release: 3
+Release: 4
Epoch: 1
License: GPL
Group: X11/Applications
@@ -11,6 +11,7 @@ Source0: https://downloads.sourceforge.net/gnotify/%{name}-%{version}.tar.gz
Source1: %{name}.xml
Patch0: %{name}-clean.patch
Patch1: %{name}-optflags.patch
+Patch2: %{name}-format.patch
URL: https://gnotify.sourceforge.net/
BuildRequires: autoconf
BuildRequires: automake
@@ -36,7 +37,9 @@ oraz zarządców okien.
%setup -q
%patch -P0 -p1
%patch -P1 -p1
-rm -f {COPYING,INSTALL,mkinstalldirs}
+%patch -P2 -p1
+# symlinks, to replace by automake
+%{__rm} COPYING INSTALL install-sh missing mkinstalldirs
%build
%{__libtoolize}
@@ -44,23 +47,27 @@ rm -f {COPYING,INSTALL,mkinstalldirs}
%{__autoconf}
%{__autoheader}
%{__automake}
+# gnotify.h is missing externs, some of them never defined in .c - use -fcommon for now
+CFLAGS="%{rpmcflags} -fcommon"
%configure
-%{__make} \
- CFLAGS="%{rpmcflags}" \
- LDFLAGS="%{rpmldflags} -lpthread"
+%{__make}
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_mandir}/man1,%{_sysconfdir}}
-gzip -dc gnotify.1.gz > $RPM_BUILD_ROOT%{_mandir}/man1/gnotify.1
-install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
-
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
-# not neccessary?
-rm -r $RPM_BUILD_ROOT%{_includedir}/GNotify
+# missing from make install
+gzip -dc gnotify.1.gz > $RPM_BUILD_ROOT%{_mandir}/man1/gnotify.1
+
+cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
+
+# no API, useless
+%{__rm} -r $RPM_BUILD_ROOT%{_includedir}/GNotify
+# packaged as %doc
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/gnotify
%clean
rm -rf $RPM_BUILD_ROOT
diff --git a/gnotify-format.patch b/gnotify-format.patch
new file mode 100644
index 0000000..d18d799
--- /dev/null
+++ b/gnotify-format.patch
@@ -0,0 +1,11 @@
+--- gnotify-1.2/src/gnotify_gtk.c.orig 2004-08-31 13:35:18.000000000 +0200
++++ gnotify-1.2/src/gnotify_gtk.c 2025-08-31 19:56:44.220702846 +0200
+@@ -202,7 +202,7 @@ void gnotify_about(void)
+ void showmessage(int type, int buttons, char *text)
+ {
+ GtkWidget *msg;
+- msg=gtk_message_dialog_new(NULL,GTK_DIALOG_DESTROY_WITH_PARENT,type,buttons,text);
++ msg=gtk_message_dialog_new(NULL,GTK_DIALOG_DESTROY_WITH_PARENT,type,buttons,"%s",text);
+ g_signal_connect_swapped(GTK_OBJECT(msg),"response",G_CALLBACK(gtk_widget_destroy),GTK_OBJECT(msg));
+ gtk_widget_show_all(msg);
+ return;
diff --git a/gnotify-optflags.patch b/gnotify-optflags.patch
index 1208aae..95cc952 100644
--- a/gnotify-optflags.patch
+++ b/gnotify-optflags.patch
@@ -11,3 +11,14 @@
bin_PROGRAMS = gnotify
+--- gnotify-1.2/configure.in.orig 2004-08-31 13:35:18.000000000 +0200
++++ gnotify-1.2/configure.in 2025-08-31 19:54:24.286509679 +0200
+@@ -8,8 +8,6 @@ AM_INIT_AUTOMAKE(GNotify, 1.2)
+ AM_CONFIG_HEADER(config.h)
+
+ AC_ISC_POSIX
+-CFLAGS=""
+-AC_SUBST(CFLAGS,$CFLAGS)
+ AC_PROG_CC
+ AM_PROG_CC_STDC
+ AC_HEADER_STDC
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/gnotify.git/commitdiff/be6658efe4dbe734390b15517129f108b97a5e0c
More information about the pld-cvs-commit
mailing list