From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Jun 26 00:10:54 2004 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A64DB16A4CE for ; Sat, 26 Jun 2004 00:10:54 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4387843D41 for ; Sat, 26 Jun 2004 00:10:54 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) i5Q0AKR7044280 for ; Sat, 26 Jun 2004 00:10:20 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.11/8.12.11/Submit) id i5Q0AKT4044279; Sat, 26 Jun 2004 00:10:20 GMT (envelope-from gnats) Resent-Date: Sat, 26 Jun 2004 00:10:20 GMT Resent-Message-Id: <200406260010.i5Q0AKT4044279@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Juergen Lock Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3558E16A4CE for ; Sat, 26 Jun 2004 00:03:05 +0000 (GMT) Received: from gwyn.kn-bremen.de (gwyn.kn-bremen.de [212.63.36.242]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3804E43D1F for ; Sat, 26 Jun 2004 00:03:03 +0000 (GMT) (envelope-from nox@saturn.kn-bremen.de) Received: from gwyn.kn-bremen.de (uucp@gwyn [127.0.0.1]) i5PIuBMZ025584 for ; Fri, 25 Jun 2004 20:56:11 +0200 Received: from saturn.kn-bremen.de (uucp@localhost)i5PIuBrq025582 for FreeBSD-gnats-submit@freebsd.org; Fri, 25 Jun 2004 20:56:11 +0200 Received: (from nox@localhost) by saturn.kn-bremen.de (8.11.4/8.8.5) id i5PIv2F78572; Fri, 25 Jun 2004 20:57:02 +0200 (CEST) Message-Id: <200406251857.i5PIv2F78572@saturn.kn-bremen.de> Date: Fri, 25 Jun 2004 20:57:02 +0200 (CEST) From: Juergen Lock To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: ports/68349: unbreak emulators/qemu for -stable, add ONLY_FOR_ARCHS X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Juergen Lock List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jun 2004 00:10:54 -0000 >Number: 68349 >Category: ports >Synopsis: unbreak emulators/qemu for -stable, add ONLY_FOR_ARCHS >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Sat Jun 26 00:10:19 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Juergen Lock >Release: FreeBSD 5.2.1-SECURITY i386 >Organization: me? organized?? >Environment: System: FreeBSD neptun 5.2.1-SECURITY FreeBSD 5.2.1-SECURITY #0: Wed May 26 04:19:54 GMT 2004 root@builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC i386 >Description: forgot an #ifdef DIOCGMEDIASIZE, add ONLY_FOR_ARCHS= i386 amd64 powerpc >How-To-Repeat: >Fix: Index: Makefile =================================================================== RCS file: /home/ncvs/ports/emulators/qemu/Makefile,v retrieving revision 1.10 diff -u -r1.10 Makefile --- Makefile 25 Jun 2004 07:37:31 -0000 1.10 +++ Makefile 25 Jun 2004 18:07:50 -0000 @@ -27,6 +27,7 @@ PATCH_STRIP= -p1 CONFIGURE_ARGS+= --prefix=${PREFIX} --cc=${CC}\ -I${PREFIX}/include MAN1= qemu.1 qemu-mkcow.1 +ONLY_FOR_ARCHS= i386 amd64 powerpc post-install: @${CAT} ${PKGMESSAGE} Index: files/patch-bg =================================================================== RCS file: /home/ncvs/ports/emulators/qemu/files/patch-bg,v retrieving revision 1.1 diff -u -r1.1 patch-bg --- files/patch-bg 25 Jun 2004 07:37:31 -0000 1.1 +++ files/patch-bg 25 Jun 2004 16:35:28 -0000 @@ -8,27 +8,30 @@ #include #include #include -@@ -36,6 +38,12 @@ +@@ -36,6 +38,13 @@ #include #include +#ifdef _BSD +#include +#include ++#include +#include +#endif + #include "cow.h" #include "bswap.h" -@@ -56,6 +64,13 @@ int cow_create(int cow_fd, const char *i +@@ -56,6 +64,15 @@ int cow_create(int cow_fd, const char *i perror(image_filename); exit(1); } +#ifdef _BSD + struct stat sb; + if (!fstat(fd,&sb) && (S_IFCHR & sb.st_mode)) { ++#ifdef DIOCGMEDIASIZE + if (ioctl(fd, DIOCGMEDIASIZE, (off_t *)&image_sectors)) ++#endif + image_sectors = lseek(fd, 0LL, SEEK_END); + } else +#endif >Release-Note: >Audit-Trail: >Unformatted: