Add subdir patch.
Signed-off-by: Fabian Deutsch <fabian.deutsch@gmx.de>
This commit is contained in:
parent
84217fdd05
commit
196f35e3d7
48
orc-subdir.patch
Normal file
48
orc-subdir.patch
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
From 8bc69ba508e2ec6e573ba197d0f20b1a39a1c920 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Fabian Deutsch <fabian.deutsch@gmx.de>
|
||||||
|
Date: Tue, 4 Oct 2011 13:28:38 +0200
|
||||||
|
Subject: [PATCH] Use a subdirectory for temporary files.
|
||||||
|
|
||||||
|
This allows the a better integration with selinux, as the rule can use the path name and doesn't need globbing.
|
||||||
|
|
||||||
|
Signed-off-by: Fabian Deutsch <fabian.deutsch@gmx.de>
|
||||||
|
---
|
||||||
|
orc/orccodemem.c | 18 +++++++++++++++++-
|
||||||
|
1 files changed, 17 insertions(+), 1 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/orc/orccodemem.c b/orc/orccodemem.c
|
||||||
|
index f470be5..e125faa 100644
|
||||||
|
--- a/orc/orccodemem.c
|
||||||
|
+++ b/orc/orccodemem.c
|
||||||
|
@@ -193,11 +193,27 @@ orc_code_chunk_free (OrcCodeChunk *chunk)
|
||||||
|
#ifdef HAVE_CODEMEM_MMAP
|
||||||
|
int
|
||||||
|
orc_code_region_allocate_codemem_dual_map (OrcCodeRegion *region,
|
||||||
|
- const char *dir, int force_unlink)
|
||||||
|
+ const char *basedir, int force_unlink)
|
||||||
|
{
|
||||||
|
int fd;
|
||||||
|
int n;
|
||||||
|
char *filename;
|
||||||
|
+ char *dir;
|
||||||
|
+ struct stat stat_p;
|
||||||
|
+
|
||||||
|
+ dir = malloc (strlen (basedir) + strlen ("/.orc"));
|
||||||
|
+ sprintf (dir, "%s/.orc", basedir);
|
||||||
|
+
|
||||||
|
+ stat (dir, &stat_p);
|
||||||
|
+ if (!S_ISDIR (stat_p.st_mode))
|
||||||
|
+ {
|
||||||
|
+ n = mkdir (dir, S_IRWXU);
|
||||||
|
+ if (n < 0)
|
||||||
|
+ {
|
||||||
|
+ ORC_WARNING ("failed to create subdir");
|
||||||
|
+ return FALSE;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
|
||||||
|
filename = malloc (strlen ("/orcexec..") +
|
||||||
|
strlen (dir) + 6 + 1);
|
||||||
|
--
|
||||||
|
1.7.6.4
|
||||||
|
|
12
orc.spec
12
orc.spec
@ -1,6 +1,6 @@
|
|||||||
Name: orc
|
Name: orc
|
||||||
Version: 0.4.16
|
Version: 0.4.16
|
||||||
Release: 2%{?dist}
|
Release: 3%{?dist}
|
||||||
Summary: The Oil Run-time Compiler
|
Summary: The Oil Run-time Compiler
|
||||||
|
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
@ -13,6 +13,8 @@ BuildRequires: gtk-doc, libtool
|
|||||||
|
|
||||||
Patch1: orc-no-nopl.patch
|
Patch1: orc-no-nopl.patch
|
||||||
Patch2: orc-no-nopw.patch
|
Patch2: orc-no-nopw.patch
|
||||||
|
# Upstream bug: https://bugs.freedesktop.org/show_bug.cgi?id=41446
|
||||||
|
Patch3: orc-subdir.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Orc is a library and set of tools for compiling and executing
|
Orc is a library and set of tools for compiling and executing
|
||||||
@ -54,8 +56,9 @@ The Orc compiler, to produce optimized code.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch1 -p1
|
%patch1 -p1 -b .nopl
|
||||||
%patch2 -p1
|
%patch2 -p1 -b .nopw
|
||||||
|
%patch3 -p1 -b .subdir
|
||||||
|
|
||||||
autoreconf -vif
|
autoreconf -vif
|
||||||
|
|
||||||
@ -119,6 +122,9 @@ make check
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Oct 16 2011 Fabian Deutsch <fabiand@fedoraproject.org> - 0.4.16-3
|
||||||
|
- Add Fedora specific patch for tempfiles in subdirs
|
||||||
|
|
||||||
* Sun Oct 16 2011 Daniel Drake <dsd@laptop.org> - 0.4.16-2
|
* Sun Oct 16 2011 Daniel Drake <dsd@laptop.org> - 0.4.16-2
|
||||||
- Add upstream patches to fix gstreamer crash on Geode (#746185)
|
- Add upstream patches to fix gstreamer crash on Geode (#746185)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user