View | Details | Raw Unified | Return to bug 122398 | Differences between
and this patch

Collapse All | Expand All

(-)b/devel/libffi/Makefile (-10 / +3 lines)
Lines 6-12 Link Here
6
#
6
#
7
7
8
PORTNAME=	libffi
8
PORTNAME=	libffi
9
PORTVERSION=	3.0.1
9
PORTVERSION=	3.0.4
10
CATEGORIES=	devel
10
CATEGORIES=	devel
11
MASTER_SITES=	ftp://sourceware.org/pub/libffi/
11
MASTER_SITES=	ftp://sourceware.org/pub/libffi/
12
12
Lines 15-32 COMMENT= Foreign Function Interface Link Here
15
15
16
GNU_CONFIGURE=	yes
16
GNU_CONFIGURE=	yes
17
USE_LDCONFIG=	yes
17
USE_LDCONFIG=	yes
18
USE_AUTOTOOLS=	automake:110 autoconf:261
18
USE_GNOME=	gnomehack gnometarget
19
PLIST_SUB=	PORTVERSION=${PORTVERSION}
19
20
20
INFO=		libffi
21
INFO=		libffi
21
22
22
MAN3=		ffi.3 ffi_call.3 ffi_prep_cif.3
23
MAN3=		ffi.3 ffi_call.3 ffi_prep_cif.3
23
24
24
pre-configure:
25
		@${REINPLACE_CMD} -e 's,^\(includesdir = \).*,\1$$(includedir),' \
26
			${WRKSRC}/include/Makefile.am
27
28
post-configure:
29
		@${REINPLACE_CMD} -e 's,^\(transform = \).*,\1,' \
30
			${WRKSRC}/man/Makefile
31
32
.include <bsd.port.mk>
25
.include <bsd.port.mk>
(-)b/devel/libffi/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
MD5 (libffi-3.0.1.tar.gz) = 6f6cea82a8dfe6126d207fd6113ad632
1
MD5 (libffi-3.0.4.tar.gz) = eea52a0f7929182da1f393d43ed231c5
2
SHA256 (libffi-3.0.1.tar.gz) = f68e16619b9eb67b1a0fbfcb4ae827f9154fece03ab35366f6896417bd021292
2
SHA256 (libffi-3.0.4.tar.gz) = 2f3ca5852a89115846eeff53e3cc26a1e298d2698e54c4f0671984791ab14d8a
3
SIZE (libffi-3.0.1.tar.gz) = 719044
3
SIZE (libffi-3.0.4.tar.gz) = 722782
(-)a/devel/libffi/files/patch-Makefile.am-new (-29 lines)
Removed Link Here
1
--- Makefile.am	2008-02-15 00:42:33.000000000 +0000
2
+++ Makefile.am	2008-02-21 01:50:41.000000000 +0000
3
@@ -26,6 +26,7 @@
4
 	src/sparc/v8.S src/sparc/v9.S src/sparc/ffitarget.h \
5
 	src/sparc/ffi.c src/x86/darwin64.S \
6
 	src/x86/ffi.c src/x86/sysv.S src/x86/win32.S src/x86/darwin.S \
7
+	src/x86/freebsd.S \
8
 	src/x86/ffi64.c src/x86/unix64.S src/x86/ffitarget.h \
9
 	src/pa/ffitarget.h src/pa/ffi.c src/pa/linux.S src/pa/hpux32.S \
10
 	src/frv/ffi.c src/frv/eabi.S src/frv/ffitarget.h src/dlmalloc.c \
11
@@ -84,7 +85,7 @@
12
 libffi_la_SOURCES = src/debug.c src/prep_cif.c src/types.c \
13
 		src/raw_api.c src/java_raw_api.c src/closures.c
14
 
15
-pkgconfigdir = $(libdir)/pkgconfig
16
+pkgconfigdir = $(prefix)/libdata/pkgconfig
17
 pkgconfig_DATA = libffi.pc
18
 
