diff --git a/x11-packages/thunar/0001-fix-hardcoded-paths.patch b/x11-packages/thunar/0001-fix-hardcoded-paths.patch
new file mode 100644
index 0000000000..362ea06ff5
--- /dev/null
+++ b/x11-packages/thunar/0001-fix-hardcoded-paths.patch
@@ -0,0 +1,22 @@
+--- a/plugins/thunar-sendto-email/main.c
++++ b/plugins/thunar-sendto-email/main.c
+@@ -434,7 +434,7 @@
+ gint n;
+
+ /* create a temporary directory */
+- tmpdir = g_strdup ("/tmp/thunar-sendto-email.XXXXXX");
++ tmpdir = g_strdup ("@TERMUX_PREFIX@/tmp/thunar-sendto-email.XXXXXX");
+ if (G_UNLIKELY (mkdtemp (tmpdir) == NULL))
+ {
+ /* tell the user that we failed to create a temporary directory */
+--- a/plugins/thunar-uca/thunar-uca-model.c
++++ b/plugins/thunar-uca/thunar-uca-model.c
+@@ -53,7 +53,7 @@
+
+ /* not all systems define _PATH_BSHELL */
+ #ifndef _PATH_BSHELL
+-#define _PATH_BSHELL "/bin/sh"
++#define _PATH_BSHELL "@TERMUX_PREFIX@/bin/sh"
+ #endif
+
+
diff --git a/x11-packages/thunar/build.sh b/x11-packages/thunar/build.sh
index 427d565221..d51f33722c 100644
--- a/x11-packages/thunar/build.sh
+++ b/x11-packages/thunar/build.sh
@@ -2,20 +2,20 @@ TERMUX_PKG_HOMEPAGE=https://docs.xfce.org/xfce/thunar/start
TERMUX_PKG_DESCRIPTION="Modern file manager for XFCE environment"
TERMUX_PKG_LICENSE="GPL-2.0, LGPL-2.0"
TERMUX_PKG_MAINTAINER="@termux"
-TERMUX_PKG_VERSION="4.18.11"
+TERMUX_PKG_VERSION="4.20.0"
TERMUX_PKG_SRCURL=https://archive.xfce.org/src/xfce/thunar/${TERMUX_PKG_VERSION%.*}/thunar-${TERMUX_PKG_VERSION}.tar.bz2
-TERMUX_PKG_SHA256=7d0bdae2076a568c137d403ab5600e06a7a4f7a02514d486da7b8414aa75d612
+TERMUX_PKG_SHA256=27731a76f3aecf3752b1ca35afad89e264c52244f70083d933507dd4a17548b0
TERMUX_PKG_AUTO_UPDATE=true
TERMUX_PKG_DEPENDS="atk, desktop-file-utils, exo, gdk-pixbuf, glib, gtk3, harfbuzz, libcairo, libexif, libice, libnotify, libsm, libx11, libxfce4ui, libxfce4util, pango, pcre2, shared-mime-info, xfce4-panel, xfconf, zlib"
-TERMUX_PKG_BUILD_DEPENDS="g-ir-scanner"
+TERMUX_PKG_BUILD_DEPENDS="g-ir-scanner, xfce4-dev-tools"
TERMUX_PKG_RECOMMENDS="gvfs, hicolor-icon-theme, thunar-archive-plugin, tumbler"
TERMUX_PKG_VERSIONED_GIR=false
TERMUX_PKG_DISABLE_GIR=false
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
+--disable-debug
--enable-gtk-doc-html=no
--enable-introspection=yes
"
-TERMUX_PKG_BUILD_IN_SRC=true
termux_step_pre_configure() {
termux_setup_gir
diff --git a/x11-packages/thunar/gir/Thunarx-3.0.xml b/x11-packages/thunar/gir/Thunarx-3.0.xml
index c33dd7e331..409c4bb60e 100644
--- a/x11-packages/thunar/gir/Thunarx-3.0.xml
+++ b/x11-packages/thunar/gir/Thunarx-3.0.xml
@@ -7,6 +7,8 @@
+
+
@@ -20,8 +22,6 @@
-
-