Date: Fri, 28 Jan 2005 19:47:15 -0600 (CST) From: Craig Boston <craig@yekse.gank.org> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/76802: New port: comms/cdce Message-ID: <20050129014715.099722AF19@ion.gank.org> Resent-Message-ID: <200501290150.j0T1oHd8049451@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 76802 >Category: ports >Synopsis: New port: comms/cdce >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sat Jan 29 01:50:17 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Craig Boston >Release: FreeBSD 5.3-RELEASE-p5 i386 >Organization: Project Mayhem >Environment: System: FreeBSD aldaris 5.3-RELEASE-p5 FreeBSD 5.3-RELEASE-p5 #0: Sat Jan 22 14:52:25 CST 2005 root@aldaris:/usr/obj/usr/src/sys/ALDARIS i386 >Description: This port is meant to be an easier way to install the CDC Ethernet driver (driver for USB Linux-based PDAs: Sharp Zaurus, YOPY, etc). Currently the driver is maintained out-of-tree as a set of files to be downloaded and built manually. >How-To-Repeat: $ cd /usr/ports/comms/cdce cd: can't cd to /usr/ports/comms/cdce $ make install make: don't know how to make install. Stop >Fix: --- cdce.shar begins here --- # 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: # # cdce # cdce/Makefile # cdce/distinfo # cdce/pkg-descr # cdce/pkg-message # cdce/pkg-plist # cdce/pkg-install # cdce/pkg-deinstall # echo c - cdce mkdir -p cdce > /dev/null 2>&1 echo x - cdce/Makefile sed 's/^X//' >cdce/Makefile << 'END-of-cdce/Makefile' X# New ports collection makefile for: cdce X# Date Created: Jan 25, 2005 X# Whom: Craig Boston <craig@yekse.gank.org> X# X# $FreeBSD$ X# X XPORTNAME= cdce XPORTVERSION= 1.0 XCATEGORIES= comms XMASTER_SITES= http://www.gank.org/freebsd/cdce/ X XMAINTAINER= craig@yekse.gank.org XCOMMENT= Driver for point-to-point CDC Ethernet interfaces X X.include <bsd.port.pre.mk> X X.if ${OSVERSION} < 503000 XIGNORE= "FreeBSD versions prior to 5.3 are not supported" X.endif XNO_PACKAGE= Depends on kernel X Xpre-fetch: X.if !exists(${SRC_BASE}/sys/Makefile) X @${ECHO} "*************************************************"; \ X ${ECHO} "This port requires the kernel source be available"; \ X ${ECHO} "*************************************************"; \ X exit 1 X.endif X Xdo-install: X ${MKDIR} ${PREFIX}/lib/cdce X ${INSTALL_SCRIPT} ${WRKSRC}/if_cdce.ko ${PREFIX}/lib/cdce X Xpost-install: X @PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL X @${CAT} ${PKGMESSAGE} X X.include <bsd.port.post.mk> END-of-cdce/Makefile echo x - cdce/distinfo sed 's/^X//' >cdce/distinfo << 'END-of-cdce/distinfo' XMD5 (cdce-1.0.tar.gz) = 15d57b1d0d10256e7b88f6f7e237213b XSIZE (cdce-1.0.tar.gz) = 6540 END-of-cdce/distinfo echo x - cdce/pkg-descr sed 's/^X//' >cdce/pkg-descr << 'END-of-cdce/pkg-descr' XThis port builds a driver for several devices which communicate using Ethernet Xover USB (CDC Ethernet specification). It does not yet include support for Xmore advanced devices such as cable modems, but is sufficient to talk to Xseveral Linux-based PDAs. X XThis driver has been confirmed to work with Sharp Zaurus and YOPY handhelds. X XIt currently only works on FreeBSD 5.3 or later. X XWWW: http://www.gank.org/freebsd/cdce/ END-of-cdce/pkg-descr echo x - cdce/pkg-message sed 's/^X//' >cdce/pkg-message << 'END-of-cdce/pkg-message' X******************************************************************************* X* Please add the line * X* * X* if_cdce_load="YES" * X* * X* to /boot/loader.conf if you wish the driver to be loaded at system startup. * X******************************************************************************* X* This port contains a prebuilt kernel module. Due to the ever changing * X* nature of FreeBSD it may be necessary to rebuild the module after a kernel * X* source update. To do this, reinstall the port. * X******************************************************************************* END-of-cdce/pkg-message echo x - cdce/pkg-plist sed 's/^X//' >cdce/pkg-plist << 'END-of-cdce/pkg-plist' Xlib/cdce/if_cdce.ko X@dirrm lib/cdce END-of-cdce/pkg-plist echo x - cdce/pkg-install sed 's/^X//' >cdce/pkg-install << 'END-of-cdce/pkg-install' X#!/bin/sh X# X# $FreeBSD$ X XPREFIX=${PKG_PREFIX:-/usr/local} X X[ "x$1" = "x" ] && exit 1 Xif [ "x$2" = "xPOST-INSTALL" ]; then X if [ `sysctl -n kern.osreldate` -ge 500000 ]; then X KMODDIR="/boot/modules" X else X KMODDIR="/modules" X fi X X install -C -o root -g wheel -m 555 ${PREFIX}/lib/cdce/if_cdce.ko \ X ${KMODDIR} X kldxref ${KMODDIR} Xfi END-of-cdce/pkg-install echo x - cdce/pkg-deinstall sed 's/^X//' >cdce/pkg-deinstall << 'END-of-cdce/pkg-deinstall' X#!/bin/sh X# X# Unload cdce kernel module if necessary X# X# $FreeBSD$ X# X Xif [ "x$2" != "xDEINSTALL" ]; then X exit 0 Xfi X Xecho "Disabling if_cdce." X X# Unload if_cdce kernel module Xkldstat -n if_cdce 2>/dev/null >/dev/null && kldunload if_cdce X X# Remove kernel module Xif [ `sysctl -n kern.osreldate` -ge 500000 ]; then X KMODDIR="/boot/modules" Xelse X KMODDIR="/modules" Xfi X[ -f ${KMODDIR}/if_cdce.ko ] && rm -f ${KMODDIR}/if_cdce.ko END-of-cdce/pkg-deinstall exit --- cdce.shar ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050129014715.099722AF19>