19
 nodist_libffi_la_SOURCES =
20
@@ -95,6 +96,9 @@
21
 if X86
22
 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/sysv.S
23
 endif
24
+if X86_FREEBSD
25
+nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/freebsd.S
26
+endif
27
 if X86_WIN32
28
 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/win32.S
29
 endif
(-)a/devel/libffi/files/patch-configure.ac (-31 lines)
Removed Link Here
1
--- configure.ac	2008-02-16 01:51:30.000000000 +0100
2
+++ configure.ac	2008-02-21 02:03:35.000000000 +0100
3
@@ -45,6 +45,10 @@
4
 	HAVE_LONG_DOUBLE='defined(__LONG_DOUBLE_128__)'
5
 	;;
6
 
7
+  amd64-*-freebsd*)
8
+	TARGET=X86_64; TARGETDIR=x86
9
+	;;
10
+
11
   arm*-*-*)
12
 	TARGET=ARM; TARGETDIR=arm
13
 	;;
14
@@ -67,6 +71,9 @@
15
 	TARGET=PA_HPUX; TARGETDIR=pa
16
 	;;
17
 
18
+  i386-*-freebsd*)
19
+	TARGET=X86_FREEBSD; TARGETDIR=x86
20
+	;;
21
   i?86-win32* | i?86-*-cygwin* | i?86-*-mingw*)
22
 	TARGET=X86_WIN32; TARGETDIR=x86
23
 	;;
24
@@ -152,6 +159,7 @@
25
 AM_CONDITIONAL(MIPS, test x$TARGET = xMIPS)
26
 AM_CONDITIONAL(SPARC, test x$TARGET = xSPARC)
27
 AM_CONDITIONAL(X86, test x$TARGET = xX86)
28
+AM_CONDITIONAL(X86_FREEBSD, test x$TARGET = xX86_FREEBSD)
29
 AM_CONDITIONAL(X86_WIN32, test x$TARGET = xX86_WIN32)
30
 AM_CONDITIONAL(X86_DARWIN, test x$TARGET = xX86_DARWIN)
31
 AM_CONDITIONAL(ALPHA, test x$TARGET = xALPHA)
