From owner-freebsd-java Mon Mar 6 15:50:56 2000 Delivered-To: freebsd-java@freebsd.org Received: from ares.maths.adelaide.edu.au (ares.maths.adelaide.edu.au [129.127.246.5]) by hub.freebsd.org (Postfix) with ESMTP id DEC7737BEF1 for ; Mon, 6 Mar 2000 15:50:51 -0800 (PST) (envelope-from glewis@ares.maths.adelaide.edu.au) Received: (from glewis@localhost) by ares.maths.adelaide.edu.au (8.9.3/8.9.3) id KAA02809 for freebsd-java@freebsd.org; Tue, 7 Mar 2000 10:20:49 +1030 (CST) (envelope-from glewis) From: Greg Lewis Message-Id: <200003062350.KAA02809@ares.maths.adelaide.edu.au> Subject: JDK 1.2.2 source - Solaris fcntl flags To: freebsd-java@freebsd.org Date: Tue, 7 Mar 2000 10:20:48 +1030 (CST) X-Mailer: ELM [version 2.4ME+ PL70 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Hi all, During compiling JDK 1.2.2 under FreeBSD one of the errors I've run into is in compiling the awt_Robot.c file which contains the code (in fdSetNoBuffer) flags |= O_NDELAY|O_SYNC|O_DSYNC|O_RSYNC; if (fcntl(fd, F_SETFL, flags) != -1) { /* fprintf(stderr, * "ERROR OCCURRED IN fdSetNoBuffer(). " * "File output may be buffered.\n"); */ return; } FreeBSD certainly defines O_NDELAY (as an alias for O_NONBLOCK) but doesn't define the other flags. On a Solaris 2.5.1 box the remaining flags are defined as (in /usr/include/sys/fcntl.h) #if defined(__EXTENSIONS__) || !defined(_POSIX_C_SOURCE) || \ (_POSIX_C_SOURCE > 2) || defined(_XOPEN_SOURCE) #define O_SYNC 0x10 /* synchronized file update option */ #define O_DSYNC 0x40 /* synchronized data update option */ #define O_RSYNC 0x8000 /* synchronized file update option */ /* defines read/write file integraty */ /* we are taking last bit as no spece */ /* left in first 8 bits */ #endif /* defined(__EXTENSIONS__) || !defined(_POSIX_C_SOURCE) ... */ Nothing leaps out at me from the FreeBSD fcntl.h as equivalent. Anyone got any thoughts on this? If not I'll just experiment I guess :). -- Greg Lewis glewis@trc.adelaide.edu.au Computing Officer +61 8 8303 5083 Teletraffic Research Centre To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message