Page MenuHomeFreeBSD

D25163.id73099.diff
No OneTemporary

D25163.id73099.diff

Index: Mk/Uses/cabal.mk
===================================================================
--- Mk/Uses/cabal.mk
+++ Mk/Uses/cabal.mk
@@ -70,7 +70,7 @@
iconv_ARGS= translit
.include "${USESDIR}/iconv.mk"
LIB_DEPENDS+= libgmp.so:math/gmp \
- libffi.so.6:devel/libffi
+ libffi.so:devel/libffi
DIST_SUBDIR?= cabal
Index: devel/libffi/Makefile
===================================================================
--- devel/libffi/Makefile
+++ devel/libffi/Makefile
@@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= libffi
-PORTVERSION= 3.2.1
-PORTREVISION= 3
+PORTVERSION= 3.3
CATEGORIES= devel
MASTER_SITES= SOURCEWARE/${PORTNAME}
@@ -15,23 +14,17 @@
TEST_DEPENDS= runtest:misc/dejagnu
-USES= libtool pathfix
+USES= gmake libtool pathfix
USE_LDCONFIG= yes
GNU_CONFIGURE= yes
+CONFIGURE_ARGS= --disable-multi-os-directory
INSTALL_TARGET= install-strip
INFO= libffi
-PLIST_SUB= PORTVERSION=${PORTVERSION}
TEST_TARGET= check
post-patch:
@${REINPLACE_CMD} -e 's| -Wno-psabi||g' \
${WRKSRC}/testsuite/lib/libffi.exp
-post-install:
- @${LN} -sf ../lib/libffi-${PORTVERSION}/include/ffi.h \
- ${STAGEDIR}${PREFIX}/include/
- @${LN} -sf ../lib/libffi-${PORTVERSION}/include/ffitarget.h \
- ${STAGEDIR}${PREFIX}/include/
-
.include <bsd.port.mk>
Index: devel/libffi/distinfo
===================================================================
--- devel/libffi/distinfo
+++ devel/libffi/distinfo
@@ -1,2 +1,3 @@
-SHA256 (libffi-3.2.1.tar.gz) = d06ebb8e1d9a22d19e38d63fdb83954253f39bedc5d46232a05645685722ca37
-SIZE (libffi-3.2.1.tar.gz) = 940837
+TIMESTAMP = 1575540897
+SHA256 (libffi-3.3.tar.gz) = 72fba7922703ddfa7a028d513ac15a85c8d54c8d67f55fa5a4802885dc652056
+SIZE (libffi-3.3.tar.gz) = 1305466
Index: devel/libffi/files/patch-b5ade2
===================================================================
--- devel/libffi/files/patch-b5ade2
+++ /dev/null
@@ -1,112 +0,0 @@
-# Clang doesn't like the -Wno-psabi argument that we want to pass to GCC.
-# Since clang is detected as GCC via __GNUC__, use ax_cv_c_compiler_vendor.
-# https://github.com/atgreen/libffi/commit/b5ade2fb5d9ba06519484677a5474e5dad48c2e3
-
-diff --git a/testsuite/lib/libffi.exp b/testsuite/lib/libffi.exp
-index 5051d31..0e92bb0 100644
---- testsuite/lib/libffi.exp
-+++ testsuite/lib/libffi.exp
-@@ -100,46 +100,39 @@ proc libffi-init { args } {
- global libffi_link_flags
- global tool_root_dir
- global ld_library_path
--
-- global using_gcc
-+ global compiler_vendor
-
- set blddirffi [pwd]/..
- verbose "libffi $blddirffi"
-
-- # Are we building with GCC?
-- set tmp [grep ../config.status "GCC='yes'"]
-- if { [string match $tmp "GCC='yes'"] } {
--
-- set using_gcc "yes"
-+ # Which compiler are we building with?
-+ set tmp [grep ../config.log "^ax_cv_c_compiler_vendor.*$"]
-+ regexp -- {^[^=]*=(.*)$} $tmp nil compiler_vendor
-
-- set gccdir [lookfor_file $tool_root_dir gcc/libgcc.a]
-- if {$gccdir != ""} {
-- set gccdir [file dirname $gccdir]
-- }
-- verbose "gccdir $gccdir"
--
-- set ld_library_path "."
-- append ld_library_path ":${gccdir}"
--
-- set compiler "${gccdir}/xgcc"
-- if { [is_remote host] == 0 && [which $compiler] != 0 } {
-- foreach i "[exec $compiler --print-multi-lib]" {
-- set mldir ""
-- regexp -- "\[a-z0-9=_/\.-\]*;" $i mldir
-- set mldir [string trimright $mldir "\;@"]
-- if { "$mldir" == "." } {
-- continue
-- }
-- if { [llength [glob -nocomplain ${gccdir}/${mldir}/libgcc_s*.so.*]] >= 1 } {
-- append ld_library_path ":${gccdir}/${mldir}"
-+ if { [string match $compiler_vendor "gnu"] } {
-+ set gccdir [lookfor_file $tool_root_dir gcc/libgcc.a]
-+ if {$gccdir != ""} {
-+ set gccdir [file dirname $gccdir]
-+ }
-+ verbose "gccdir $gccdir"
-+
-+ set ld_library_path "."
-+ append ld_library_path ":${gccdir}"
-+
-+ set compiler "${gccdir}/xgcc"
-+ if { [is_remote host] == 0 && [which $compiler] != 0 } {
-+ foreach i "[exec $compiler --print-multi-lib]" {
-+ set mldir ""
-+ regexp -- "\[a-z0-9=_/\.-\]*;" $i mldir
-+ set mldir [string trimright $mldir "\;@"]
-+ if { "$mldir" == "." } {
-+ continue
-+ }
-+ if { [llength [glob -nocomplain ${gccdir}/${mldir}/libgcc_s*.so.*]] >= 1 } {
-+ append ld_library_path ":${gccdir}/${mldir}"
-+ }
- }
-- }
-- }
--
-- } else {
--
-- set using_gcc "no"
--
-+ }
- }
-
- # add the library path for libffi.
-@@ -278,18 +271,25 @@ proc libffi-dg-runtest { testcases default-extra-flags } {
- }
-
- proc run-many-tests { testcases extra_flags } {
-- global using_gcc
-- if { [string match $using_gcc "yes"] } {
-+ global compiler_vendor
-+ switch $compiler_vendor {
-+ "clang" {
-+ set common "-W -Wall"
-+ set optimizations { "-O0" "-O1" "-O2" "-O3" "-Os" }
-+ }
-+ "gnu" {
- set common "-W -Wall -Wno-psabi"
- set optimizations { "-O0" "-O2" "-O3" "-Os" "-O2 -fomit-frame-pointer" }
-- } else {
-+ }
-+ default {
- # Assume we are using the vendor compiler.
- set common ""
- set optimizations { "" }
-+ }
- }
-
- set targetabis { "" }
-- if [string match $using_gcc "yes"] {
-+ if [string match $compiler_vendor "gnu"] {
- if [istarget "i?86-*-*"] {
- set targetabis {
- ""
Index: devel/libffi/files/patch-configure
===================================================================
--- devel/libffi/files/patch-configure
+++ /dev/null
@@ -1,124 +0,0 @@
---- configure.orig 2014-11-12 11:59:57 UTC
-+++ configure
-@@ -17221,7 +17221,7 @@ case "$host" in
- mips-sgi-irix5.* | mips-sgi-irix6.* | mips*-*-rtems*)
- TARGET=MIPS; TARGETDIR=mips
- ;;
-- mips*-*linux* | mips*-*-openbsd*)
-+ mips*-*linux* | mips*-*-openbsd* | mips*-*-freebsd*)
- # Support 128-bit long double for NewABI.
- HAVE_LONG_DOUBLE='defined(__mips64)'
- TARGET=MIPS; TARGETDIR=mips
-@@ -17255,6 +17255,10 @@ case "$host" in
- TARGET=POWERPC_FREEBSD; TARGETDIR=powerpc
- HAVE_LONG_DOUBLE_VARIANT=1
- ;;
-+ powerpcspe-*-freebsd*)
-+ TARGET=POWERPC_FREEBSD; TARGETDIR=powerpc
-+ CFLAGS="$CFLAGS -D__NO_FPRS__"
-+ ;;
- powerpc64-*-freebsd*)
- TARGET=POWERPC; TARGETDIR=powerpc
- ;;
-@@ -18289,7 +18293,8 @@ $as_echo "#define HAVE_AS_CFI_PSEUDO_OP 1" >>confdefs.
- fi
-
-
--if test x$TARGET = xSPARC; then
-+case "$TARGET" in
-+ SPARC)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler and linker support unaligned pc related relocs" >&5
- $as_echo_n "checking assembler and linker support unaligned pc related relocs... " >&6; }
- if ${libffi_cv_as_sparc_ua_pcrel+:} false; then :
-@@ -18363,9 +18368,9 @@ $as_echo "$libffi_cv_as_register_pseudo_op" >&6; }
- $as_echo "#define HAVE_AS_REGISTER_PSEUDO_OP 1" >>confdefs.h
-
- fi
--fi
-+ ;;
-
--if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64; then
-+ X86*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler supports pc related relocs" >&5
- $as_echo_n "checking assembler supports pc related relocs... " >&6; }
- if ${libffi_cv_as_x86_pcrel+:} false; then :
-@@ -18386,77 +18391,8 @@ $as_echo "$libffi_cv_as_x86_pcrel" >&6; }
- $as_echo "#define HAVE_AS_X86_PCREL 1" >>confdefs.h
-
- fi
--
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler .ascii pseudo-op support" >&5
--$as_echo_n "checking assembler .ascii pseudo-op support... " >&6; }
--if ${libffi_cv_as_ascii_pseudo_op+:} false; then :
-- $as_echo_n "(cached) " >&6
--else
--
-- libffi_cv_as_ascii_pseudo_op=unknown
-- # Check if we have .ascii
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--
--int
--main ()
--{
--asm (".ascii \\"string\\"");
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_compile "$LINENO"; then :
-- libffi_cv_as_ascii_pseudo_op=yes
--else
-- libffi_cv_as_ascii_pseudo_op=no
--fi
--rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
--
--fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libffi_cv_as_ascii_pseudo_op" >&5
--$as_echo "$libffi_cv_as_ascii_pseudo_op" >&6; }
-- if test "x$libffi_cv_as_ascii_pseudo_op" = xyes; then
--
--$as_echo "#define HAVE_AS_ASCII_PSEUDO_OP 1" >>confdefs.h
--
-- fi
--
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler .string pseudo-op support" >&5
--$as_echo_n "checking assembler .string pseudo-op support... " >&6; }
--if ${libffi_cv_as_string_pseudo_op+:} false; then :
-- $as_echo_n "(cached) " >&6
--else
--
-- libffi_cv_as_string_pseudo_op=unknown
-- # Check if we have .string
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--
--int
--main ()
--{
--asm (".string \\"string\\"");
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_compile "$LINENO"; then :
-- libffi_cv_as_string_pseudo_op=yes
--else
-- libffi_cv_as_string_pseudo_op=no
--fi
--rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
--
--fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libffi_cv_as_string_pseudo_op" >&5
--$as_echo "$libffi_cv_as_string_pseudo_op" >&6; }
-- if test "x$libffi_cv_as_string_pseudo_op" = xyes; then
--
--$as_echo "#define HAVE_AS_STRING_PSEUDO_OP 1" >>confdefs.h
--
-- fi
--fi
-+ ;;
-+esac
-
- # On PaX enable kernels that have MPROTECT enable we can't use PROT_EXEC.
- # Check whether --enable-pax_emutramp was given.
Index: devel/libffi/files/patch-configure.host
===================================================================
--- /dev/null
+++ devel/libffi/files/patch-configure.host
@@ -0,0 +1,22 @@
+--- configure.host.orig 2019-11-22 23:55:36 UTC
++++ configure.host
+@@ -167,7 +167,7 @@ case "${host}" in
+ mips-sgi-irix5.* | mips-sgi-irix6.* | mips*-*-rtems*)
+ TARGET=MIPS; TARGETDIR=mips
+ ;;
+- mips*-*linux* | mips*-*-openbsd*)
++ mips*-*linux* | mips*-*-openbsd* | mips*-*-freebsd*)
+ # Support 128-bit long double for NewABI.
+ HAVE_LONG_DOUBLE='defined(__mips64)'
+ TARGET=MIPS; TARGETDIR=mips
+@@ -202,6 +202,10 @@ case "${host}" in
+ powerpc-*-freebsd* | powerpc-*-openbsd* | powerpc-*-netbsd*)
+ TARGET=POWERPC_FREEBSD; TARGETDIR=powerpc
+ HAVE_LONG_DOUBLE_VARIANT=1
++ ;;
++ powerpcspe-*-freebsd*)
++ TARGET=POWERPC_FREEBSD; TARGETDIR=powerpc
++ CFLAGS="$CFLAGS -D__NO_FPRS__"
+ ;;
+ powerpc64-*-freebsd*)
+ TARGET=POWERPC; TARGETDIR=powerpc
Index: devel/libffi/files/patch-src__arm__ffi.c
===================================================================
--- devel/libffi/files/patch-src__arm__ffi.c
+++ devel/libffi/files/patch-src__arm__ffi.c
@@ -3,11 +3,11 @@
# PR: ports/149167 ports/184517
# Patch by: cognet@ (to be upstreamed @ LLVM)
---- ./src/arm/ffi.c.orig 2013-03-16 22:19:39.000000000 +1100
-+++ ./src/arm/ffi.c 2013-12-03 19:30:58.440924300 +1100
-@@ -33,6 +33,11 @@
-
- #include <stdlib.h>
+--- src/arm/ffi.c.orig 2019-10-31 14:49:54 UTC
++++ src/arm/ffi.c
+@@ -55,6 +55,11 @@ extern unsigned int ffi_arm_trampoline[3] FFI_HIDDEN;
+ #endif
+ #endif
+#if defined(__FreeBSD__) && defined(__arm__)
+#include <sys/types.h>
@@ -15,12 +15,13 @@
+#endif
+
/* Forward declares. */
- static int vfp_type_p (ffi_type *);
+ static int vfp_type_p (const ffi_type *);
static void layout_vfp_args (ffi_cif *);
-@@ -582,6 +587,16 @@
-
- #else
+@@ -568,6 +573,16 @@ void ffi_go_closure_SYSV (void) FFI_HIDDEN;
+ void ffi_go_closure_VFP (void) FFI_HIDDEN;
+ /* the cif must already be prep'ed */
++
+#if defined(__FreeBSD__) && defined(__arm__)
+#define __clear_cache(start, end) do { \
+ struct arm_sync_icache_args ua; \
@@ -30,7 +31,6 @@
+ sysarch(ARM_SYNC_ICACHE, &ua); \
+ } while (0);
+#endif
-+
- #define FFI_INIT_TRAMPOLINE(TRAMP,FUN,CTX) \
- ({ unsigned char *__tramp = (unsigned char*)(TRAMP); \
- unsigned int __fun = (unsigned int)(FUN); \
+
+ ffi_status
+ ffi_prep_closure_loc (ffi_closure * closure,
Index: devel/libffi/files/patch-src_arm_sysv.S
===================================================================
--- devel/libffi/files/patch-src_arm_sysv.S
+++ /dev/null
@@ -1,55 +0,0 @@
-# Description: 3.2.1 fails to build with clang 3.5.0 on arm
-# Issue ID: https://github.com/atgreen/libffi/issues/162
-# Submitted by: sbruno
-
---- src/arm/sysv.S.orig 2015-01-01 10:47:51 UTC
-+++ src/arm/sysv.S
-@@ -360,7 +360,7 @@ ARM_FUNC_START(ffi_call_VFP)
- cmp r0, #3
- sub ip, fp, #64
- flddle d0, [ip]
-- fldmiadgt ip, {d0-d7}
-+ vldmiagt ip, {d0-d7}
-
- LSYM(Lbase_args):
- @ move first 4 parameters in registers
-@@ -396,7 +396,7 @@ LSYM(Lbase_args):
- beq LSYM(Lepilogue_vfp)
-
- cmp r3, #FFI_TYPE_SINT64
-- stmeqia r2, {r0, r1}
-+ stmiaeq r2, {r0, r1}
- beq LSYM(Lepilogue_vfp)
-
- cmp r3, #FFI_TYPE_FLOAT
-@@ -409,7 +409,7 @@ LSYM(Lbase_args):
-
- cmp r3, #FFI_TYPE_STRUCT_VFP_FLOAT
- cmpne r3, #FFI_TYPE_STRUCT_VFP_DOUBLE
-- fstmiadeq r2, {d0-d3}
-+ vstmiaeq r2, {d0-d3}
-
- LSYM(Lepilogue_vfp):
- RETLDM "r0-r3,fp"
-@@ -420,7 +420,7 @@ LSYM(Lepilogue_vfp):
-
-
- ARM_FUNC_START(ffi_closure_VFP)
-- fstmfdd sp!, {d0-d7}
-+ vstmdb sp!, {d0-d7}
- @ r0-r3, then d0-d7
- UNWIND .pad #80
- add ip, sp, #80
-@@ -470,10 +470,10 @@ ARM_FUNC_START(ffi_closure_VFP)
- ldmia sp, {r0, r1}
- b .Lclosure_epilogue_vfp
- .Lretfloat_struct_vfp:
-- fldmiad sp, {d0-d1}
-+ vldmia sp, {d0-d1}
- b .Lclosure_epilogue_vfp
- .Lretdouble_struct_vfp:
-- fldmiad sp, {d0-d3}
-+ vldmia sp, {d0-d3}
- b .Lclosure_epilogue_vfp
-
- .ffi_closure_VFP_end:
Index: devel/libffi/pkg-descr
===================================================================
--- devel/libffi/pkg-descr
+++ devel/libffi/pkg-descr
@@ -3,4 +3,4 @@
call any function specified by a call interface description at run
time.
-WWW: http://sources.redhat.com/libffi/
+WWW: https://sourceware.org/libffi/
Index: devel/libffi/pkg-plist
===================================================================
--- devel/libffi/pkg-plist
+++ devel/libffi/pkg-plist
@@ -1,11 +1,9 @@
include/ffi.h
include/ffitarget.h
-lib/libffi-%%PORTVERSION%%/include/ffi.h
-lib/libffi-%%PORTVERSION%%/include/ffitarget.h
lib/libffi.a
lib/libffi.so
-lib/libffi.so.6
-lib/libffi.so.6.0.4
+lib/libffi.so.7
+lib/libffi.so.7.1.0
libdata/pkgconfig/libffi.pc
man/man3/ffi.3.gz
man/man3/ffi_call.3.gz
Index: java/bootstrap-openjdk8/Makefile
===================================================================
--- java/bootstrap-openjdk8/Makefile
+++ java/bootstrap-openjdk8/Makefile
@@ -36,7 +36,7 @@
.include <bsd.port.pre.mk>
.if ${ARCH} == aarch64 || ${ARCH:Marmv*}
-RUN_DEPENDS+= ${LOCALBASE}/lib/libffi.so.6:devel/libffi
+RUN_DEPENDS+= ${LOCALBASE}/lib/libffi.so:devel/libffi
.endif
.if defined(PPC_ABI) && ${PPC_ABI} == ELFv2
Index: lang/ghc/Makefile
===================================================================
--- lang/ghc/Makefile
+++ lang/ghc/Makefile
@@ -56,7 +56,7 @@
ffi-includes=${LOCALBASE}/include \
ffi-libraries=${LOCALBASE}/lib
# The version number is needed as lang/gcc installs a different version
-DYNAMIC_LIB_DEPENDS= libffi.so.6:devel/libffi
+DYNAMIC_LIB_DEPENDS= libffi.so:devel/libffi
DYNAMIC_SUB_LIST= WITH_DYNAMIC="YES"
DYNAMIC_SUB_LIST_OFF= WITH_DYNAMIC="NO"

File Metadata

Mime Type
text/plain
Expires
Sat, Jul 11, 12:42 AM (16 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
34944914
Default Alt Text
D25163.id73099.diff (14 KB)

Event Timeline