(-)a/devel/libffi/files/patch-src-x86-freebsd.S (-460 lines)
Removed Link Here
1
--- src/x86/freebsd.S	1970-01-01 01:00:00.000000000 +0100
2
+++ src/x86/freebsd.S	2008-02-21 02:01:27.000000000 +0100
3
@@ -0,0 +1,457 @@
4
+/* -----------------------------------------------------------------------
5
+   freebsd.S - Copyright (c) 1996, 1998, 2001, 2002, 2003, 2005  Red Hat, Inc.
6
+   
7
+   X86 Foreign Function Interface 
8
+
9
+   Permission is hereby granted, free of charge, to any person obtaining
10
+   a copy of this software and associated documentation files (the
11
+   ``Software''), to deal in the Software without restriction, including
12
+   without limitation the rights to use, copy, modify, merge, publish,
13
+   distribute, sublicense, and/or sell copies of the Software, and to
14
+   permit persons to whom the Software is furnished to do so, subject to
15
+   the following conditions:
16
+
17
+   The above copyright notice and this permission notice shall be included
18
+   in all copies or substantial portions of the Software.
19
+
20
+   THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS
21
+   OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22
+   MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23
+   IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
24
+	ANY CLAIM, DAMAGES OR
25
+   OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
26
+   ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
27
+   OTHER DEALINGS IN THE SOFTWARE.
28
+   ----------------------------------------------------------------------- */
29
+
30
+#ifndef __x86_64__
31
+
32
+#define LIBFFI_ASM	
33
+#include <fficonfig.h>
34
+#include <ffi.h>
35
+
36
+.text
37
+
38
+.globl ffi_prep_args
39
+
40
+	.align 4
41
+.globl ffi_call_SYSV
42
+        .type    ffi_call_SYSV,@function
43
+
44
+ffi_call_SYSV:
45
+.LFB1:
46
+        pushl %ebp
47
+.LCFI0:
48
+        movl  %esp,%ebp
49
+.LCFI1:
50
+	/* Make room for all of the new args.  */
51
+	movl  16(%ebp),%ecx
52
+	subl  %ecx,%esp
53
+
54
+	movl  %esp,%eax
55
+
56
+	/* Place all of the ffi_prep_args in position  */
57
+	pushl 12(%ebp)
58
+	pushl %eax
59
+	call  *8(%ebp)
60
+
61
+	/* Return stack to previous state and call the function  */
62
+	addl  $8,%esp	
63
+
64
+	call  *28(%ebp)
65
+
66
+	/* Load %ecx with the return type code  */
67
+	movl  20(%ebp),%ecx	
68
+
69
+	/* Protect %esi.  We're going to pop it in the epilogue.  */
70
+	pushl %esi
71
+
72
+	/* If the return value pointer is NULL, assume no return value.  */
73
+	cmpl  $0,24(%ebp)
74
+	jne  0f
75
+
76
+	/* Even if there is no space for the return value, we are 
77
+	   obliged to handle floating-point values.  */
78
+	cmpl  $FFI_TYPE_FLOAT,%ecx
79
+	jne   noretval
80
+	fstp  %st(0)
81
+
82
+        jmp   epilogue
83
+
84
+0:
85
+	call  1f
86
+
87
+.Lstore_table:
88
+	.long	noretval-.Lstore_table	/* FFI_TYPE_VOID */
89
+	.long	retint-.Lstore_table	/* FFI_TYPE_INT */
90
+	.long	retfloat-.Lstore_table	/* FFI_TYPE_FLOAT */
91
+	.long	retdouble-.Lstore_table	/* FFI_TYPE_DOUBLE */
92
+	.long	retlongdouble-.Lstore_table	/* FFI_TYPE_LONGDOUBLE */
93
+	.long	retuint8-.Lstore_table	/* FFI_TYPE_UINT8 */
94
+	.long	retsint8-.Lstore_table	/* FFI_TYPE_SINT8 */
95
+	.long	retuint16-.Lstore_table	/* FFI_TYPE_UINT16 */
96
+	.long	retsint16-.Lstore_table	/* FFI_TYPE_SINT16 */
97
+	.long	retint-.Lstore_table	/* FFI_TYPE_UINT32 */
98
+	.long	retint-.Lstore_table	/* FFI_TYPE_SINT32 */
99
+	.long	retint64-.Lstore_table	/* FFI_TYPE_UINT64 */
100
+	.long	retint64-.Lstore_table	/* FFI_TYPE_SINT64 */
101
+	.long	retstruct-.Lstore_table	/* FFI_TYPE_STRUCT */
102
+	.long	retint-.Lstore_table	/* FFI_TYPE_POINTER */
103
+	.long   retstruct1b-.Lstore_table	/* FFI_TYPE_SMALL_STRUCT_1B */
104
+	.long   retstruct2b-.Lstore_table	/* FFI_TYPE_SMALL_STRUCT_2B */
105
+
106
+1:
107
+	pop  %esi
108
+	add  (%esi, %ecx, 4), %esi
109
+	jmp  *%esi
110
+
111
+	/* Sign/zero extend as appropriate.  */
112
+retsint8:
113
+	movsbl  %al, %eax
114
+	jmp  retint
115
+
116
+retsint16:
117
+	movswl  %ax, %eax
118
+	jmp  retint
119
+
120
+retuint8:
121
+	movzbl  %al, %eax
122
+	jmp  retint
123
+
124
+retuint16:
125
+	movzwl  %ax, %eax
126
+	jmp  retint
127
+
128
+retfloat:
129
+	/* Load %ecx with the pointer to storage for the return value  */
130
+	movl  24(%ebp),%ecx	
131
+	fstps (%ecx)
132
+	jmp   epilogue
133
+
134
+retdouble:
135
+	/* Load %ecx with the pointer to storage for the return value  */
136
+	movl  24(%ebp),%ecx	
137
+	fstpl (%ecx)
138
+	jmp   epilogue
139
+
140
+retlongdouble:
141
+	/* Load %ecx with the pointer to storage for the return value  */
142
+	movl  24(%ebp),%ecx	
143
+	fstpt (%ecx)
144
+	jmp   epilogue
145
+	
146
+retint64:	
147
+	/* Load %ecx with the pointer to storage for the return value  */
148
+	movl  24(%ebp),%ecx	
149
+	movl  %eax,0(%ecx)
150
+	movl  %edx,4(%ecx)
151
+	jmp   epilogue
152
+	
153
+retstruct1b:
154
+	/* Load %ecx with the pointer to storage for the return value  */
155
+	movl  24(%ebp),%ecx
156
+	movb  %al,0(%ecx)
157
+	jmp   epilogue
158
+
159
+retstruct2b:
160
+	/* Load %ecx with the pointer to storage for the return value  */
161
+	movl  24(%ebp),%ecx
162
+	movw  %ax,0(%ecx)
163
+	jmp   epilogue
164
+
165
+retint:
166
+	/* Load %ecx with the pointer to storage for the return value  */
167
+	movl  24(%ebp),%ecx	
168
+	movl  %eax,0(%ecx)
169
+
170
+retstruct:
171
+	/* Nothing to do!  */
172
+
173
+noretval:
174
+epilogue:
175
+        popl %esi
176
+        movl %ebp,%esp
177
+        popl %ebp
178
+        ret
179
+.LFE1:
180
+.ffi_call_SYSV_end:
181
+        .size    ffi_call_SYSV,.ffi_call_SYSV_end-ffi_call_SYSV
182
+
183
+	.align	4
184
+FFI_HIDDEN (ffi_closure_SYSV)
185
+.globl ffi_closure_SYSV
186
+	.type	ffi_closure_SYSV, @function
187
+
188
+ffi_closure_SYSV:
189
+.LFB2:
190
+	pushl	%ebp
191
+.LCFI2:
192
+	movl	%esp, %ebp
193
+.LCFI3:
194
+	subl	$40, %esp
195
+	leal	-24(%ebp), %edx
196
+	movl	%edx, -12(%ebp)	/* resp */
197
+	leal	8(%ebp), %edx
198
+	movl	%edx, 4(%esp)	/* args = __builtin_dwarf_cfa () */
199
+	leal	-12(%ebp), %edx
200
+	movl	%edx, (%esp)	/* &resp */
201
+#if defined HAVE_HIDDEN_VISIBILITY_ATTRIBUTE || !defined __PIC__
202
+	call	ffi_closure_SYSV_inner
203
+#else
204
+	movl	%ebx, 8(%esp)
205
+.LCFI7:
206
+	call	1f
207
+1:	popl	%ebx
208
+	addl	$_GLOBAL_OFFSET_TABLE_+[.-1b], %ebx
209
+	call	ffi_closure_SYSV_inner@PLT
210
+	movl	8(%esp), %ebx
211
+#endif
212
+	movl	-12(%ebp), %ecx
213
+	cmpl	$FFI_TYPE_INT, %eax
214
+	je	.Lcls_retint
215
+
216
+	/* Handle FFI_TYPE_UINT8, FFI_TYPE_SINT8, FFI_TYPE_UINT16,
217
+	   FFI_TYPE_SINT16, FFI_TYPE_UINT32, FFI_TYPE_SINT32.  */
218
+	cmpl	$FFI_TYPE_UINT64, %eax
219
+	jge	0f
220
+	cmpl	$FFI_TYPE_UINT8, %eax
221
+	jge	.Lcls_retint
222
+	
223
+0:	cmpl	$FFI_TYPE_FLOAT, %eax
224
+	je	.Lcls_retfloat
225
+	cmpl	$FFI_TYPE_DOUBLE, %eax
226
+	je	.Lcls_retdouble
227
+	cmpl	$FFI_TYPE_LONGDOUBLE, %eax
228
+	je	.Lcls_retldouble
229
+	cmpl	$FFI_TYPE_SINT64, %eax
230
+	je	.Lcls_retllong
231
+	cmpl	$FFI_TYPE_SMALL_STRUCT_1B, %eax
232
+	je	.Lcls_retstruct1b
233
+	cmpl	$FFI_TYPE_SMALL_STRUCT_2B, %eax
234
+	je	.Lcls_retstruct2b
235
+	cmpl	$FFI_TYPE_STRUCT, %eax
236
+	je	.Lcls_retstruct
237
+.Lcls_epilogue:
238
+	movl	%ebp, %esp
239
+	popl	%ebp
240
+	ret
241
+.Lcls_retint:
242
+	movl	(%ecx), %eax
243
+	jmp	.Lcls_epilogue
244
+.Lcls_retfloat:
245
+	flds	(%ecx)
246
+	jmp	.Lcls_epilogue
247
+.Lcls_retdouble:
248
+	fldl	(%ecx)
249
+	jmp	.Lcls_epilogue
250
+.Lcls_retldouble:
251
+	fldt	(%ecx)
252
+	jmp	.Lcls_epilogue
253
+.Lcls_retllong:
254
+	movl	(%ecx), %eax
255
+	movl	4(%ecx), %edx
256
+	jmp	.Lcls_epilogue
257
+.Lcls_retstruct1b:
258
+	movsbl	(%ecx), %eax
259
+	jmp	.Lcls_epilogue
260
+.Lcls_retstruct2b:
261
+	movswl	(%ecx), %eax
262
+	jmp	.Lcls_epilogue
263
+.Lcls_retstruct:
264
+	movl	%ebp, %esp
265
+	popl	%ebp
266
+	ret	$4
267
+.LFE2:
268
+	.size	ffi_closure_SYSV, .-ffi_closure_SYSV
269
+
270
+#if !FFI_NO_RAW_API
271
+
272
+#define RAW_CLOSURE_CIF_OFFSET ((FFI_TRAMPOLINE_SIZE + 3) & ~3)
273
+#define RAW_CLOSURE_FUN_OFFSET (RAW_CLOSURE_CIF_OFFSET + 4)
274
+#define RAW_CLOSURE_USER_DATA_OFFSET (RAW_CLOSURE_FUN_OFFSET + 4)
275
+#define CIF_FLAGS_OFFSET 20
276
+
277
+	.align	4
278
+FFI_HIDDEN (ffi_closure_raw_SYSV)
279
+.globl ffi_closure_raw_SYSV
280
+	.type	ffi_closure_raw_SYSV, @function
281
+
282
+ffi_closure_raw_SYSV:
283
+.LFB3:
284
+	pushl	%ebp
285
+.LCFI4:
286
+	movl	%esp, %ebp
287
+.LCFI5:
288
+	pushl	%esi
289
+.LCFI6:
290
+	subl	$36, %esp
291
+	movl	RAW_CLOSURE_CIF_OFFSET(%eax), %esi	 /* closure->cif */
292
+	movl	RAW_CLOSURE_USER_DATA_OFFSET(%eax), %edx /* closure->user_data */
293
+	movl	%edx, 12(%esp)	/* user_data */
294
+	leal	8(%ebp), %edx	/* __builtin_dwarf_cfa () */
295
+	movl	%edx, 8(%esp)	/* raw_args */
296
+	leal	-24(%ebp), %edx
297
+	movl	%edx, 4(%esp)	/* &res */
298
+	movl	%esi, (%esp)	/* cif */
299
+	call	*RAW_CLOSURE_FUN_OFFSET(%eax)		 /* closure->fun */
300
+	movl	CIF_FLAGS_OFFSET(%esi), %eax		 /* rtype */
301
+	cmpl	$FFI_TYPE_INT, %eax
302
+	je	.Lrcls_retint
303
+
304
+	/* Handle FFI_TYPE_UINT8, FFI_TYPE_SINT8, FFI_TYPE_UINT16,
305
+	   FFI_TYPE_SINT16, FFI_TYPE_UINT32, FFI_TYPE_SINT32.  */
306
+	cmpl	$FFI_TYPE_UINT64, %eax
307
+	jge	0f
308
+	cmpl	$FFI_TYPE_UINT8, %eax
309
+	jge	.Lrcls_retint
310
+0:
311
+	cmpl	$FFI_TYPE_FLOAT, %eax
312
+	je	.Lrcls_retfloat
313
+	cmpl	$FFI_TYPE_DOUBLE, %eax
314
+	je	.Lrcls_retdouble
315
+	cmpl	$FFI_TYPE_LONGDOUBLE, %eax
316
+	je	.Lrcls_retldouble
317
+	cmpl	$FFI_TYPE_SINT64, %eax
318
+	je	.Lrcls_retllong
319
+.Lrcls_epilogue:
320
+	addl	$36, %esp
321
+	popl	%esi
322
+	popl	%ebp
323
+	ret
324
+.Lrcls_retint:
325
+	movl	-24(%ebp), %eax
326
+	jmp	.Lrcls_epilogue
327
+.Lrcls_retfloat:
328
+	flds	-24(%ebp)
329
+	jmp	.Lrcls_epilogue
330
+.Lrcls_retdouble:
331
+	fldl	-24(%ebp)
332
+	jmp	.Lrcls_epilogue
333
+.Lrcls_retldouble:
334
+	fldt	-24(%ebp)
335
+	jmp	.Lrcls_epilogue
336
+.Lrcls_retllong:
337
+	movl	-24(%ebp), %eax
338
+	movl	-20(%ebp), %edx
339
+	jmp	.Lrcls_epilogue
340
+.LFE3:
341
+	.size	ffi_closure_raw_SYSV, .-ffi_closure_raw_SYSV
342
+#endif
343
+
344
+	.section	.eh_frame,EH_FRAME_FLAGS,@progbits
345
+.Lframe1:
346
+	.long	.LECIE1-.LSCIE1	/* Length of Common Information Entry */
347
+.LSCIE1:
348
+	.long	0x0	/* CIE Identifier Tag */
349
+	.byte	0x1	/* CIE Version */
350
+#ifdef __PIC__
351
+	.ascii "zR\0"	/* CIE Augmentation */
352
+#else
353
+	.ascii "\0"	/* CIE Augmentation */
354
+#endif
355
+	.byte	0x1	/* .uleb128 0x1; CIE Code Alignment Factor */
356
+	.byte	0x7c	/* .sleb128 -4; CIE Data Alignment Factor */
357
+	.byte	0x8	/* CIE RA Column */
358
+#ifdef __PIC__
359
+	.byte	0x1	/* .uleb128 0x1; Augmentation size */
360
+	.byte	0x1b	/* FDE Encoding (pcrel sdata4) */
361
+#endif
362
+	.byte	0xc	/* DW_CFA_def_cfa */
363
+	.byte	0x4	/* .uleb128 0x4 */
364
+	.byte	0x4	/* .uleb128 0x4 */
365
+	.byte	0x88	/* DW_CFA_offset, column 0x8 */
366
+	.byte	0x1	/* .uleb128 0x1 */
367
+	.align 4
368
+.LECIE1:
369
+.LSFDE1:
370
+	.long	.LEFDE1-.LASFDE1	/* FDE Length */
371
+.LASFDE1:
372
+	.long	.LASFDE1-.Lframe1	/* FDE CIE offset */
373
+#ifdef __PIC__
374
+	.long	.LFB1-.	/* FDE initial location */
375
+#else
376
+	.long	.LFB1	/* FDE initial location */
377
+#endif
378
+	.long	.LFE1-.LFB1	/* FDE address range */
379
+#ifdef __PIC__
380
+	.byte	0x0	/* .uleb128 0x0; Augmentation size */
381
+#endif
382
+	.byte	0x4	/* DW_CFA_advance_loc4 */
383
+	.long	.LCFI0-.LFB1
384
+	.byte	0xe	/* DW_CFA_def_cfa_offset */
385
+	.byte	0x8	/* .uleb128 0x8 */
386
+	.byte	0x85	/* DW_CFA_offset, column 0x5 */
387
+	.byte	0x2	/* .uleb128 0x2 */
388
+	.byte	0x4	/* DW_CFA_advance_loc4 */
389
+	.long	.LCFI1-.LCFI0
390
+	.byte	0xd	/* DW_CFA_def_cfa_register */
391
+	.byte	0x5	/* .uleb128 0x5 */
392
+	.align 4
393
+.LEFDE1:
394
+.LSFDE2:
395
+	.long	.LEFDE2-.LASFDE2	/* FDE Length */
396
+.LASFDE2:
397
+	.long	.LASFDE2-.Lframe1	/* FDE CIE offset */
398
+#ifdef __PIC__
399
+	.long	.LFB2-.	/* FDE initial location */
400
+#else
401
+	.long	.LFB2
402
+#endif
403
+	.long	.LFE2-.LFB2	/* FDE address range */
404
+#ifdef __PIC__
405
+	.byte	0x0	/* .uleb128 0x0; Augmentation size */
406
+#endif
407
+	.byte	0x4	/* DW_CFA_advance_loc4 */
408
+	.long	.LCFI2-.LFB2
409
+	.byte	0xe	/* DW_CFA_def_cfa_offset */
410
+	.byte	0x8	/* .uleb128 0x8 */
411
+	.byte	0x85	/* DW_CFA_offset, column 0x5 */
412
+	.byte	0x2	/* .uleb128 0x2 */
413
+	.byte	0x4	/* DW_CFA_advance_loc4 */
414
+	.long	.LCFI3-.LCFI2
415
+	.byte	0xd	/* DW_CFA_def_cfa_register */
416
+	.byte	0x5	/* .uleb128 0x5 */
417
+#if !defined HAVE_HIDDEN_VISIBILITY_ATTRIBUTE && defined __PIC__
418
+	.byte	0x4	/* DW_CFA_advance_loc4 */
419
+	.long	.LCFI7-.LCFI3
420
+	.byte	0x83	/* DW_CFA_offset, column 0x3 */
421
+	.byte	0xa	/* .uleb128 0xa */
422
+#endif
423
+	.align 4
424
+.LEFDE2:
425
+
426
+#if !FFI_NO_RAW_API
427
+
428
+.LSFDE3:
429
+	.long	.LEFDE3-.LASFDE3	/* FDE Length */
430
+.LASFDE3:
431
+	.long	.LASFDE3-.Lframe1	/* FDE CIE offset */
432
+#ifdef __PIC__
433
+	.long	.LFB3-.	/* FDE initial location */
434
+#else
435
+	.long	.LFB3
436
+#endif
437
+	.long	.LFE3-.LFB3	/* FDE address range */
438
+#ifdef __PIC__
439
+	.byte	0x0	/* .uleb128 0x0; Augmentation size */
440
+#endif
441
+	.byte	0x4	/* DW_CFA_advance_loc4 */
442
+	.long	.LCFI4-.LFB3
443
+	.byte	0xe	/* DW_CFA_def_cfa_offset */
444
+	.byte	0x8	/* .uleb128 0x8 */
445
+	.byte	0x85	/* DW_CFA_offset, column 0x5 */
446
+	.byte	0x2	/* .uleb128 0x2 */
447
+	.byte	0x4	/* DW_CFA_advance_loc4 */
448
+	.long	.LCFI5-.LCFI4
449
+	.byte	0xd	/* DW_CFA_def_cfa_register */
450
+	.byte	0x5	/* .uleb128 0x5 */
451
+	.byte	0x4	/* DW_CFA_advance_loc4 */
452
+	.long	.LCFI6-.LCFI5
453
+	.byte	0x86	/* DW_CFA_offset, column 0x6 */
454
+	.byte	0x3	/* .uleb128 0x3 */
455
+	.align 4
456
+.LEFDE3:
457
+
458
+#endif
459
+
460
+#endif /* ifndef __x86_64__ */
(-)b/devel/libffi/files/patch-src_arm_sysv.S (+73 lines)
Added Link Here
1
--- src/arm/sysv.S.orig	2008-02-15 02:15:41.000000000 +0100
2
+++ src/arm/sysv.S	2008-04-01 13:25:02.000000000 +0200
3
@@ -83,14 +83,6 @@
4
 # define call_reg(x)	mov	lr, pc ; mov	pc, x
