mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 19:50:05 +02:00
libffi: added recipe for version 3.2.1
This commit is contained in:
66
dev-libs/libffi/libffi-3.2.1.recipe
Normal file
66
dev-libs/libffi/libffi-3.2.1.recipe
Normal file
@@ -0,0 +1,66 @@
|
||||
SUMMARY="A portable, high level programming interface."
|
||||
DESCRIPTION="
|
||||
A portable, high level programming interface to various calling conventions.
|
||||
"
|
||||
HOMEPAGE="http://sourceware.org/libffi"
|
||||
LICENSE="MIT"
|
||||
REVISION="2"
|
||||
|
||||
ARCHITECTURES="x86_gcc2 x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
SRC_URI="ftp://sourceware.org/pub/libffi/libffi-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="d06ebb8e1d9a22d19e38d63fdb83954253f39bedc5d46232a05645685722ca37"
|
||||
COPYRIGHT="1996-2013 Anthony Green, Red Hat, Inc and others."
|
||||
PATCHES="libffi-$portVersion.patchset"
|
||||
|
||||
PROVIDES="
|
||||
libffi$secondaryArchSuffix = $portVersion compat >= 3
|
||||
lib:libffi$secondaryArchSuffix = 6.0.4 compat >= 6
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix >= $haikuVersion
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel >= $haikuVersion
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:awk
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
runConfigure ./configure
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
mkdir -p $includeDir
|
||||
mv -f $libDir/libffi-$portVersion/include/*.h* $includeDir
|
||||
rm -rf $libDir/libffi-$portVersion
|
||||
|
||||
prepareInstalledDevelLibs libffi
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir \
|
||||
$documentationDir
|
||||
}
|
||||
|
||||
PROVIDES_devel="
|
||||
libffi${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libffi$secondaryArchSuffix = 6.0.4 compat >= 6
|
||||
"
|
||||
|
||||
REQUIRES_devel="
|
||||
libffi$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
22
dev-libs/libffi/patches/libffi-3.2.1.patchset
Normal file
22
dev-libs/libffi/patches/libffi-3.2.1.patchset
Normal file
@@ -0,0 +1,22 @@
|
||||
From 7346bc44a1d1f47b38d556b0cc291fc948725042 Mon Sep 17 00:00:00 2001
|
||||
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
|
||||
Date: Sun, 21 Sep 2014 18:59:06 +0200
|
||||
Subject: gcc2 fix.
|
||||
|
||||
|
||||
diff --git a/include/ffi_common.h b/include/ffi_common.h
|
||||
index 650ca69..02a1913 100644
|
||||
--- a/include/ffi_common.h
|
||||
+++ b/include/ffi_common.h
|
||||
@@ -115,7 +115,7 @@ typedef signed int SINT64 __attribute__((__mode__(__DI__)));
|
||||
|
||||
typedef float FLOAT32;
|
||||
|
||||
-#ifndef __GNUC__
|
||||
+#if !defined(__GNUC__) || __GNUC__ < 3
|
||||
#define __builtin_expect(x, expected_value) (x)
|
||||
#endif
|
||||
#define LIKELY(x) __builtin_expect(!!(x),1)
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
Reference in New Issue
Block a user