Compare commits

...

No commits in common. 'c9' and 'cs10' have entirely different histories.
c9 ... cs10

2
.gitignore vendored

@ -1 +1 @@
SOURCES/libnotify-0.7.9.tar.xz
SOURCES/libnotify-0.8.3.tar.xz

@ -1 +1 @@
75f80afad4d77b4968bfbcd47f4beea5ac2cc87b SOURCES/libnotify-0.7.9.tar.xz
857d860f38f1e4dfb78d54c1c8ffeb4caf709b7d SOURCES/libnotify-0.8.3.tar.xz

@ -1,139 +0,0 @@
From 390500fc0c806ed347f76afcfe8a62a74653e81b Mon Sep 17 00:00:00 2001
From: Ray Strode <rstrode@redhat.com>
Date: Tue, 12 May 2020 10:12:26 -0400
Subject: [PATCH] notify-send: Give failing exit code if showing notification
fails
Right now notify-send will quietly return a successful exit status
even if showing the notification fails.
This commit changes the behavior to instead fail on failure.
https://gitlab.gnome.org/GNOME/libnotify/-/merge_requests/13
---
tools/notify-send.c | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/tools/notify-send.c b/tools/notify-send.c
index 67e0b03..52fa46a 100644
--- a/tools/notify-send.c
+++ b/tools/notify-send.c
@@ -105,61 +105,61 @@ notify_notification_set_hint_variant (NotifyNotification *notification,
N_("Invalid hint type \"%s\". Valid types "
"are int, double, string and byte."),
type);
return FALSE;
}
if (conv_error) {
*error = g_error_new (G_OPTION_ERROR,
G_OPTION_ERROR_BAD_VALUE,
N_("Value \"%s\" of hint \"%s\" could not be "
"parsed as type \"%s\"."), value, key,
type);
return FALSE;
}
return TRUE;
}
int
main (int argc, char *argv[])
{
static const char *summary = NULL;
char *body;
static const char *type = NULL;
static char *app_name = NULL;
static char *icon_str = NULL;
static char *icons = NULL;
static char **n_text = NULL;
static char **hints = NULL;
static gboolean do_version = FALSE;
- static gboolean hint_error = FALSE;
+ static gboolean hint_error = FALSE, show_error = FALSE;
static glong expire_timeout = NOTIFY_EXPIRES_DEFAULT;
GOptionContext *opt_ctx;
NotifyNotification *notify;
GError *error = NULL;
gboolean retval;
static const GOptionEntry entries[] = {
{"urgency", 'u', 0, G_OPTION_ARG_CALLBACK,
g_option_arg_urgency_cb,
N_("Specifies the urgency level (low, normal, critical)."),
N_("LEVEL")},
{"expire-time", 't', 0, G_OPTION_ARG_INT, &expire_timeout,
N_
("Specifies the timeout in milliseconds at which to expire the "
"notification."), N_("TIME")},
{"app-name", 'a', 0, G_OPTION_ARG_STRING, &app_name,
N_("Specifies the app name for the icon"), N_("APP_NAME")},
{"icon", 'i', 0, G_OPTION_ARG_FILENAME, &icons,
N_("Specifies an icon filename or stock icon to display."),
N_("ICON[,ICON...]")},
{"category", 'c', 0, G_OPTION_ARG_FILENAME, &type,
N_("Specifies the notification category."),
N_("TYPE[,TYPE...]")},
{"hint", 'h', 0, G_OPTION_ARG_FILENAME_ARRAY, &hints,
N_
("Specifies basic extra data to pass. Valid types are int, double, string and byte."),
N_("TYPE:NAME:VALUE")},
{"version", 'v', 0, G_OPTION_ARG_NONE, &do_version,
N_("Version of the package."),
NULL},
@@ -247,39 +247,49 @@ main (int argc, char *argv[])
while ((hint = hints[i++])) {
tokens = g_strsplit (hint, ":", 3);
l = g_strv_length (tokens);
if (l != 3) {
fprintf (stderr, "%s\n",
N_("Invalid hint syntax specified. "
"Use TYPE:NAME:VALUE."));
hint_error = TRUE;
} else {
retval = notify_notification_set_hint_variant (notify,
tokens[0],
tokens[1],
tokens[2],
&error);
if (!retval) {
fprintf (stderr, "%s\n", error->message);
g_error_free (error);
hint_error = TRUE;
}
}
g_strfreev (tokens);
if (hint_error)
break;
}
}
- if (!hint_error)
- notify_notification_show (notify, NULL);
+ if (!hint_error) {
+ retval = notify_notification_show (notify, &error);
+
+ if (!retval) {
+ fprintf (stderr, "%s\n", error->message);
+ g_error_free (error);
+ show_error = TRUE;
+ }
+ }
g_object_unref (G_OBJECT (notify));
notify_uninit ();
- exit (hint_error);
+ if (hint_error || show_error)
+ exit (1);
+
+ return 0;
}
--
2.33.1

@ -0,0 +1,225 @@
From b0f7fc9293e6ee2d42ebd85ac6c1c8fe15353a8a Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Wed, 17 Jul 2024 11:00:42 +0200
Subject: [PATCH] drop-docbook5-style-xsl.patch
---
docs/meson.build | 7 +--
docs/notify-send.1 | 141 +++++++++++++++++++++++++++++++++++++++++++++
meson.build | 21 -------
meson_options.txt | 2 +-
4 files changed, 143 insertions(+), 28 deletions(-)
create mode 100644 docs/notify-send.1
diff --git a/docs/meson.build b/docs/meson.build
index 4c5ba64..bd44664 100644
--- a/docs/meson.build
+++ b/docs/meson.build
@@ -30,11 +30,6 @@ if get_option('man')
manpages = ['notify-send']
foreach page : manpages
- custom_target(page + '-man',
- input: page + '.xml',
- output: page + '.1',
- command: xsltproc_command,
- install: true,
- install_dir: man1dir)
+ install_man(page + '.1')
endforeach
endif
diff --git a/docs/notify-send.1 b/docs/notify-send.1
new file mode 100644
index 0000000..fb58424
--- /dev/null
+++ b/docs/notify-send.1
@@ -0,0 +1,141 @@
+'\" t
+.\" Title: notify-send
+.\" Author: Andre Filipe de Assuncao e Brito <decko@noisemakers.org>
+.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
+.\" Date: November 2005
+.\" Manual: User Commands
+.\" Source: libnotify
+.\" Language: English
+.\"
+.TH "NOTIFY\-SEND" "1" "" "libnotify" "User Commands"
+.\" -----------------------------------------------------------------
+.\" * Define some portability stuff
+.\" -----------------------------------------------------------------
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.\" http://bugs.debian.org/507673
+.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.ie \n(.g .ds Aq \(aq
+.el .ds Aq '
+.\" -----------------------------------------------------------------
+.\" * set default formatting
+.\" -----------------------------------------------------------------
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
+.\" -----------------------------------------------------------------
+.\" * MAIN CONTENT STARTS HERE *
+.\" -----------------------------------------------------------------
+.SH "NAME"
+notify-send \- a program to send desktop notifications
+.SH "SYNOPSIS"
+.HP \w'\fBnotify\-send\fR\ 'u
+\fBnotify\-send\fR [\fIOPTIONS\fR] {\fIsummary\fR} [\fIbody\fR]
+.SH "DESCRIPTION"
+.PP
+With
+\fBnotify\-send\fR
+you can send desktop notifications to the user via a notification daemon from the command line\&. These notifications can be used to inform the user about an event or display some form of information without getting in the user\(cqs way\&.
+.SH "OPTIONS"
+.PP
+\fB\-?\fR, \fB\-\-help\fR
+.RS 4
+Show help and exit\&.
+.RE
+.PP
+\fB\-a\fR, \fB\-\-app\-name\fR=\fIAPP_NAME\fR
+.RS 4
+Specifies the app name for the notification\&.
+.RE
+.PP
+\fB\-A\fR, \fB\-\-action\fR=[\fINAME\fR=]\fIText\&.\&.\&.\fR
+.RS 4
+Specifies the actions to display to the user\&. Implies
+\fB\-\-wait\fR
+to wait for user input\&. May be set multiple times\&. The
+\fINAME\fR
+of the action is output to
+stdout\&. If
+\fINAME\fR
+is not specified, the numerical index of the option is used (starting with
+1)\&.
+.RE
+.PP
+\fB\-u\fR, \fB\-\-urgency\fR=\fILEVEL\fR
+.RS 4
+Specifies the urgency level (low,
+normal,
+critical)\&.
+.RE
+.PP
+\fB\-t\fR, \fB\-\-expire\-time\fR=\fITIME\fR
+.RS 4
+The duration, in milliseconds, for the notification to appear on screen\&.
+.sp
+Not all implementations use this parameter\&. GNOME Shell and Notify OSD always ignore it, while Plasma ignores it for notifications with the critical urgency level\&.
+.RE
+.PP
+\fB\-i\fR, \fB\-\-icon\fR=\fIICON\fR
+.RS 4
+Specifies an icon filename or stock icon to display\&.
+.RE
+.PP
+\fB\-c\fR, \fB\-\-category\fR=\fITYPE\fR[,\fITYPE\fR\&...]
+.RS 4
+Specifies the notification category\&.
+.RE
+.PP
+\fB\-h\fR, \fB\-\-hint\fR=\fITYPE\fR:\fINAME\fR:\fIVALUE\fR
+.RS 4
+Specifies basic extra data to pass\&. Valid types are
+BOOLEAN,
+INT,
+DOUBLE,
+STRING,
+BYTE
+and
+VARIANT\&.
+.RE
+.PP
+\fB\-p\fR, \fB\-\-print\-id\fR
+.RS 4
+Print the notification ID\&.
+.RE
+.PP
+\fB\-r\fR, \fB\-\-replace\-id\fR=\fIREPLACE_ID\fR
+.RS 4
+The ID of the notification to replace\&.
+.RE
+.PP
+\fB\-w\fR, \fB\-\-wait\fR
+.RS 4
+Wait for the notification to be closed before exiting\&. If the
+\fBexpire\-time\fR
+is set, it will be used as the maximum waiting time\&.
+.RE
+.PP
+\fB\-e\fR, \fB\-\-transient\fR
+.RS 4
+Show a transient notification\&. Transient notifications by\-pass the server\*(Aqs persistence capability, if any\&. And so it won\*(Aqt be preserved until the user acknowledges it\&.
+.RE
+.SH "SEE ALSO"
+.PP
+The Desktop Notification Spec on
+\m[blue]\fBhttps://specifications\&.freedesktop\&.org/notification\-spec/\fR\m[]\&.
+.SH "AUTHORS"
+.PP
+\fBAndre Filipe de Assuncao e Brito\fR <\&decko@noisemakers\&.org\&>
+.RS 4
+Original author
+.RE
+.PP
+\fBPaul van Tilburg\fR <\&paulvt@debian\&.org\&>
+.RS 4
+Original author
+.RE
+.PP
+\fBRiccardo Setti\fR <\&giskard@debian\&.org\&>
+.RS 4
+Original author
+.RE
diff --git a/meson.build b/meson.build
index 82e796a..9c3fe81 100644
--- a/meson.build
+++ b/meson.build
@@ -55,27 +55,6 @@ configure_file(input: 'config.h.meson',
output : 'config.h',
configuration : conf)
-if get_option('man')
- xsltproc = find_program('xsltproc', required: true)
- stylesheet = 'http://docbook.sourceforge.net/release/xsl-ns/current/manpages/docbook.xsl'
- xsltproc_command = [
- xsltproc,
- '--nonet',
- '--stringparam', 'man.output.quietly', '1',
- '--stringparam', 'funcsynopsis.style', 'ansi',
- '--stringparam', 'man.th.extra1.suppress', '1',
- '-o', '@OUTPUT@',
- stylesheet,
- '@INPUT@',
- ]
-
- testrun = run_command(xsltproc, '--nonet', stylesheet, check: false)
-
- if testrun.returncode() != 0
- error('DocBook stylesheet for generating man pages not found, you need to install docbook-xsl-ns or similar package.')
- endif
-endif
-
subdir('libnotify')
subdir('tools')
subdir('docs')
diff --git a/meson_options.txt b/meson_options.txt
index d20d16d..fb0f005 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -9,7 +9,7 @@ option('introspection',
option('man',
type: 'boolean',
value: true,
- description: 'Enable generating the manual page (depends on xsltproc)')
+ description: 'Install the manual page')
option('gtk_doc',
type: 'boolean',
value: true,
--
2.45.1

@ -1,26 +0,0 @@
From 34bf541f11b57995a019731e5a8d328422458bd3 Mon Sep 17 00:00:00 2001
From: David King <amigadave@amigadave.com>
Date: Mon, 13 Dec 2021 15:20:32 +0000
Subject: [PATCH] docs: Use consistent IDs in spec build
This avoids differences between IDs for separate builds of the
specification.
https://bugzilla.redhat.com/show_bug.cgi?id=1915831
---
docs/config.xsl | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/config.xsl b/docs/config.xsl
index 7aa9def..59490e7 100644
--- a/docs/config.xsl
+++ b/docs/config.xsl
@@ -3,4 +3,5 @@
xmlns:fo="http://www.w3.org/1999/XSL/Format"
version="1.0">
<xsl:param name="html.stylesheet" select="'docbook.css'"/>
+ <xsl:param name="generate.consistent.ids" select="1"/>
</xsl:stylesheet>
--
2.33.1

@ -1,31 +1,25 @@
%define glib2_version 2.26.0
Name: libnotify
Version: 0.7.9
Release: 8%{?dist}
Summary: Desktop notification library
License: LGPLv2+
URL: http://www.gnome.org
Source0: http://ftp.gnome.org/pub/GNOME/sources/libnotify/0.7/%{name}-%{version}.tar.xz
# https://bugzilla.redhat.com/show_bug.cgi?id=1915831#
# https://bugzilla.redhat.com/show_bug.cgi?id=1915831#
# https://bugzilla.redhat.com/show_bug.cgi?id=1915831
Patch10001: libnotify-0.7.9-consistent-ids.patch
Patch20001: 0001-notify-send-Give-failing-exit-code-if-showing-notifi.patch
BuildRequires: docbook-xsl-ns
BuildRequires: gdk-pixbuf2-devel
BuildRequires: glib2-devel >= %{glib2_version}
BuildRequires: gobject-introspection-devel
BuildRequires: gtk3-devel
BuildRequires: gtk-doc
BuildRequires: meson
BuildRequires: xmlto
BuildRequires: /usr/bin/xsltproc
Requires: glib2%{?_isa} >= %{glib2_version}
%define glib2_version 2.38.0
Name: libnotify
Version: 0.8.3
Release: 6%{?dist}
Summary: Desktop notification library
License: LGPL-2.1-or-later
URL: https://gitlab.gnome.org/GNOME/libnotify
Source0: https://download.gnome.org/sources/libnotify/0.8/%{name}-%{version}.tar.xz
Patch0: drop-docbook5-style-xsl.patch
BuildRequires: pkgconfig(gdk-pixbuf-2.0)
BuildRequires: pkgconfig(glib-2.0) >= %{glib2_version}
BuildRequires: pkgconfig(gobject-introspection-1.0)
BuildRequires: gi-docgen
BuildRequires: meson
BuildRequires: xmlto
BuildRequires: /usr/bin/xsltproc
Requires: glib2%{?_isa} >= %{glib2_version}
%description
libnotify is a library for sending desktop notifications to a notification
@ -33,11 +27,11 @@ daemon, as defined in the freedesktop.org Desktop Notifications spec. These
notifications can be used to inform the user about an event or display some
form of information without getting in the user's way.
%package devel
%package devel
Summary: Development files for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel
%description devel
This package contains libraries and header files needed for
development of programs using %{name}.
@ -45,17 +39,15 @@ development of programs using %{name}.
%autosetup -p1
%build
%meson
%meson -Dtests=false
%meson_build
%install
%meson_install
%ldconfig_scriptlets
%files
%license COPYING
%doc NEWS AUTHORS
%doc NEWS AUTHORS README.md
%{_bindir}/notify-send
%{_libdir}/libnotify.so.*
%{_libdir}/girepository-1.0/Notify-0.7.typelib
@ -66,25 +58,62 @@ development of programs using %{name}.
%{_includedir}/libnotify/*
%{_libdir}/libnotify.so
%{_libdir}/pkgconfig/libnotify.pc
%dir %{_datadir}/gtk-doc/html/libnotify
%{_datadir}/gtk-doc/html/libnotify/*
%{_datadir}/gir-1.0/Notify-0.7.gir
%{_docdir}/libnotify-0/
%doc %{_docdir}/libnotify/spec/
%changelog
* Wed Dec 22 2021 Ray Strode <rstrode@redhat.com> - 0.7.9-8
- Make notify-send return failure when it fails
Resolves: #2017158
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 0.8.3-6
- Bump release for October 2024 mass rebuild:
Resolves: RHEL-64018
* Wed Jul 17 2024 Tomas Popela <tpopela@redhat.com> - 0.8.3-5
- Drop the requirement on docbook5-style-xsl as it will be removed from RHEL.
As it was used to build the man page, add the man page in the native format.
- Resolves: RHEL-45565
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 0.8.3-4
- Bump release for June 2024 mass rebuild
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sat Oct 21 2023 Kalev Lember <klember@redhat.com> - 0.8.3-1
- Update to 0.8.3
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Mon Feb 20 2023 David King <amigadave@amigadave.com> - 0.8.2-1
- Update to 0.8.2
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Mon Jul 18 2022 Kalev Lember <klember@redhat.com> - 0.8.1-1
- Update to 0.8.1
* Thu May 05 2022 David King <amigadave@amigadave.com> - 0.7.12-1
- Update to 0.7.12
* Thu Apr 28 2022 David King <amigadave@amigadave.com> - 0.7.11-1
- Update to 0.7.11
* Mon Dec 13 2021 David King <amigadave@amigadave.com> - 0.7.9-7
- Fix inconsistent IDs in specification (#1915831)
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.9-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 0.7.9-6
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Tue Dec 14 2021 David King <amigadave@amigadave.com> - 0.7.9-6
- Use pkgconfig for BuildRequires
- Disable building unused tests
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.7.9-5
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.9-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.9-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild

Loading…
Cancel
Save