0
0
mirror of https://github.com/termux/termux-packages.git synced 2025-03-03 02:09:03 +00:00
termux-packages/packages/file/fix-paths.patch

25 lines
842 B
Diff
Raw Normal View History

2022-07-22 17:20:43 +01:00
diff -uNr file-5.42/src/compress.c file-5.42.mod/src/compress.c
--- file-5.42/src/compress.c 2022-04-11 19:15:07.000000000 +0100
+++ file-5.42.mod/src/compress.c 2022-07-22 17:17:00.944240000 +0100
@@ -465,7 +465,7 @@
(void)strlcat(buf, "/", sizeof(buf));
(void)strlcat(buf, "file.XXXXXX", sizeof(buf));
#else
- (void)strlcpy(buf, "/tmp/file.XXXXXX", sizeof(buf));
2019-03-02 14:52:28 +02:00
+ (void)strlcpy(buf, "@TERMUX_PREFIX@/tmp/file.XXXXXX", sizeof buf);
2022-07-22 17:20:43 +01:00
#endif
2019-03-02 14:52:28 +02:00
#ifndef HAVE_MKSTEMP
{
2022-07-22 17:20:43 +01:00
diff -uNr file-5.42/src/file.h file-5.42.mod/src/file.h
--- file-5.42/src/file.h 2022-05-28 21:24:09.000000000 +0100
+++ file-5.42.mod/src/file.h 2022-07-22 17:16:04.080017000 +0100
@@ -96,7 +96,7 @@
2019-03-02 14:52:28 +02:00
#define ENABLE_CONDITIONALS
#ifndef MAGIC
-#define MAGIC "/etc/magic"
+#define MAGIC "@TERMUX_PREFIX@/etc/magic"
#endif
#if defined(__EMX__) || defined (WIN32)