libffi package update
Signed-off-by: basebuilder_pel7ppc64bebuilder0 <basebuilder@powerel.org>master
parent
ec59ab6ab7
commit
6e5ef40540
|
@ -0,0 +1,23 @@
|
|||
/* This file is here to prevent a file conflict on multiarch systems. */
|
||||
#ifdef ffi_wrapper_h
|
||||
#error "Do not define ffi_wrapper_h!"
|
||||
#endif
|
||||
#define ffi_wrapper_h
|
||||
|
||||
#if defined(__i386__)
|
||||
#include "ffi-i386.h"
|
||||
#elif defined(__powerpc64__)
|
||||
#include "ffi-ppc64.h"
|
||||
#elif defined(__powerpc__)
|
||||
#include "ffi-ppc.h"
|
||||
#elif defined(__s390x__)
|
||||
#include "ffi-s390x.h"
|
||||
#elif defined(__s390__)
|
||||
#include "ffi-s390.h"
|
||||
#elif defined(__x86_64__)
|
||||
#include "ffi-x86_64.h"
|
||||
#else
|
||||
#error "The libffi-devel package is not usable with the architecture."
|
||||
#endif
|
||||
|
||||
#undef ffi_wrapper_h
|
|
@ -0,0 +1,23 @@
|
|||
/* This file is here to prevent a file conflict on multiarch systems. */
|
||||
#ifdef ffitarget_wrapper_h
|
||||
#error "Do not define ffitarget_wrapper_h!"
|
||||
#endif
|
||||
#define ffitarget_wrapper_h
|
||||
|
||||
#if defined(__i386__)
|
||||
#include "ffitarget-i386.h"
|
||||
#elif defined(__powerpc64__)
|
||||
#include "ffitarget-ppc64.h"
|
||||
#elif defined(__powerpc__)
|
||||
#include "ffitarget-ppc.h"
|
||||
#elif defined(__s390x__)
|
||||
#include "ffitarget-s390x.h"
|
||||
#elif defined(__s390__)
|
||||
#include "ffitarget-s390.h"
|
||||
#elif defined(__x86_64__)
|
||||
#include "ffitarget-x86_64.h"
|
||||
#else
|
||||
#error "The libffi-devel package is not usable with the architecture."
|
||||
#endif
|
||||
|
||||
#undef ffitarget_wrapper_h
|
|
@ -0,0 +1,82 @@
|
|||
From 8daeed9570af72eb135c8ded460d2888f05b2e68 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Micka=C3=ABl=20Sala=C3=BCn?= <mic@digikod.net>
|
||||
Date: Sun, 11 May 2014 22:54:58 +0200
|
||||
Subject: [PATCH 626/627] closures: Create temporary file with O_TMPFILE and
|
||||
O_CLOEXEC when available
|
||||
|
||||
The open_temp_exec_file_dir function can create a temporary file without
|
||||
file system accessible link. If the O_TMPFILE flag is not defined (old
|
||||
Linux kernel or libc) the behavior is unchanged.
|
||||
|
||||
The open_temp_exec_file_name function now need a new argument "flags"
|
||||
(like O_CLOEXEC) used for temporary file creation.
|
||||
|
||||
The O_TMPFILE flag allow temporary file creation without race condition.
|
||||
This feature/fix prevent another process to access the (future)
|
||||
executable file from the file system.
|
||||
|
||||
The O_CLOEXEC flag automatically close the temporary file for any
|
||||
execve. This avoid transmitting (executable) file descriptor to a child
|
||||
process.
|
||||
---
|
||||
src/closures.c | 29 ++++++++++++++++++++++++-----
|
||||
1 file changed, 24 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/closures.c b/src/closures.c
|
||||
index c7863f3..9799ce6 100644
|
||||
--- a/src/closures.c
|
||||
+++ b/src/closures.c
|
||||
@@ -265,9 +265,9 @@ static size_t execsize = 0;
|
||||
|
||||
/* Open a temporary file name, and immediately unlink it. */
|
||||
static int
|
||||
-open_temp_exec_file_name (char *name)
|
||||
+open_temp_exec_file_name (char *name, int flags)
|
||||
{
|
||||
- int fd = mkstemp (name);
|
||||
+ int fd = mkostemp (name, flags);
|
||||
|
||||
if (fd != -1)
|
||||
unlink (name);
|
||||
@@ -280,8 +280,27 @@ static int
|
||||
open_temp_exec_file_dir (const char *dir)
|
||||
{
|
||||
static const char suffix[] = "/ffiXXXXXX";
|
||||
- int lendir = strlen (dir);
|
||||
- char *tempname = __builtin_alloca (lendir + sizeof (suffix));
|
||||
+ int lendir, flags, fd;
|
||||
+ char *tempname;
|
||||
+
|
||||
+#ifdef O_CLOEXEC
|
||||
+ flags = O_CLOEXEC;
|
||||
+#else
|
||||
+ flags = 0;
|
||||
+#endif
|
||||
+
|
||||
+#ifdef O_TMPFILE
|
||||
+ fd = open (dir, flags | O_RDWR | O_EXCL | O_TMPFILE, 0700);
|
||||
+ /* If the running system does not support the O_TMPFILE flag then retry without it. */
|
||||
+ if (fd != -1 || (errno != EINVAL && errno != EISDIR && errno != EOPNOTSUPP)) {
|
||||
+ return fd;
|
||||
+ } else {
|
||||
+ errno = 0;
|
||||
+ }
|
||||
+#endif
|
||||
+
|
||||
+ lendir = strlen (dir);
|
||||
+ tempname = __builtin_alloca (lendir + sizeof (suffix));
|
||||
|
||||
if (!tempname)
|
||||
return -1;
|
||||
@@ -289,7 +308,7 @@ open_temp_exec_file_dir (const char *dir)
|
||||
memcpy (tempname, dir, lendir);
|
||||
memcpy (tempname + lendir, suffix, sizeof (suffix));
|
||||
|
||||
- return open_temp_exec_file_name (tempname);
|
||||
+ return open_temp_exec_file_name (tempname, flags);
|
||||
}
|
||||
|
||||
/* Open a temporary file in the directory in the named environment
|
||||
--
|
||||
1.7.12.1
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
diff -up libffi-3.0.13/include/Makefile.am.fixpath libffi-3.0.13/include/Makefile.am
|
||||
--- libffi-3.0.13/include/Makefile.am.fixpath 2013-05-25 22:11:25.983889342 -0400
|
||||
+++ libffi-3.0.13/include/Makefile.am 2013-05-25 22:12:12.337890037 -0400
|
||||
@@ -5,5 +5,5 @@ AUTOMAKE_OPTIONS=foreign
|
||||
DISTCLEANFILES=ffitarget.h
|
||||
EXTRA_DIST=ffi.h.in ffi_common.h
|
||||
|
||||
-includesdir = $(libdir)/@PACKAGE_NAME@-@PACKAGE_VERSION@/include
|
||||
+includesdir = $(includedir)/
|
||||
nodist_includes_HEADERS = ffi.h ffitarget.h
|
||||
diff -up libffi-3.0.13/include/Makefile.in.fixpath libffi-3.0.13/include/Makefile.in
|
||||
--- libffi-3.0.13/include/Makefile.in.fixpath 2013-05-25 22:12:56.259890696 -0400
|
||||
+++ libffi-3.0.13/include/Makefile.in 2013-05-25 22:13:12.101890934 -0400
|
||||
@@ -250,7 +250,7 @@ top_srcdir = @top_srcdir@
|
||||
AUTOMAKE_OPTIONS = foreign
|
||||
DISTCLEANFILES = ffitarget.h
|
||||
EXTRA_DIST = ffi.h.in ffi_common.h
|
||||
-includesdir = $(libdir)/@PACKAGE_NAME@-@PACKAGE_VERSION@/include
|
||||
+includesdir = $(includedir)/
|
||||
nodist_includes_HEADERS = ffi.h ffitarget.h
|
||||
all: all-am
|
||||
|
||||
diff -up libffi-3.0.13/libffi.pc.in.fixpath libffi-3.0.13/libffi.pc.in
|
||||
--- libffi-3.0.13/libffi.pc.in.fixpath 2013-05-25 22:14:21.037891968 -0400
|
||||
+++ libffi-3.0.13/libffi.pc.in 2013-05-25 22:14:31.652892128 -0400
|
||||
@@ -1,7 +1,7 @@
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
-includedir=${libdir}/@PACKAGE_NAME@-@PACKAGE_VERSION@/include
|
||||
+includedir=@includedir@
|
||||
|
||||
Name: @PACKAGE_NAME@
|
||||
Description: Library supporting Foreign Function Interfaces
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,56 @@
|
|||
Date: Wed, 20 Nov 2013 18:03:32 +1030
|
||||
From: Alan Modra <amodra at gmail dot com>
|
||||
To: libffi-discuss at sourceware dot org
|
||||
Subject: PowerPC64 ELFv2 fix 1 of 2
|
||||
Message-ID: <20131120073332.GF22514@bubble.grove.modra.org>
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline
|
||||
User-Agent: Mutt/1.5.21 (2010-09-15)
|
||||
|
||||
Using the return value area as a place to pass parameters wasn't such
|
||||
a good idea, causing a failure of cls_ulonglong.c. I didn't see this
|
||||
when running the mainline gcc libffi testsuite because that version of
|
||||
the test is inferior to the upstreamm libffi test.
|
||||
|
||||
* src/powerpc/linux64_closure.S: Don't use the return value area
|
||||
as a parameter save area on ELFv2.
|
||||
|
||||
diff --git a/src/powerpc/linux64_closure.S b/src/powerpc/linux64_closure.S
|
||||
index 9b6b5f3..4d012cc 100644
|
||||
--- a/src/powerpc/linux64_closure.S
|
||||
+++ b/src/powerpc/linux64_closure.S
|
||||
@@ -60,13 +60,11 @@ ffi_closure_LINUX64:
|
||||
# endif
|
||||
|
||||
# if _CALL_ELF == 2
|
||||
-# 32 byte special reg save area + 64 byte parm save area and retval
|
||||
-# + 13*8 fpr save area + round to 16
|
||||
-# define STACKFRAME 208
|
||||
+# 32 byte special reg save area + 64 byte parm save area
|
||||
+# + 64 byte retval area + 13*8 fpr save area + round to 16
|
||||
+# define STACKFRAME 272
|
||||
# define PARMSAVE 32
|
||||
-# No parameter save area is needed for the call to ffi_closure_helper_LINUX64,
|
||||
-# so return value can start there.
|
||||
-# define RETVAL PARMSAVE
|
||||
+# define RETVAL PARMSAVE+64
|
||||
# else
|
||||
# 48 bytes special reg save area + 64 bytes parm save area
|
||||
# + 16 bytes retval area + 13*8 bytes fpr save area + round to 16
|
||||
@@ -85,8 +83,8 @@ ffi_closure_LINUX64:
|
||||
bt 7, .Lparmsave
|
||||
# Our caller has not allocated a parameter save area.
|
||||
# We need to allocate one here and use it to pass gprs to
|
||||
- # ffi_closure_helper_LINUX64. The return value area will do.
|
||||
- addi %r12, %r1, -STACKFRAME+RETVAL
|
||||
+ # ffi_closure_helper_LINUX64.
|
||||
+ addi %r12, %r1, -STACKFRAME+PARMSAVE
|
||||
.Lparmsave:
|
||||
std %r0, 16(%r1)
|
||||
# Save general regs into parm save area
|
||||
|
||||
--
|
||||
Alan Modra
|
||||
Australia Development Lab, IBM
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
Date: Wed, 20 Nov 2013 18:05:21 +1030
|
||||
From: Alan Modra <amodra at gmail dot com>
|
||||
To: libffi-discuss at sourceware dot org
|
||||
Subject: PowerPC64 ELFv2 fix 2 of 2
|
||||
Message-ID: <20131120073521.GG22514@bubble.grove.modra.org>
|
||||
References: <20131117031650.GR22514@bubble.grove.modra.org> <87eh6e2b4o.fsf@redhat.com> <20131119001430.GX22514@bubble.grove.modra.org>
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: inline
|
||||
In-Reply-To: <20131119001430 dot GX22514 at bubble dot grove dot modra dot org>
|
||||
User-Agent: Mutt/1.5.21 (2010-09-15)
|
||||
|
||||
Using NUM_FPR_ARG_REGISTERS rather than NUM_FPR_ARG_REGISTERS64 meant
|
||||
that a parameter save area could be allocated before it was strictly
|
||||
necessary. Wrong but harmless. Found when splitting apart ffi.c
|
||||
into 32-bit and 64-bit support.
|
||||
|
||||
* src/powerpc/ffi.c (ffi_prep_cif_machdep_core): Use
|
||||
NUM_FPR_ARG_REGISTERS64 and NUM_GPR_ARG_REGISTERS64 not their
|
||||
32-bit versions for 64-bit code.
|
||||
|
||||
diff --git a/src/powerpc/ffi.c b/src/powerpc/ffi.c
|
||||
index feb2144..6896065 100644
|
||||
--- a/src/powerpc/ffi.c
|
||||
+++ b/src/powerpc/ffi.c
|
||||
@@ -978,7 +978,7 @@ ffi_prep_cif_machdep_core (ffi_cif *cif)
|
||||
case FFI_TYPE_LONGDOUBLE:
|
||||
fparg_count += 2;
|
||||
intarg_count += 2;
|
||||
- if (fparg_count > NUM_FPR_ARG_REGISTERS)
|
||||
+ if (fparg_count > NUM_FPR_ARG_REGISTERS64)
|
||||
flags |= FLAG_ARG_NEEDS_PSAVE;
|
||||
break;
|
||||
#endif
|
||||
@@ -986,7 +986,7 @@ ffi_prep_cif_machdep_core (ffi_cif *cif)
|
||||
case FFI_TYPE_DOUBLE:
|
||||
fparg_count++;
|
||||
intarg_count++;
|
||||
- if (fparg_count > NUM_FPR_ARG_REGISTERS)
|
||||
+ if (fparg_count > NUM_FPR_ARG_REGISTERS64)
|
||||
flags |= FLAG_ARG_NEEDS_PSAVE;
|
||||
break;
|
||||
|
||||
@@ -1007,12 +1007,12 @@ ffi_prep_cif_machdep_core (ffi_cif *cif)
|
||||
if (elt)
|
||||
{
|
||||
fparg_count += elnum;
|
||||
- if (fparg_count > NUM_FPR_ARG_REGISTERS)
|
||||
+ if (fparg_count > NUM_FPR_ARG_REGISTERS64)
|
||||
flags |= FLAG_ARG_NEEDS_PSAVE;
|
||||
}
|
||||
else
|
||||
{
|
||||
- if (intarg_count > NUM_GPR_ARG_REGISTERS)
|
||||
+ if (intarg_count > NUM_GPR_ARG_REGISTERS64)
|
||||
flags |= FLAG_ARG_NEEDS_PSAVE;
|
||||
}
|
||||
break;
|
||||
@@ -1030,7 +1030,7 @@ ffi_prep_cif_machdep_core (ffi_cif *cif)
|
||||
/* Everything else is passed as a 8-byte word in a GPR, either
|
||||
the object itself or a pointer to it. */
|
||||
intarg_count++;
|
||||
- if (intarg_count > NUM_GPR_ARG_REGISTERS)
|
||||
+ if (intarg_count > NUM_GPR_ARG_REGISTERS64)
|
||||
flags |= FLAG_ARG_NEEDS_PSAVE;
|
||||
break;
|
||||
default:
|
||||
|
||||
--
|
||||
Alan Modra
|
||||
Australia Development Lab, IBM
|
||||
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,11 @@
|
|||
--- libffi-3.1/src/aarch64/ffi.c.orig 2014-04-25 18:45:13.000000000 +0100
|
||||
+++ libffi-3.1/src/aarch64/ffi.c 2015-01-15 02:36:56.314906455 +0000
|
||||
@@ -728,7 +728,7 @@
|
||||
state.ngrn = N_X_ARG_REG;
|
||||
|
||||
memcpy (allocate_to_stack (&state, stack, ty->alignment,
|
||||
- ty->size), ecif->avalue + i, ty->size);
|
||||
+ ty->size), ecif->avalue[i], ty->size);
|
||||
}
|
||||
break;
|
||||
|
|
@ -0,0 +1,60 @@
|
|||
diff --git a/testsuite/libffi.call/cls_struct_va1.c b/testsuite/libffi.call/cls_struct_va1.c
|
||||
index 175ed96..6d1fdae 100644
|
||||
--- a/testsuite/libffi.call/cls_struct_va1.c
|
||||
+++ b/testsuite/libffi.call/cls_struct_va1.c
|
||||
@@ -35,7 +35,7 @@ test_fn (ffi_cif* cif __UNUSED__, void* resp,
|
||||
printf ("%d %d %d %d %d %d %d %d %d %d\n", n, s1.a, s1.b,
|
||||
l1.a, l1.b, l1.c, l1.d, l1.e,
|
||||
s2.a, s2.b);
|
||||
- * (int*) resp = 42;
|
||||
+ * (ffi_arg*) resp = 42;
|
||||
}
|
||||
|
||||
int
|
||||
diff --git a/testsuite/libffi.call/cls_uint_va.c b/testsuite/libffi.call/cls_uint_va.c
|
||||
index 150fddd..548d8c6 100644
|
||||
--- a/testsuite/libffi.call/cls_uint_va.c
|
||||
+++ b/testsuite/libffi.call/cls_uint_va.c
|
||||
@@ -10,12 +10,13 @@
|
||||
|
||||
typedef unsigned int T;
|
||||
|
||||
-static void cls_ret_T_fn(ffi_cif* cif __UNUSED__, void* resp, void** args,
|
||||
+static void cls_ret_T_fn(ffi_cif* cif __UNUSED__, void *resp, void** args,
|
||||
void* userdata __UNUSED__)
|
||||
{
|
||||
- *(T *)resp = *(T *)args[0];
|
||||
+ *(ffi_arg*)resp = *(T *)args[0];
|
||||
|
||||
- printf("%d: %d %d\n", *(T *)resp, *(T *)args[0], *(T *)args[1]);
|
||||
+
|
||||
+ printf("%d: %d %d\n", (int)*(ffi_arg *)resp, *(T *)args[0], *(T *)args[1]);
|
||||
}
|
||||
|
||||
typedef T (*cls_ret_T)(T, ...);
|
||||
diff --git a/testsuite/libffi.call/va_1.c b/testsuite/libffi.call/va_1.c
|
||||
index cf4dd85..7f96809 100644
|
||||
--- a/testsuite/libffi.call/va_1.c
|
||||
+++ b/testsuite/libffi.call/va_1.c
|
||||
@@ -94,7 +94,7 @@ main (void)
|
||||
struct large_tag l1;
|
||||
|
||||
int n;
|
||||
- int res;
|
||||
+ ffi_arg res;
|
||||
|
||||
unsigned char uc;
|
||||
signed char sc;
|
||||
diff --git a/testsuite/libffi.call/va_struct1.c b/testsuite/libffi.call/va_struct1.c
|
||||
index 11d1f10..e645206 100644
|
||||
--- a/testsuite/libffi.call/va_struct1.c
|
||||
+++ b/testsuite/libffi.call/va_struct1.c
|
||||
@@ -61,7 +61,7 @@ main (void)
|
||||
struct large_tag l1;
|
||||
|
||||
int n;
|
||||
- int res;
|
||||
+ ffi_arg res;
|
||||
|
||||
s_type.size = 0;
|
||||
s_type.alignment = 0;
|
|
@ -0,0 +1,278 @@
|
|||
%global multilib_arches %{ix86} ppc ppc64 s390 s390x x86_64
|
||||
|
||||
Name: libffi
|
||||
Version: 3.0.13
|
||||
Release: 18%{?dist}
|
||||
Summary: A portable foreign function interface library
|
||||
|
||||
Group: System Environment/Libraries
|
||||
License: MIT and Public Domain
|
||||
URL: http://sourceware.org/libffi
|
||||
Source0: ftp://sourceware.org/pub/libffi/libffi-%{version}.tar.gz
|
||||
# part of upstream commit 5feacad4
|
||||
Source1: ffi-multilib.h
|
||||
Source2: ffitarget-multilib.h
|
||||
Patch0: libffi-3.0.13-fix-include-path.patch
|
||||
Patch1: libffi-fix-ppc-tests.patch
|
||||
# part of upstream commit 5feacad4
|
||||
Patch10: libffi-3.0.13-ppc64le-0.patch
|
||||
Patch11: libffi-3.0.13-ppc64le-1.patch
|
||||
Patch12: libffi-3.0.13-ppc64le-2.patch
|
||||
Patch13: libffi-3.0.13-ppc64le-3.patch
|
||||
# rhbz 1287815:
|
||||
Patch20: libffi-aarch64-rhbz1174037.patch
|
||||
|
||||
Patch21: libffi-3.0.13-closures-Create-temporary-file-with-O_TMPFILE-and-O_.patch
|
||||
%ifarch ppc64le
|
||||
BuildRequires: autoconf automake libtool texinfo
|
||||
%endif
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
%description
|
||||
Compilers for high level languages generate code that follow certain
|
||||
conventions. These conventions are necessary, in part, for separate
|
||||
compilation to work. One such convention is the "calling convention".
|
||||
The calling convention is a set of assumptions made by the compiler
|
||||
about where function arguments will be found on entry to a function. A
|
||||
calling convention also specifies where the return value for a function
|
||||
is found.
|
||||
|
||||
Some programs may not know at the time of compilation what arguments
|
||||
are to be passed to a function. For instance, an interpreter may be
|
||||
told at run-time about the number and types of arguments used to call a
|
||||
given function. `Libffi' can be used in such programs to provide a
|
||||
bridge from the interpreter program to compiled code.
|
||||
|
||||
The `libffi' library provides a portable, high level programming
|
||||
interface to various calling conventions. This allows a programmer to
|
||||
call any function specified by a call interface description at run time.
|
||||
|
||||
FFI stands for Foreign Function Interface. A foreign function
|
||||
interface is the popular name for the interface that allows code
|
||||
written in one language to call code written in another language. The
|
||||
`libffi' library really only provides the lowest, machine dependent
|
||||
layer of a fully featured foreign function interface. A layer must
|
||||
exist above `libffi' that handles type conversions for values passed
|
||||
between the two languages.
|
||||
|
||||
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Group: Development/Libraries
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: pkgconfig
|
||||
Requires(post): /sbin/install-info
|
||||
Requires(preun): /sbin/install-info
|
||||
|
||||
%description devel
|
||||
The %{name}-devel package contains libraries and header files for
|
||||
developing applications that use %{name}.
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1 -b .fixpath
|
||||
%patch1 -p1 -b .fixpath
|
||||
%ifarch ppc64le
|
||||
%patch10 -p1 -b .ppc64le-0
|
||||
%patch11 -p1 -b .ppc64le-1
|
||||
%patch12 -p1 -b .ppc64le-2
|
||||
%patch13 -p1 -b .ppc64le-3
|
||||
|
||||
autoreconf -vif
|
||||
%endif
|
||||
|
||||
%patch20 -p1 -b .aarch64
|
||||
%patch21 -p1 -b .tmpfile
|
||||
%build
|
||||
CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" %configure --disable-static
|
||||
make %{?_smp_mflags}
|
||||
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make install DESTDIR=$RPM_BUILD_ROOT
|
||||
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
|
||||
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
|
||||
|
||||
# Determine generic arch target name for multilib wrapper
|
||||
basearch=%{_arch}
|
||||
%ifarch %{ix86}
|
||||
basearch=i386
|
||||
%endif
|
||||
|
||||
%ifarch %{multilib_arches}
|
||||
# Do header file switcheroo to avoid file conflicts on systems where you
|
||||
# can have both a 32- and 64-bit version of the library, and they each need
|
||||
# their own correct-but-different versions of the headers to be usable.
|
||||
for i in ffi ffitarget; do
|
||||
mv $RPM_BUILD_ROOT%{_includedir}/$i.h $RPM_BUILD_ROOT%{_includedir}/$i-${basearch}.h
|
||||
done
|
||||
install -m644 %{SOURCE1} $RPM_BUILD_ROOT%{_includedir}/ffi.h
|
||||
install -m644 %{SOURCE2} $RPM_BUILD_ROOT%{_includedir}/ffitarget.h
|
||||
%endif
|
||||
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%post -p /sbin/ldconfig
|
||||
|
||||
%post devel
|
||||
/sbin/install-info --info-dir=%{_infodir} %{_infodir}/libffi.info.gz
|
||||
|
||||
%preun devel
|
||||
if [ $1 = 0 ] ;then
|
||||
/sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/libffi.info.gz
|
||||
fi
|
||||
|
||||
%postun -p /sbin/ldconfig
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc LICENSE README
|
||||
%{_libdir}/*.so.*
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root,-)
|
||||
%{_libdir}/pkgconfig/*.pc
|
||||
%{_includedir}/ffi*.h
|
||||
%{_libdir}/*.so
|
||||
%{_mandir}/man3/*.gz
|
||||
%{_infodir}/libffi.info.gz
|
||||
|
||||
%changelog
|
||||
* Tue Apr 5 2016 Andrew Haley <aph@redhat.com> - 3.0.13-18
|
||||
- closures: Create temporary file with O_TMPFILE and O_CLOEXEC
|
||||
- Resolves: RHBZ1151568
|
||||
|
||||
* Tue Apr 5 2016 Andrew Haley <aph@redhat.com> - 3.0.13-17
|
||||
- libffi needs fix for structures not passed in registers
|
||||
- Resolves: RHBZ1287815
|
||||
|
||||
* Tue Sep 02 2014 Dan Horák <dhorak@redhat.com> - 3.0.13-16
|
||||
- Drop ppc64le from the multilib list
|
||||
- Use additional BR: only in ppc64le build
|
||||
- Resolves: RHBZ1116945
|
||||
|
||||
* Tue Aug 26 2014 Andrew Haley <aph@redhat.com> - 3.0.13-15
|
||||
- Add requires for libtool and texinfo
|
||||
- Resolves: RHBZ1116945
|
||||
|
||||
* Tue Aug 26 2014 Andrew Haley <aph@redhat.com> - 3.0.13-14
|
||||
- Add requires for automake
|
||||
- Resolves: RHBZ1116945
|
||||
|
||||
* Tue Aug 26 2014 Andrew Haley <aph@redhat.com> - 3.0.13-13
|
||||
- Add requires for autoconf
|
||||
- Resolves: RHBZ1116945
|
||||
|
||||
* Tue Aug 26 2014 Andrew Haley <aph@redhat.com> - 3.0.13-12
|
||||
- Merge from private-rhel-7.0-ppc64le branch
|
||||
- Resolves: RHBZ1116945
|
||||
|
||||
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 3.0.13-11
|
||||
- Mass rebuild 2014-01-24
|
||||
|
||||
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 3.0.13-10
|
||||
- Mass rebuild 2013-12-27
|
||||
|
||||
* Wed Dec 18 2013 Deepak Bhole <dbhole@redhat.com> - 3.0.13-9
|
||||
- Added -fno-strict-aliasing (pointed out by rpmdiff)
|
||||
- Fixes RHBZ 1006261
|
||||
|
||||
* Fri Nov 15 2013 Jon VanAlten <jon.vanalten@redhat.com> - 3.0.13-8
|
||||
- Patch test suite to fix errors on ppc64
|
||||
- Fixes RHBZ 1006261
|
||||
|
||||
* Thu Aug 22 2013 Deepak Bhole <dbhole@redhat.com> - 3.0.13-7
|
||||
- Removed temporarily introduced compat package for OpenJDk6 bootstrap
|
||||
|
||||
* Wed Aug 21 2013 Deepak Bhole <dbhole@redhat.com> - 3.0.13-6
|
||||
- Temporarily build with a .so.5 compat package to allow OpenJDK6 bootstrap
|
||||
|
||||
* Mon Jul 15 2013 Jon VanAlten <jon.vanalten@redhat.com> - 3.0.13-5
|
||||
- Correct spec license
|
||||
|
||||
* Tue May 28 2013 Tom Callaway <spot@fedoraproject.org> - 3.0.13-4
|
||||
- fix typos in wrapper headers
|
||||
|
||||
* Mon May 27 2013 Tom Callaway <spot@fedoraproject.org> - 3.0.13-3
|
||||
- make header files multilib safe
|
||||
|
||||
* Sat May 25 2013 Tom Callaway <spot@fedoraproject.org> - 3.0.13-2
|
||||
- fix incorrect header pathing (and .pc file)
|
||||
|
||||
* Wed Mar 20 2013 Anthony Green <green@redhat.com> - 3.0.13-1
|
||||
- update to 3.0.13
|
||||
|
||||
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.11-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||
|
||||
* Mon Jan 14 2013 Dennis Gilmore <dennis@ausil.us> - 3.0.11-1
|
||||
- update to 3.0.11
|
||||
|
||||
* Fri Nov 02 2012 Deepak Bhole <dbhole@redhat.com> - 3.0.10-4
|
||||
- Fixed source location
|
||||
|
||||
* Fri Aug 10 2012 Dennis Gilmore <dennis@ausil.us> - 3.0.10-3
|
||||
- drop back to 3.0.10, 3.0.11 was never pushed anywhere as the soname bump broke buildroots
|
||||
- as 3.0.11 never went out no epoch needed.
|
||||
|
||||
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.11-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||
|
||||
* Fri Apr 13 2012 Anthony Green <green@redhat.com> - 3.0.11-1
|
||||
- Upgrade to 3.0.11.
|
||||
|
||||
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.10-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
* Tue Aug 23 2011 Anthony Green <green@redhat.com> - 3.0.10-1
|
||||
- Upgrade to 3.0.10.
|
||||
|
||||
* Fri Mar 18 2011 Dan Horák <dan[at]danny.cz> - 3.0.9-3
|
||||
- added patch for being careful when defining relatively generic symbols
|
||||
|
||||
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.9-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
||||
|
||||
* Tue Dec 29 2009 Anthony Green <green@redhat.com> - 3.0.9-1
|
||||
- Upgrade
|
||||
|
||||
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.5-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
||||
|
||||
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.5-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
||||
|
||||
* Tue Jul 08 2008 Anthony Green <green@redhat.com> 3.0.5-1
|
||||
- Upgrade to 3.0.5
|
||||
|
||||
* Fri Feb 15 2008 Anthony Green <green@redhat.com> 3.0.1-1
|
||||
- Upgrade to 3.0.1
|
||||
|
||||
* Fri Feb 15 2008 Anthony Green <green@redhat.com> 2.99.9-1
|
||||
- Upgrade to 2.99.9
|
||||
- Require pkgconfig for the devel package.
|
||||
- Update summary.
|
||||
|
||||
* Fri Feb 15 2008 Anthony Green <green@redhat.com> 2.99.8-1
|
||||
- Upgrade to 2.99.8
|
||||
|
||||
* Thu Feb 14 2008 Anthony Green <green@redhat.com> 2.99.7-1
|
||||
- Upgrade to 2.99.7
|
||||
|
||||
* Thu Feb 14 2008 Anthony Green <green@redhat.com> 2.99.6-1
|
||||
- Upgrade to 2.99.6
|
||||
|
||||
* Thu Feb 14 2008 Anthony Green <green@redhat.com> 2.99.4-1
|
||||
- Upgrade to 2.99.4
|
||||
|
||||
* Thu Feb 14 2008 Anthony Green <green@redhat.com> 2.99.3-1
|
||||
- Upgrade to 2.99.3
|
||||
|
||||
* Thu Feb 14 2008 Anthony Green <green@redhat.com> 2.99.2-1
|
||||
- Created.
|
Loading…
Reference in New Issue