From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 17779 invoked from network); 9 Dec 2023 23:43:33 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 9 Dec 2023 23:43:33 -0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Message-ID:Date: Content-Transfer-Encoding:Content-ID:Content-Type:MIME-Version:Subject:To: References:From:In-reply-to:cc:Reply-To:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=ssN13SA1MC1j2y9pNapY7xs3Uo1ae61n5EUKdwSN00w=; b=WeAD6sC2KbM1GJoUk7KctusnjZ fjbC8N2M5ZakN2EhUI4C1WL2d2zXn1fQL5nTtMQwdCMCsc2RrP1vjmu1uoaOAeyV/N3KSZCYzTokk QLmjk4qYCke1X2GIjEScS6/zanxEn5JftJ1nO2jtYQFUOiOLSJ3psN8KL8tpg08Cyz8/knB7SBgGl XCH6CU5NDQ2rKNm4iT+YQLg6qj+uWjGBqGvbDvRE2emH3OSU8almWTwuqNKI0I0xqDeNAaT+aUrui dv8318jF8HP9S+y23BNN5W0L6wQmQie+8FU99EXvzJj8VevkS/PiEBBry+o4Yd4Ujg4r8/TT5CIOG sbgE1pPQ==; Received: by zero.zsh.org with local id 1rC6yq-000JyF-6M; Sat, 09 Dec 2023 23:43:32 +0000 Received: by zero.zsh.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1rC6yZ-000JgD-4Z; Sat, 09 Dec 2023 23:43:15 +0000 Received: from [192.168.178.21] (helo=hydra) by mail.kiddle.eu with esmtp(Exim 4.95) (envelope-from ) id 1rC6yY-0005Em-Dy; Sun, 10 Dec 2023 00:43:14 +0100 cc: Zsh workers In-reply-to: From: Oliver Kiddle References: <50885-1702060132.779123@YSiF.CgC_.vGLi> To: Bart Schaefer Subject: Re: PATCH: Avoid \e in C code; building on Solaris 11 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <20134.1702165394.1@hydra> Content-Transfer-Encoding: 8bit Date: Sun, 10 Dec 2023 00:43:14 +0100 Message-ID: <20135-1702165394.429946@o8Bt.xo_H.6Uja> X-Seq: 52394 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: Bart Schaefer wrote: > /dev/fd tests are being skipped because it doesn't detect /dev/fd. > That test is: echo ok|(exec 3<&0; cat /dev/fd/3 2>/dev/null;) > > (This refers to [2]configure.ac, not Test/*) Yes, sorry. However it was something that was only apparent when running test cases because it caused some to get skipped. It occurred to me that /bin/sh on Solaris 11 is ksh 93 and that test consistently doesn't work with ksh (88 or 93). The same applies with ksh93 on Linux. > This is testing that /dev/fd/ entries are created when new descriptors are > created.  The commit log says "work around /dev/fd problem on FreeBSD": > +dnl FreeBSD 5 only supports /dev/fd/0 to /dev/fd/2 without mounting > +dnl a special file system.  As zsh needs arbitrary /dev/fd (typically > +dnl >10) for its own use, we need to make sure higher fd's are available. While that talks about FreeBSD 5, that isn't a situation that has changed at all. Annoyingly, most package builds take place in a jail where fdescfs is not mounted so PATH_DEV_FD is probably undefined for most users on FreeBSD even if they mount fdescfs. Just doing test -e on /dev/fd/3 gives the same results as the existing test on FreeBSD both with and without fdescfs. Do you see a problem with this approach? Oliver diff --git a/configure.ac b/configure.ac index a42758bf3..2871dcb7c 100644 --- a/configure.ac +++ b/configure.ac @@ -2016,7 +2016,7 @@ AH_TEMPLATE([PATH_DEV_FD], [Define to the path of the /dev/fd filesystem.]) AC_CACHE_CHECK(for /dev/fd filesystem, zsh_cv_sys_path_dev_fd, [for zsh_cv_sys_path_dev_fd in /proc/self/fd /dev/fd no; do - test x`echo ok|(exec 3<&0; cat $zsh_cv_sys_path_dev_fd/3 2>/dev/null;)` = xok && break + (exec 3<&0; test -e $zsh_cv_sys_path_dev_fd/3;) && break done]) if test x$zsh_cv_sys_path_dev_fd != xno; then AC_DEFINE_UNQUOTED(PATH_DEV_FD, "$zsh_cv_sys_path_dev_fd")