5
 #endif
6
 
7
-/* Conditionally compile unwinder directives.  */
8
-#ifdef __ARM_EABI__
9
-#define UNWIND
10
-#else
11
-#define UNWIND @
12
-#endif	
13
-
14
-	
15
 #if defined(__thumb__) && !defined(__THUMB_INTERWORK__)
16
 .macro	ARM_FUNC_START name
17
 	.text
18
@@ -101,7 +93,6 @@
19
 	bx	pc
20
 	nop
21
 	.arm
22
-	UNWIND .fnstart
23
 /* A hook to tell gdb that we've switched to ARM mode.  Also used to call
24
    directly from other local arm routines.  */
25
 _L__\name:		
26
@@ -112,7 +103,6 @@
27
 	.align 0
28
 	.arm
29
 	ENTRY(\name)
30
-	UNWIND .fnstart
31
 .endm
32
 #endif
33
 
34
@@ -145,11 +135,8 @@
35
 ARM_FUNC_START ffi_call_SYSV
36
 	@ Save registers
37
         stmfd	sp!, {r0-r3, fp, lr}
38
-	UNWIND .save	{r0-r3, fp, lr}
39
 	mov	fp, sp
40
 
41
-	UNWIND .setfp	fp, sp
42
-
43
 	@ Make room for all of the new args.
