Fix fcntl(2) support on 64-bit platforms (alpha, amd64, sparc64).
This makes "cvsup -l" work on them in particular. PR: ports/75015 Approved by: jdp Reviewed by: bz, jdp
This commit is contained in:
parent
e3b3506d16
commit
d815cdba83
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=159796
3 changed files with 44 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= ezm3
|
||||
PORTVERSION= 1.2
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= lang
|
||||
|
||||
MASTER_SITES= ftp://ftp.FreeBSD.org/pub/FreeBSD/development/CVSup/ezm3/:src \
|
||||
|
@ -90,6 +91,9 @@ post-patch:
|
|||
.if ${ARCH} == "sparc64" && ${OSVERSION} < 502107
|
||||
@${REINPLACE_CMD} -E -e 's|(^.*time_t.*=.*)int64_t;|\1int32_t;|' \
|
||||
${WRKSRC}/libs/m3core/src/unix/freebsd-4.sparc64/Utypes.i3
|
||||
.elif ${ARCH} == "amd64"
|
||||
@${CP} ${WRKSRC}/libs/m3core/src/unix/freebsd-4.alpha/Unix.i3 \
|
||||
${WRKSRC}/libs/m3core/src/unix/freebsd-4.amd64/Unix.i3
|
||||
.endif
|
||||
|
||||
do-build:
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
--- libs/m3core/src/unix/freebsd-4.alpha/Unix.i3 Sat Mar 23 04:28:45 2002
|
||||
+++ libs/m3core/src/unix/freebsd-4.alpha/Unix.i3 Mon Apr 17 13:03:44 2006
|
||||
@@ -128,7 +128,7 @@
|
||||
F_GETFL = 3; (* Get fd status flags *)
|
||||
F_SETFL = 4; (* Set fd status flags *)
|
||||
|
||||
- (* in these three cases, you need to pass LOOPHOLE (ADR (v), int)
|
||||
+ (* in these three cases, you need to pass LOOPHOLE (ADR (v), long)
|
||||
for arg, where v is a variable of type struct_flock *)
|
||||
F_GETOWN = 5; (* Set owner *)
|
||||
F_SETOWN = 6; (* Get owner *)
|
||||
@@ -155,7 +155,7 @@
|
||||
F_WRLCK = 3; (* Write lock *)
|
||||
F_UNLCK = 2; (* Remove lock(s) *)
|
||||
|
||||
-<*EXTERNAL*> PROCEDURE fcntl (fd, request, arg: int): int;
|
||||
+<*EXTERNAL*> PROCEDURE fcntl (fd, request: int; arg: long): int;
|
||||
(* ok *)
|
||||
|
||||
(*** flock - apply or remove an advisory lock on an open file ***)
|
|
@ -0,0 +1,20 @@
|
|||
--- libs/m3core/src/unix/freebsd-4.sparc64/Unix.i3 Sat Mar 23 04:28:45 2002
|
||||
+++ libs/m3core/src/unix/freebsd-4.sparc64/Unix.i3 Mon Apr 17 13:04:12 2006
|
||||
@@ -128,7 +128,7 @@
|
||||
F_GETFL = 3; (* Get fd status flags *)
|
||||
F_SETFL = 4; (* Set fd status flags *)
|
||||
|
||||
- (* in these three cases, you need to pass LOOPHOLE (ADR (v), int)
|
||||
+ (* in these three cases, you need to pass LOOPHOLE (ADR (v), long)
|
||||
for arg, where v is a variable of type struct_flock *)
|
||||
F_GETOWN = 5; (* Set owner *)
|
||||
F_SETOWN = 6; (* Get owner *)
|
||||
@@ -155,7 +155,7 @@
|
||||
F_WRLCK = 3; (* Write lock *)
|
||||
F_UNLCK = 2; (* Remove lock(s) *)
|
||||
|
||||
-<*EXTERNAL*> PROCEDURE fcntl (fd, request, arg: int): int;
|
||||
+<*EXTERNAL*> PROCEDURE fcntl (fd, request: int; arg: long): int;
|
||||
(* ok *)
|
||||
|
||||
(*** flock - apply or remove an advisory lock on an open file ***)
|
Loading…
Reference in a new issue