From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Dec 26 12:20:13 2010 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 5D6DD1065672 for ; Sun, 26 Dec 2010 12:20:13 +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 4BC888FC15 for ; Sun, 26 Dec 2010 12:20:13 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id oBQCKDtT054483 for ; Sun, 26 Dec 2010 12:20:13 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id oBQCKCVp054482; Sun, 26 Dec 2010 12:20:12 GMT (envelope-from gnats) Date: Sun, 26 Dec 2010 12:20:12 GMT Message-Id: <201012261220.oBQCKCVp054482@freefall.freebsd.org> To: freebsd-ports-bugs@FreeBSD.org From: Stefan Bethke Cc: Subject: Re: ports/153452: New port: science/py-ws2300 A driver for the LaCrosse WS-2300 weather station X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Stefan Bethke List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Dec 2010 12:20:13 -0000 The following reply was made to PR ports/153452; it has been noted by GNATS. From: Stefan Bethke To: FreeBSD-gnats-submit@FreeBSD.org, freebsd-ports-bugs@FreeBSD.org Cc: Subject: Re: ports/153452: New port: science/py-ws2300 A driver for the LaCrosse WS-2300 weather station Date: Sun, 26 Dec 2010 13:14:55 +0100 --Apple-Mail-1--621600839 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii I forgot a patch. Here's the complete SHAR with the patch included. --Apple-Mail-1--621600839 Content-Disposition: attachment; filename=py-ws2300.shar Content-Type: application/octet-stream; x-unix-mode=0644; name="py-ws2300.shar" Content-Transfer-Encoding: 7bit # This is a shell archive. Save it in a file, remove anything before # this line, and then unpack it by entering "sh file". Note, it may # create directories; files and directories will be owned by you and # have default permissions. # # This archive contains: # # py-ws2300 # py-ws2300/distinfo # py-ws2300/pkg-plist # py-ws2300/Makefile # py-ws2300/files # py-ws2300/files/ws2300 # py-ws2300/files/patch-ws2300.py # py-ws2300/pkg-descr # echo c - py-ws2300 mkdir -p py-ws2300 > /dev/null 2>&1 echo x - py-ws2300/distinfo sed 's/^X//' >py-ws2300/distinfo << 'd6658d0e9f20f34fad70eb0626cb729c' XSHA256 (ws2300-1.3.tar.gz) = f824943f04791d63fc5edd940a60181bde2c8f575c11be1e473036fce76c7eef XSIZE (ws2300-1.3.tar.gz) = 63738 d6658d0e9f20f34fad70eb0626cb729c echo x - py-ws2300/pkg-plist sed 's/^X//' >py-ws2300/pkg-plist << 'f76cabf254af03cfc8bad852c78c288d' X%%PYTHON_SITELIBDIR%%/ws2300.py X%%PYTHON_SITELIBDIR%%/ws2300.pyc X%%PYTHON_SITELIBDIR%%/ws2300.pyo Xbin/ws2300 f76cabf254af03cfc8bad852c78c288d echo x - py-ws2300/Makefile sed 's/^X//' >py-ws2300/Makefile << '7a0b06e1c53503f2c69695bf7d7531a7' X# New ports collection makefile for: py-ws2300 X# Date created: 26 December 2010 X# Whom: Stefan Bethke X# X# $FreeBSD$ X# X XPORTNAME= ws2300 XPORTVERSION= 1.3 XCATEGORIES= science python XMASTER_SITES= http://ace-host.stuart.id.au/russell/files/ws2300/ \ X http://www.transit.hanse.de/mirror/ace-host.stuart.id.au/russell/files/ws2300/ XPKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} X#DISTNAME= pydns-${PORTVERSION} X XMAINTAINER= stb@lassitu.de XCOMMENT= A driver for the LaCrosse WS-2300 weather station X XUSE_PYTHON= yes XUSE_PYDISTUTILS= yes X#PYDISTUTILS_PKGNAME= x X XMAN1= ws2300.1 X Xpost-install: X #@${LN} -sf ${PYTHONPREFIX_SITELIBDIR}/ws2300.py ${PREFIX}/bin/ws2300 X @${INSTALL_SCRIPT} ${FILESDIR}/ws2300 ${PREFIX}/bin/ws2300 X @${INSTALL_MAN} ${WRKSRC}/ws2300.1 ${PREFIX}/man/man1/ X X.include 7a0b06e1c53503f2c69695bf7d7531a7 echo c - py-ws2300/files mkdir -p py-ws2300/files > /dev/null 2>&1 echo x - py-ws2300/files/ws2300 sed 's/^X//' >py-ws2300/files/ws2300 << '02cea18e519bd17929d719270a34d8f7' X#!/usr/bin/env python X Xfrom ws2300 import * Xmain(sys.argv) 02cea18e519bd17929d719270a34d8f7 echo x - py-ws2300/files/patch-ws2300.py sed 's/^X//' >py-ws2300/files/patch-ws2300.py << '84061ef936654111515b41c19f08d83c' X--- ws2300.py.orig 2008-02-09 01:05:06.000000000 +0100 X+++ ws2300.py 2010-12-26 13:09:04.204179367 +0100 X@@ -26,15 +26,16 @@ X import math X import optparse X import os X-import popen2 X import select X import signal X import socket X import stat X import string X import struct X+import subprocess X import sys X import syslog X+import termios X import traceback X import time X import tty X@@ -182,7 +183,10 @@ X setup[6][tty.VMIN] = 1 X setup[6][tty.VTIME] = 0 X tty.tcflush(self.serial_port, tty.TCIOFLUSH) X- tty.tcflow(self.serial_port, tty.TCOON|tty.TCION) X+ try: X+ tty.tcflow(self.serial_port, tty.TCOON|tty.TCION) X+ except termios.error: X+ pass X tty.tcsetattr(self.serial_port, tty.TCSAFLUSH, setup) X # X # Set DTR low and RTS high and leave other control lines untouched. X@@ -2714,9 +2718,9 @@ X # If some sort of error occurred, send an email. X # X def email_fatal(me, email, lines): X- stdout, stdin = popen2.popen2("/usr/sbin/sendmail -t") X- stdout.close() X- w = lambda s: stdin.write(s + "\n") X+ p = subprocess.Popen(["/usr/sbin/sendmail", "-t"], X+ stdin=subprocess.PIPE, close_fds=True) X+ w = lambda s: p.stdin.write(s + "\n") X if not isinstance(email, (type(()), type([]))): X email = [email] X w("To: " + ",".join(email)) X@@ -2730,7 +2734,7 @@ X w("Regards,") X w(me) X w("Running on " + socket.gethostname()) X- stdin.close() X+ p.stdin.close() X X # X # Daemon mode recording. 84061ef936654111515b41c19f08d83c echo x - py-ws2300/pkg-descr sed 's/^X//' >py-ws2300/pkg-descr << '008ccc22a6abb8405cc79d0e3f0a0ef6' XWs2300 manipulates the LaCrosse WS-2300 weather station via its RS232 Xinterface. It can read and write values, and can continuously log data from XWS-2300 to a file or SQL database. X XWWW: http://ace-host.stuart.id.au/russell/files/ws2300/ 008ccc22a6abb8405cc79d0e3f0a0ef6 exit --Apple-Mail-1--621600839 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii -- Stefan Bethke Fon +49 151 14070811 --Apple-Mail-1--621600839--