mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-05 06:33:50 +02:00
caja-extensions: bump for new gupnp
This commit is contained in:
parent
04de6ed690
commit
01df31e30c
4 changed files with 222 additions and 3 deletions
24
srcpkgs/caja-extensions/patches/1-gtk-radio-button-id.patch
Normal file
24
srcpkgs/caja-extensions/patches/1-gtk-radio-button-id.patch
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
From dac72f1d7b4ab1f24bdc64bd2b3f96bd0e30e489 Mon Sep 17 00:00:00 2001
|
||||||
|
From: David Henry <davi.henry@orange.fr>
|
||||||
|
Date: Fri, 18 Nov 2022 22:28:01 +0000
|
||||||
|
Subject: [PATCH] Fix missing GtkRadioButton id
|
||||||
|
|
||||||
|
Add missing id to custom scale radio button referenced in caja-image-resizer.c
|
||||||
|
This fixes issue #104.
|
||||||
|
---
|
||||||
|
image-converter/caja-image-resize.ui | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/image-converter/caja-image-resize.ui b/image-converter/caja-image-resize.ui
|
||||||
|
index 5fe0ea35..f3bcbce4 100644
|
||||||
|
--- a/image-converter/caja-image-resize.ui
|
||||||
|
+++ b/image-converter/caja-image-resize.ui
|
||||||
|
@@ -183,7 +183,7 @@
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="spacing">8</property>
|
||||||
|
<child>
|
||||||
|
- <object class="GtkRadioButton">
|
||||||
|
+ <object class="GtkRadioButton" id="custom_pct_radiobutton">
|
||||||
|
<property name="label" translatable="yes">Scale:</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
132
srcpkgs/caja-extensions/patches/2-sendto-gupnp-1.6.patch
Normal file
132
srcpkgs/caja-extensions/patches/2-sendto-gupnp-1.6.patch
Normal file
|
@ -0,0 +1,132 @@
|
||||||
|
From 652e145d2c5e2a9658eed7a665fe5a295503940b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Xiaotian Wu <yetist@gmail.com>
|
||||||
|
Date: Mon, 16 Oct 2023 10:42:27 +0800
|
||||||
|
Subject: [PATCH] sendto: require gupnp-1.6
|
||||||
|
|
||||||
|
---
|
||||||
|
configure.ac | 6 ++---
|
||||||
|
sendto/plugins/upnp/upnp.c | 48 ++++++++++++++++++++++----------------
|
||||||
|
2 files changed, 30 insertions(+), 24 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index a6c506c..5fedb4b 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -100,7 +100,7 @@ if test "x$enable_sendto" = "xyes"; then
|
||||||
|
GTHREAD_REQUIRED=2.6.0
|
||||||
|
DBUS_REQUIRED=1.0
|
||||||
|
DBUS_GLIB_REQUIRED=0.60
|
||||||
|
- GUPNP_REQUIRED=0.13
|
||||||
|
+ GUPNP_REQUIRED=1.6
|
||||||
|
PKG_CHECK_MODULES(SENDTO,
|
||||||
|
glib-2.0 >= $GLIB_REQUIRED
|
||||||
|
gthread-2.0 >= $GTHREAD_REQUIRED
|
||||||
|
@@ -214,9 +214,7 @@ if test "x$enable_sendto" = "xyes"; then
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
upnp)
|
||||||
|
- PKG_CHECK_MODULES(UPNP, gupnp-1.2 >= $GUPNP_REQUIRED,
|
||||||
|
- enable_upnp=yes AC_DEFINE([HAS_GUPNP_VERSION_1_2], 1, ["Version is at least 1.2"]), enable_upnp=no)
|
||||||
|
- PKG_CHECK_MODULES(UPNP, gupnp-1.0 >= $GUPNP_REQUIRED,
|
||||||
|
+ PKG_CHECK_MODULES(UPNP, gupnp-1.6 >= $GUPNP_REQUIRED,
|
||||||
|
enable_upnp=yes, enable_upnp=no)
|
||||||
|
if test "${enable_upnp}" != "yes" ; then
|
||||||
|
sendto_plugin_error_or_ignore "you need gupnp installed to build the upnp plugin"
|
||||||
|
diff --git a/sendto/plugins/upnp/upnp.c b/sendto/plugins/upnp/upnp.c
|
||||||
|
index 7b6775b..b770e37 100644
|
||||||
|
--- a/sendto/plugins/upnp/upnp.c
|
||||||
|
+++ b/sendto/plugins/upnp/upnp.c
|
||||||
|
@@ -87,25 +87,37 @@ check_required_actions (GUPnPServiceIntrospection *introspection)
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
-get_introspection_cb (GUPnPServiceInfo *service_info,
|
||||||
|
- GUPnPServiceIntrospection *introspection, const GError *error,
|
||||||
|
- gpointer user_data)
|
||||||
|
+get_introspection_cb (GObject *source_object,
|
||||||
|
+ GAsyncResult *res,
|
||||||
|
+ gpointer user_data)
|
||||||
|
{
|
||||||
|
GUPnPDeviceInfo *device_info;
|
||||||
|
gchar *name;
|
||||||
|
const gchar *udn, *interface;
|
||||||
|
GtkTreeIter iter;
|
||||||
|
GUPnPContext *context;
|
||||||
|
+ GError *error = NULL;
|
||||||
|
|
||||||
|
device_info = GUPNP_DEVICE_INFO (user_data);
|
||||||
|
|
||||||
|
- if (introspection != NULL) {
|
||||||
|
- /* If introspection is available, make sure required actions
|
||||||
|
- * are implemented.
|
||||||
|
- */
|
||||||
|
- if (!check_required_actions (introspection))
|
||||||
|
- goto error;
|
||||||
|
- }
|
||||||
|
+ GUPnPServiceIntrospection *introspection =
|
||||||
|
+ gupnp_service_info_introspect_finish (GUPNP_SERVICE_INFO (GUPNP_SERVICE_INFO (source_object)),
|
||||||
|
+ res,
|
||||||
|
+ &error);
|
||||||
|
+ if (error) {
|
||||||
|
+ g_warning ("Failed to create introspection for '%s': %s",
|
||||||
|
+ gupnp_service_info_get_udn (GUPNP_SERVICE_INFO (source_object)),
|
||||||
|
+ error->message);
|
||||||
|
+ g_clear_error (&error);
|
||||||
|
+ goto error;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ /* If introspection is available, make sure required actions
|
||||||
|
+ * are implemented.
|
||||||
|
+ */
|
||||||
|
+ if (!check_required_actions (introspection)) {
|
||||||
|
+ goto error;
|
||||||
|
+ }
|
||||||
|
|
||||||
|
udn = gupnp_device_info_get_udn (device_info);
|
||||||
|
if (G_UNLIKELY (udn == NULL))
|
||||||
|
@@ -129,10 +141,8 @@ get_introspection_cb (GUPnPServiceInfo *service_info,
|
||||||
|
-1);
|
||||||
|
|
||||||
|
g_free (name);
|
||||||
|
-
|
||||||
|
+ g_object_unref (introspection);
|
||||||
|
error:
|
||||||
|
- /* We don't need the proxy objects anymore */
|
||||||
|
- g_object_unref (service_info);
|
||||||
|
g_object_ref (device_info);
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -148,9 +158,10 @@ device_proxy_available_cb (GUPnPControlPoint *cp,
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
- gupnp_service_info_get_introspection_async (info,
|
||||||
|
- get_introspection_cb,
|
||||||
|
- g_object_ref (proxy));
|
||||||
|
+ gupnp_service_info_introspect_async (info,
|
||||||
|
+ NULL,
|
||||||
|
+ get_introspection_cb,
|
||||||
|
+ g_object_ref (proxy));
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
@@ -211,11 +222,7 @@ init (NstPlugin *plugin)
|
||||||
|
return FALSE;
|
||||||
|
g_free (upload_cmd);
|
||||||
|
|
||||||
|
-#ifdef HAS_GUPNP_VERSION_1_2
|
||||||
|
context_manager = gupnp_context_manager_create (0);
|
||||||
|
-#else
|
||||||
|
- context_manager = gupnp_context_manager_new (NULL, 0);
|
||||||
|
-#endif
|
||||||
|
g_assert (context_manager != NULL);
|
||||||
|
g_signal_connect (context_manager, "context-available",
|
||||||
|
G_CALLBACK (on_context_available), NULL);
|
||||||
|
@@ -275,6 +282,7 @@ send_files (NstPlugin *plugin,
|
||||||
|
g_ptr_array_add (argv, "15"); /* discovery timeout (seconds) */
|
||||||
|
g_ptr_array_add (argv, "-e");
|
||||||
|
g_ptr_array_add (argv, interface);
|
||||||
|
+ g_ptr_array_add (argv, "-u");
|
||||||
|
g_ptr_array_add (argv, udn);
|
||||||
|
for (l = file_list ; l; l=l->next) {
|
||||||
|
gchar *file_path;
|
58
srcpkgs/caja-extensions/patches/3-xattr-mtp.patch
Normal file
58
srcpkgs/caja-extensions/patches/3-xattr-mtp.patch
Normal file
|
@ -0,0 +1,58 @@
|
||||||
|
From 91cc4665e9d707fd1015fb5c952816d13ef37693 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Goffredo Baroncelli <kreijack@inwind.it>
|
||||||
|
Date: Sun, 6 Nov 2022 16:17:04 +0100
|
||||||
|
Subject: [PATCH] xattr-tags-extension: avoid check xattr for mtp:// and
|
||||||
|
gphoto2://
|
||||||
|
|
||||||
|
Some protocols (like mtp://), doesn't support xattr. In this
|
||||||
|
case avoid to check the xattr-tags to not have
|
||||||
|
poor performance.
|
||||||
|
|
||||||
|
This patch blacklist mtp:// and gphoto2://.
|
||||||
|
---
|
||||||
|
xattr-tags/caja-xattr-tags-extension.c | 23 +++++++++++++++++++++++
|
||||||
|
1 file changed, 23 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/xattr-tags/caja-xattr-tags-extension.c b/xattr-tags/caja-xattr-tags-extension.c
|
||||||
|
index a3c8993..ab6450d 100644
|
||||||
|
--- a/xattr-tags/caja-xattr-tags-extension.c
|
||||||
|
+++ b/xattr-tags/caja-xattr-tags-extension.c
|
||||||
|
@@ -50,6 +50,16 @@ typedef struct {
|
||||||
|
GClosure *update_complete;
|
||||||
|
} CajaXattrTagsHandle;
|
||||||
|
|
||||||
|
+/* List of protocols that don't support xattr retriving,
|
||||||
|
+ * so we can skip it safetely
|
||||||
|
+ */
|
||||||
|
+static gchar *protocols_blacklist[] = {
|
||||||
|
+ "mtp://",
|
||||||
|
+ "gphoto2://",
|
||||||
|
+
|
||||||
|
+ NULL
|
||||||
|
+};
|
||||||
|
+
|
||||||
|
/* Stolen code: why they didn't expose it!?
|
||||||
|
* file: glocalfileinfo.c
|
||||||
|
* function: hex_unescape_string
|
||||||
|
@@ -107,8 +117,21 @@ static gchar *caja_xattr_tags_get_xdg_tags(CajaFileInfo *file)
|
||||||
|
gchar *tags = NULL, *uri;
|
||||||
|
GFile *location;
|
||||||
|
GFileInfo *info;
|
||||||
|
+ int i;
|
||||||
|
|
||||||
|
uri = caja_file_info_get_activation_uri (file);
|
||||||
|
+ for (i = 0 ; protocols_blacklist[i] ; i++) {
|
||||||
|
+ int l = strlen(protocols_blacklist[i]);
|
||||||
|
+
|
||||||
|
+ if (strlen(uri) < l)
|
||||||
|
+ continue;
|
||||||
|
+ if (strncasecmp(uri, protocols_blacklist[i], l))
|
||||||
|
+ continue;
|
||||||
|
+
|
||||||
|
+ g_free (uri);
|
||||||
|
+ return NULL;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
location = g_file_new_for_uri (uri);
|
||||||
|
info = g_file_query_info (location,
|
||||||
|
G_FILE_ATTRIBUTE_XATTR_XDG_TAGS,
|
|
@ -1,11 +1,12 @@
|
||||||
# Template file for 'caja-extensions'
|
# Template file for 'caja-extensions'
|
||||||
pkgname=caja-extensions
|
pkgname=caja-extensions
|
||||||
version=1.26.1
|
version=1.26.1
|
||||||
revision=2
|
revision=3
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
configure_args="--disable-gksu --disable-static"
|
configure_args="--disable-gksu --disable-static"
|
||||||
hostmakedepends="pkg-config intltool glib-devel libxml2"
|
hostmakedepends="pkg-config intltool glib-devel libxml2
|
||||||
makedepends="libcaja-devel mate-desktop-devel dbus-glib-devel gupnp1.2-devel"
|
automake gettext-devel-tools libtool gtk-doc"
|
||||||
|
makedepends="libcaja-devel mate-desktop-devel dbus-glib-devel gupnp-devel"
|
||||||
depends="caja"
|
depends="caja"
|
||||||
short_desc="Extensions for the MATE Caja file manager"
|
short_desc="Extensions for the MATE Caja file manager"
|
||||||
maintainer="skmpz <dem.procopiou@gmail.com>"
|
maintainer="skmpz <dem.procopiou@gmail.com>"
|
||||||
|
@ -15,6 +16,10 @@ changelog="https://raw.githubusercontent.com/mate-desktop/caja-extensions/master
|
||||||
distfiles="https://pub.mate-desktop.org/releases/${version%.*}/${pkgname}-${version}.tar.xz"
|
distfiles="https://pub.mate-desktop.org/releases/${version%.*}/${pkgname}-${version}.tar.xz"
|
||||||
checksum=589c19e3fa10242d6239a5ccb9585598436a56ebe94d2eb2a50b5950cce1d520
|
checksum=589c19e3fa10242d6239a5ccb9585598436a56ebe94d2eb2a50b5950cce1d520
|
||||||
|
|
||||||
|
pre_configure() {
|
||||||
|
autoreconf -fi
|
||||||
|
}
|
||||||
|
|
||||||
post_install() {
|
post_install() {
|
||||||
rm -rf ${DESTDIR}/usr/include
|
rm -rf ${DESTDIR}/usr/include
|
||||||
rm -rf ${DESTDIR}/usr/lib/pkgconfig
|
rm -rf ${DESTDIR}/usr/lib/pkgconfig
|
||||||
|
|
Loading…
Add table
Reference in a new issue