44
 	sub	sp, fp, r2
45
 
46
@@ -219,7 +206,6 @@
47
 	RETLDM	"r0-r3,fp"
48
 
49
 .ffi_call_SYSV_end:
50
-	UNWIND .fnend
51
         .size    CNAME(ffi_call_SYSV),.ffi_call_SYSV_end-CNAME(ffi_call_SYSV)
52
 
53
 /*
54
@@ -231,12 +217,9 @@
55
 */
56
 
57
 ARM_FUNC_START ffi_closure_SYSV
58
-	UNWIND .pad #16
59
 	add	ip, sp, #16
60
 	stmfd	sp!, {ip, lr}
61
-	UNWIND .save	{r0, lr}
62
 	add	r2, sp, #8
63
-	.pad #16
64
 	sub	sp, sp, #16
65
 	str	sp, [sp, #8]
66
 	add	r1, sp, #8
67
@@ -291,6 +274,5 @@
68
 #endif
69
 
70
 .ffi_closure_SYSV_end:
71
-	UNWIND .fnend
72
         .size    CNAME(ffi_closure_SYSV),.ffi_closure_SYSV_end-CNAME(ffi_closure_SYSV)
73
 
(-)b/devel/libffi/pkg-plist (-2 / +2 lines)
Lines 1-5 Link Here
1
include/ffi.h
1
lib/libffi-%%PORTVERSION%%/include/ffi.h
2
include/ffitarget.h
2
lib/libffi-%%PORTVERSION%%/include/ffitarget.h
3
lib/libffi.a
3
lib/libffi.a
4
lib/libffi.la
4
lib/libffi.la
5
lib/libffi.so
5
lib/libffi.so

Return to bug 122398