From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Jul 1 00:30:03 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 841D2106564A for ; Wed, 1 Jul 2009 00:30:03 +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 6169F8FC0A for ; Wed, 1 Jul 2009 00:30:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n610U3bb013891 for ; Wed, 1 Jul 2009 00:30:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n610U38j013890; Wed, 1 Jul 2009 00:30:03 GMT (envelope-from gnats) Resent-Date: Wed, 1 Jul 2009 00:30:03 GMT Resent-Message-Id: <200907010030.n610U38j013890@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, Li-Wen Hsu Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A59DE1065670 for ; Wed, 1 Jul 2009 00:25:03 +0000 (UTC) (envelope-from lwhsu@csie.net) Received: from lucky7.csie.net (lucky7.cs.nctu.edu.tw [140.113.17.237]) by mx1.freebsd.org (Postfix) with ESMTP id 700548FC12 for ; Wed, 1 Jul 2009 00:25:03 +0000 (UTC) (envelope-from lwhsu@csie.net) Received: from lucky7.csie.net (localhost [127.0.0.1]) by lucky7.csie.net (Postfix) with ESMTP id 11BE9147C1C; Wed, 1 Jul 2009 05:54:56 +0800 (CST) Received: by lucky7.csie.net (Postfix, from userid 1000) id 0DEC5147C1B; Wed, 1 Jul 2009 05:54:56 +0800 (CST) Message-Id: <20090630215456.0DEC5147C1B@lucky7.csie.net> Date: Wed, 1 Jul 2009 05:54:56 +0800 (CST) From: Li-Wen Hsu To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: perky@FreeBSD.org Subject: ports/136199: [PATCH] databases/py-gdbm: Fix building with python3* 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: Wed, 01 Jul 2009 00:30:03 -0000 >Number: 136199 >Category: ports >Synopsis: [PATCH] databases/py-gdbm: Fix building with python3* >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: Wed Jul 01 00:30:03 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Li-Wen Hsu >Release: FreeBSD 7.2-STABLE amd64 >Organization: >Environment: System: FreeBSD lucky7 7.2-STABLE FreeBSD 7.2-STABLE #0: Thu Jun 11 00:29:36 CST 2009 >Description: - Fix building with python3* - Use checksum file under lang/python${PYTHON_SUFFIX}/, for removal lang/python/distinfo Added file(s): - files/setup3.py Port maintainer (perky@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.77 >How-To-Repeat: >Fix: --- py26-gdbm-2.6.2.patch begins here --- Index: Makefile =================================================================== RCS file: /home/ncvs/ports/databases/py-gdbm/Makefile,v retrieving revision 1.13 diff -u -u -r1.13 Makefile --- Makefile 30 Jul 2007 09:41:05 -0000 1.13 +++ Makefile 30 Jun 2009 21:53:12 -0000 @@ -24,9 +24,15 @@ USE_PYDISTUTILS=yes PYDISTUTILS_PKGVERSION= 0.0.0 WRKSRC= ${PYTHON_WRKSRC}/Modules -MD5_FILE= ${PORTSDIR}/lang/python/distinfo +MD5_FILE= ${PORTSDIR}/lang/python${PYTHON_SUFFIX}/distinfo + +.include post-extract: +.if ${PYTHON_REL} < 300 @${CP} ${FILESDIR}/setup.py ${WRKSRC} +.else + @${CP} ${FILESDIR}/setup3.py ${WRKSRC}/setup.py +.endif -.include +.include Index: files/setup3.py =================================================================== RCS file: files/setup3.py diff -N files/setup3.py --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/setup3.py 30 Jun 2009 21:53:12 -0000 @@ -0,0 +1,28 @@ +#!/usr/bin/env python +# To use: +# python setup.py install +# + +__version__ = "$FreeBSD$" + +try: + import distutils + from distutils import sysconfig + from distutils.command.install import install + from distutils.core import setup, Extension +except: + raise SystemExit("Distutils problem") + +prefix = sysconfig.PREFIX +inc_dirs = [prefix + "/include"] +lib_dirs = [prefix + "/lib"] +libs = ["gdbm"] + +setup(name = "gdbm", + description = "GDBM Extension to Python", + + ext_modules = [Extension('gdbm', ['_gdbmmodule.c'], + include_dirs = inc_dirs, + libraries = libs, + library_dirs = lib_dirs)] + ) --- py26-gdbm-2.6.2.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted: