From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Sep 28 09:10:02 2009 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A630A1065676 for ; Mon, 28 Sep 2009 09:10:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 81E958FC1F for ; Mon, 28 Sep 2009 09:10:02 +0000 (UTC) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n8S9A2VM038761 for ; Mon, 28 Sep 2009 09:10:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n8S9A2Xg038760; Mon, 28 Sep 2009 09:10:02 GMT (envelope-from gnats) Resent-Date: Mon, 28 Sep 2009 09:10:02 GMT Resent-Message-Id: <200909280910.n8S9A2Xg038760@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, Anonymous Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1F0F9106566C for ; Mon, 28 Sep 2009 09:05:57 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-ew0-f209.google.com (mail-ew0-f209.google.com [209.85.219.209]) by mx1.freebsd.org (Postfix) with ESMTP id A16F88FC16 for ; Mon, 28 Sep 2009 09:05:56 +0000 (UTC) Received: by ewy5 with SMTP id 5so2716353ewy.36 for ; Mon, 28 Sep 2009 02:05:55 -0700 (PDT) Received: by 10.210.7.21 with SMTP id 21mr2823068ebg.66.1254128755835; Mon, 28 Sep 2009 02:05:55 -0700 (PDT) Received: from localhost (95-24-173-2.broadband.corbina.ru [95.24.173.2]) by mx.google.com with ESMTPS id 5sm1977068eyh.27.2009.09.28.02.05.54 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 28 Sep 2009 02:05:55 -0700 (PDT) Message-Id: <86my4f1lse.fsf@gmail.com> Date: Mon, 28 Sep 2009 13:05:53 +0400 From: Anonymous To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/139206: [patch] archivers/xz: use system byteswapping functions X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Sep 2009 09:10:02 -0000 >Number: 139206 >Category: ports >Synopsis: [patch] archivers/xz: use system byteswapping functions >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Sep 28 09:10:02 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Anonymous >Release: FreeBSD 9.0-CURRENT amd64 >Organization: >Environment: System: FreeBSD 9.0-CURRENT #2 r197528M: Sat Sep 26 20:24:09 UTC 2009 root@luffy:/usr/obj/usr/src/sys/PHOENIX amd64 >Description: >How-To-Repeat: >Fix: --- xz.diff begins here --- Index: archivers/xz/Makefile =================================================================== RCS file: /home/csup/ports/archivers/xz/Makefile,v retrieving revision 1.11 diff -u -p -r1.11 Makefile --- archivers/xz/Makefile 21 Sep 2009 14:07:42 -0000 1.11 +++ archivers/xz/Makefile 28 Sep 2009 09:01:11 -0000 @@ -42,6 +42,12 @@ MLINKS= xz.1 lzcat.1 xzdiff.1 lzcmp.1 \ PORTDOCS= AUTHORS COPYING COPYING.GPLv2 NEWS README THANKS TODO \ faq.txt history.txt lzma-file-format.txt xz-file-format.txt +post-patch: .SILENT + ${REINPLACE_CMD} -E -e 's/(bswap)_(16|32|64)/\1\2/g' \ + -e 's|byteswap\.h|sys/endian.h|g' \ + -e 's|byteswap_h|sys_endian_h|g' \ + ${WRKSRC}/configure + regression-test: build @cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} check Index: archivers/xz/files/patch-config.h.in =================================================================== RCS file: archivers/xz/files/patch-config.h.in diff -N archivers/xz/files/patch-config.h.in --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ archivers/xz/files/patch-config.h.in 16 Sep 2009 00:23:05 -0000 @@ -0,0 +1,13 @@ +--- config.h.in~ ++++ config.h.in +@@ -22,8 +22,8 @@ + /* Define to 1 if bswap_64 is available. */ + #undef HAVE_BSWAP_64 + +-/* Define to 1 if you have the header file. */ +-#undef HAVE_BYTESWAP_H ++/* Define to 1 if you have the header file. */ ++#undef HAVE_SYS_ENDIAN_H + + /* Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the + CoreFoundation framework. */ Index: archivers/xz/files/patch-src-common-bswap.h =================================================================== RCS file: archivers/xz/files/patch-src-common-bswap.h diff -N archivers/xz/files/patch-src-common-bswap.h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ archivers/xz/files/patch-src-common-bswap.h 16 Sep 2009 00:22:04 -0000 @@ -0,0 +1,16 @@ +--- src/common/bswap.h~ ++++ src/common/bswap.h +@@ -20,8 +20,11 @@ + // bswap_xx macros/functions, which is why we check them separately even + // if byteswap.h is available. + +-#ifdef HAVE_BYTESWAP_H +-# include ++#ifdef HAVE_SYS_ENDIAN_H ++# include ++# define bswap_16 bswap16 ++# define bswap_32 bswap32 ++# define bswap_64 bswap64 + #endif + + #ifndef HAVE_BSWAP_16 --- xz.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: