From owner-freebsd-amd64@FreeBSD.ORG Mon Feb 28 05:13:26 2005 Return-Path: Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB75116A4CE for ; Mon, 28 Feb 2005 05:13:26 +0000 (GMT) Received: from freckleface.aedifice.net (adsl-209-233-30-172.dsl.snfc21.pacbell.net [209.233.30.172]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1DF2343D4C for ; Mon, 28 Feb 2005 05:13:26 +0000 (GMT) (envelope-from myers@aedifice.net) Received: from [10.0.0.20] (dmz2 [192.168.1.2])j1S54fl09087 for ; Sun, 27 Feb 2005 21:04:42 -0800 (PST) Message-ID: <4222A870.2090500@aedifice.net> Date: Sun, 27 Feb 2005 21:13:20 -0800 From: "David C. Myers" User-Agent: Mozilla Thunderbird 1.0 (X11/20050105) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-amd64@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: VNC on amd64: SIOCGIFCONF problems X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Feb 2005 05:13:26 -0000 VNC-3.3.7 in ports looks like it doesn't work because of 64-bit alignment issues with SIOCGIFCONF. The offending code is in Xvnc/programs/Xserver/os/access.c: if (ifioctl (fd, (int) SIOCGIFCONF, (pointer) &ifc) < 0) Error ("Getting interface configuration (4)"); which comes out in the trace file as: 28138 Xvnc CALL bind(0x1,0x7fffffffe670,0x13) 28138 Xvnc NAMI "/tmp/.X11-unix/X1" 28138 Xvnc RET bind 0 28138 Xvnc CALL listen(0x1,0x80) 28138 Xvnc RET listen 0 28138 Xvnc CALL umask(0x12) 28138 Xvnc RET umask 0 28138 Xvnc CALL ioctl(0,0xffffffffc0106924 ,0x7fffffffe030) 28138 Xvnc RET ioctl -1 errno 6 Device not configured 28138 Xvnc CALL writev(0x2,0x7fffffffd790,0x4) 28138 Xvnc GIO fd 2 wrote 59 bytes "Getting interface configuration (4): Device not configured " (Actually, the very first error you'll get is a "Could not open default font 'fixed'" message, but you can make that go away by running a font server and passing its address to Xvnc...) Is there a quick solution to this? A 32-bit compatibility shim? Judging from Google, issues with this ioctl go back years, on all kinds of platforms. getifaddrs() is the right way to do this on BSD? -David.