From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Jun 18 07:20:03 2007 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3658616A41F for ; Mon, 18 Jun 2007 07:20:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id 1158B13C44C for ; Mon, 18 Jun 2007 07:20:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l5I7K2Jf097111 for ; Mon, 18 Jun 2007 07:20:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l5I7K2m3097110; Mon, 18 Jun 2007 07:20:02 GMT (envelope-from gnats) Resent-Date: Mon, 18 Jun 2007 07:20:02 GMT Resent-Message-Id: <200706180720.l5I7K2m3097110@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, Pavel I Volkov Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B7C6B16A468 for ; Mon, 18 Jun 2007 07:13:03 +0000 (UTC) (envelope-from pol@opk.ru) Received: from fire.iib.ru (fire.iib.ru [195.151.95.16]) by mx1.freebsd.org (Postfix) with ESMTP id 6137E13C45A for ; Mon, 18 Jun 2007 07:13:02 +0000 (UTC) (envelope-from pol@opk.ru) Received: from saturn.iib.ru (saturn.iib.ru [192.168.49.101]) by fire.iib.ru (8.9/8.9) with ESMTP id l5I7Ctta070561 for ; Mon, 18 Jun 2007 11:12:57 +0400 (MSD) (envelope-from pol@opk.ru) Received: from 192.168.0.100 by 192.168.0.101 with smtp-gw id normwsaWxP; Mon, 18 Jun 2007 07:15:19 GMT Received: from pol.iib.ru (pol.iib.ru [192.168.0.45]) by mars.iib.ru (8.13.3/8.13.3) with ESMTP id l5I7CpSA081435; Mon, 18 Jun 2007 11:12:52 +0400 (MSD) (envelope-from pol@opk.ru) Received: from pol.iib.ru (localhost [127.0.0.1]) by pol.iib.ru (8.14.1/8.14.1) with ESMTP id l5I7CpwK032251; Mon, 18 Jun 2007 11:12:51 +0400 (MSD) (envelope-from pol@pol.iib.ru) Received: (from pol@localhost) by pol.iib.ru (8.14.1/8.14.1/Submit) id l5I7Cp5D032250; Mon, 18 Jun 2007 11:12:51 +0400 (MSD) (envelope-from pol) Message-Id: <200706180712.l5I7Cp5D032250@pol.iib.ru> Date: Mon, 18 Jun 2007 11:12:51 +0400 (MSD) From: Pavel I Volkov To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: fjoe@FreeBSD.org Subject: ports/113808: [PATCH] emulators/dynamips: update to version 0.2.7 and other change from dynamips-devel 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, 18 Jun 2007 07:20:03 -0000 >Number: 113808 >Category: ports >Synopsis: [PATCH] emulators/dynamips: update to version 0.2.7 and other change from dynamips-devel >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 Jun 18 07:20:02 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Pavel I Volkov >Release: FreeBSD 6.2-STABLE i386 >Organization: >Environment: System: FreeBSD pol.iib.ru 6.2-STABLE FreeBSD 6.2-STABLE #4: Fri May 25 12:42:35 MSD 2007 >Description: [DESCRIBE CHANGES] Added file(s): - files/patch-README - files/patch-README.hypervisor - files/patch-dev_vtty.c - files/patch-dynamips.1 - files/patch-dynamips.c - files/patch-hypervisor.c - files/patch-hypervisor.h - files/patch-hypervisor_mode.7 - files/patch-net.c - files/patch-net.h - files/patch-nvram_export.1 Removed file(s): - files/patch-nojit_trans.c Port maintainer (fjoe@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.77 >How-To-Repeat: >Fix: --- dynamips-0.2.7.patch begins here --- diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/Makefile /usr/ports/emulators/dynamips/Makefile --- /usr/ports/emulators/dynamips.orig/Makefile Thu Nov 23 10:24:01 2006 +++ /usr/ports/emulators/dynamips/Makefile Mon Jun 18 10:57:29 2007 @@ -1,13 +1,12 @@ # New ports collection makefile for: dynamips -# Date created: 31 Jan 2006 +# Date created: 18 Jun 2007 # Whom: Max Khon # # $FreeBSD: ports/emulators/dynamips/Makefile,v 1.13 2006/11/14 04:33:04 fjoe Exp $ # PORTNAME= dynamips -PORTVERSION= 0.2.5 -PORTREVISION= 2 +DISTVERSION= 0.2.7 CATEGORIES= emulators MASTER_SITES= http://www.ipflow.utc.fr/dynamips/ @@ -19,22 +18,19 @@ USE_GMAKE= yes USE_GCC= 3.2+ USE_GETOPT_LONG=yes -ALL_TARGET= ${PORTNAME} +ALL_TARGET= ${PORTNAME} nvram_export MAKE_ENV= DYNAMIPS_ARCH=${DYNAMIPS_ARCH}\ PTHREAD_CFLAGS=${PTHREAD_CFLAGS}\ PTHREAD_LIBS=${PTHREAD_LIBS}\ LDFLAGS="${LDFLAGS}" -PLIST_FILES= bin/${PORTNAME} +PLIST_FILES= bin/${PORTNAME} bin/nvram_export .if !defined(NOPORTDOCS) -PORTDOCS= README +PORTDOCS= README README.hypervisor .endif - -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin -.if !defined(NOPORTDOCS) - ${MKDIR} ${DOCSDIR} - ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR} +.if !defined(NO_INSTALL_MANPAGES) +MAN1= ${PORTNAME}.1 nvram_export.1 +MAN7= hypervisor_mode.7 .endif .include @@ -42,19 +38,31 @@ .if ${ARCH} == "i386" DYNAMIPS_ARCH= "x86" .elif ${ARCH} == "amd64" -DYNAMIPS_ARCH= "nojit" # JIT does not work on amd64 for some reason +DYNAMIPS_ARCH= "amd64" .else DYNAMIPS_ARCH= "nojit" .endif .if ${OSVERSION} < 602100 || ${OSVERSION} < 700021 -# -# Requires libpcap 0.9.4 BUILD_DEPENDS+= libpcap>=0.9.4:${PORTSDIR}/net/libpcap .endif .if ${OSVERSION} >= 700013 MAKE_ENV+= HAS_POSIX_MEMALIGN=1 +.endif + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin + ${INSTALL_PROGRAM} ${WRKSRC}/nvram_export ${PREFIX}/bin +.if !defined(NOPORTDOCS) + ${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/README.hypervisor ${DOCSDIR} +.endif +.if !defined(NO_INSTALL_MANPAGES) + ${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${PREFIX}/man/man1 + ${INSTALL_MAN} ${WRKSRC}/nvram_export.1 ${PREFIX}/man/man1 + ${INSTALL_MAN} ${WRKSRC}/hypervisor_mode.7 ${PREFIX}/man/man7 .endif .include diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/distinfo /usr/ports/emulators/dynamips/distinfo --- /usr/ports/emulators/dynamips.orig/distinfo Mon Nov 13 12:42:42 2006 +++ /usr/ports/emulators/dynamips/distinfo Mon Jun 18 08:59:42 2007 @@ -1,3 +1,3 @@ -MD5 (dynamips-0.2.5.tar.gz) = b87ef442f7537373ccbe69c3f6dca301 -SHA256 (dynamips-0.2.5.tar.gz) = eab3f45b0e040be5748523a4ae0f2fae28ee9dd3068b56663459c7e84451de75 -SIZE (dynamips-0.2.5.tar.gz) = 312130 +MD5 (dynamips-0.2.7.tar.gz) = 0fe1875bb4e7e3624ca420dd75c85279 +SHA256 (dynamips-0.2.7.tar.gz) = f8fc6fc8f66e10f6afcffa832a6071dffeeb9356ed97fe2690bc678d977717ef +SIZE (dynamips-0.2.7.tar.gz) = 522620 diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-Makefile /usr/ports/emulators/dynamips/files/patch-Makefile --- /usr/ports/emulators/dynamips.orig/files/patch-Makefile Thu Nov 23 10:24:01 2006 +++ /usr/ports/emulators/dynamips/files/patch-Makefile Mon Jun 18 11:02:34 2007 @@ -1,5 +1,5 @@ ---- Makefile.orig Thu Sep 14 17:59:13 2006 -+++ Makefile Tue Nov 14 10:27:26 2006 +--- Makefile.orig Thu Feb 8 15:23:36 2007 ++++ Makefile Thu Feb 8 15:34:39 2007 @@ -12,6 +12,9 @@ # (WinPcap is used for Cygwin) HAS_PCAP?=1 @@ -8,14 +8,14 @@ +HAS_POSIX_MEMALIGN?=0 + # Current dynamips release - VERSION=0.2.5 - VERSION_DEV=$(VERSION)-$(shell date +%Y%m%d-%H) -@@ -30,15 +33,16 @@ + VERSION_TRAIN=0.2.7 + VERSION_SUB= +@@ -34,16 +37,17 @@ -DJIT_ARCH=\"$(DYNAMIPS_ARCH)\" \ -DARCH_INC_FILE=$(ARCH_INC_FILE) -DDYNAMIPS_VERSION=\"$(VERSION)\" \ - -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE \ + -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE \ - -DHAS_RFC2553=$(HAS_RFC2553) -+ -DHAS_RFC2553=$(HAS_RFC2553) -DHAS_POSIX_MEMALIGN=$(HAS_POSIX_MEMALIGN) ++ -DHAS_RFC2553=$(HAS_RFC2553) -DHAS_POSIX_MEMALIGN=$(HAS_POSIX_MEMALIGN) -PCAP_LIB=/usr/local/lib/libpcap.a -#PCAP_LIB=-lpcap @@ -24,11 +24,12 @@ ifeq ($(shell uname), FreeBSD) PTHREAD_LIBS?=-pthread -- CFLAGS+=-I/usr/local/include -I/usr/local/include/libelf $(PTHREAD_CFLAGS) -- LIBS=-L/usr/local/lib -L. -lelf $(PTHREAD_LIBS) +- CFLAGS+=-I/usr/local/include -I/usr/local/include/libelf $(PTHREAD_CFLAGS) \ + LOCALBASE?=/usr/local -+ CFLAGS+=-I$(LOCALBASE)/include -I$(LOCALBASE)/include/libelf $(PTHREAD_CFLAGS) ++ CFLAGS+=-I$(LOCALBASE)/include -I$(LOCALBASE)/include/libelf $(PTHREAD_CFLAGS) \ + -D_FILE_OFFSET_BITS=64 +- LIBS=-L/usr/local/lib -L. -lelf $(PTHREAD_LIBS) + LIBS=-L$(LOCALBASE)/lib -L. -lelf $(PTHREAD_LIBS) $(LDFLAGS) else - ifeq ($(shell uname -s), Darwin) - CFLAGS+=-I/usr/local/include -mdynamic-no-pic + ifeq ($(shell uname), Linux) + PTHREAD_LIBS?=-lpthread diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-README /usr/ports/emulators/dynamips/files/patch-README --- /usr/ports/emulators/dynamips.orig/files/patch-README Thu Jan 1 03:00:00 1970 +++ /usr/ports/emulators/dynamips/files/patch-README Mon Jun 18 08:58:15 2007 @@ -0,0 +1,11 @@ +--- README.orig Fri Apr 6 20:53:59 2007 ++++ README Fri Apr 6 20:57:02 2007 +@@ -50,7 +50,7 @@ + -R : Load an alternate ROM (default: embedded) + -k : Set the clock divisor (default: 4) + +- -T : Console is on TCP ++ -T [ip_address:] : Console is on TCP + -U : Console in on serial interface + (default is on the terminal) + diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-README.hypervisor /usr/ports/emulators/dynamips/files/patch-README.hypervisor --- /usr/ports/emulators/dynamips.orig/files/patch-README.hypervisor Thu Jan 1 03:00:00 1970 +++ /usr/ports/emulators/dynamips/files/patch-README.hypervisor Mon Jun 18 08:58:15 2007 @@ -0,0 +1,11 @@ +--- README.hypervisor.orig Wed Mar 21 10:00:28 2007 ++++ README.hypervisor Wed Mar 21 10:01:22 2007 +@@ -8,7 +8,7 @@ + Running dynamips in hypervisor mode + =================================== + +-dynamips -H ++dynamips -H [ip_address:] + + Managing the hypervisor + ======================= diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-dev_vtty.c /usr/ports/emulators/dynamips/files/patch-dev_vtty.c --- /usr/ports/emulators/dynamips.orig/files/patch-dev_vtty.c Thu Jan 1 03:00:00 1970 +++ /usr/ports/emulators/dynamips/files/patch-dev_vtty.c Mon Jun 18 08:58:15 2007 @@ -0,0 +1,33 @@ +--- dev_vtty.c.orig Fri Apr 6 16:44:07 2007 ++++ dev_vtty.c Fri Apr 6 19:43:37 2007 +@@ -24,6 +24,8 @@ + #include + #include + #include ++#include ++#include + + #include + +@@ -43,6 +45,8 @@ + #include "dev_c2600.h" + #include "dev_vtty.h" + ++extern char hypervisor_ip_address[]; ++ + /* VTTY list */ + static pthread_mutex_t vtty_list_mutex = PTHREAD_MUTEX_INITIALIZER; + static vtty_t *vtty_list = NULL; +@@ -132,7 +136,11 @@ + + memset(&serv,0,sizeof(serv)); + serv.sin_family = AF_INET; +- serv.sin_addr.s_addr = htonl(INADDR_ANY); ++ if (strlen(hypervisor_ip_address) != 0 && ++ inet_addr(hypervisor_ip_address) != INADDR_NONE) ++ serv.sin_addr.s_addr = inet_addr(hypervisor_ip_address); ++ else ++ serv.sin_addr.s_addr = htonl(INADDR_ANY); + serv.sin_port = htons(vtty->tcp_port); + + if (bind(vtty->accept_fd,(struct sockaddr *)&serv,sizeof(serv)) < 0) { diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-dynamips.1 /usr/ports/emulators/dynamips/files/patch-dynamips.1 --- /usr/ports/emulators/dynamips.orig/files/patch-dynamips.1 Thu Jan 1 03:00:00 1970 +++ /usr/ports/emulators/dynamips/files/patch-dynamips.1 Mon Jun 18 08:58:15 2007 @@ -0,0 +1,20 @@ +--- dynamips.1.orig Wed Feb 14 20:37:58 2007 ++++ dynamips.1 Fri Apr 6 20:59:41 2007 +@@ -44,7 +44,7 @@ + .SH OPTIONS + A summary of options is included below. + .TP +-.B -H ++.B -H [ip_address:] + Enable hypervisor mode. + .br + The hypervisor mode of dynamips allows you to run simultaneously +@@ -133,7 +133,7 @@ + The command "show clock" at the IOS' CLI will help you set this value. + + .TP +-.B -T ++.B -T [ip_address:] + Console is on TCP + .TP + .B -U diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/files/patch-dynamips.c /usr/ports/emulators/dynamips/files/patch-dynamips.c --- /usr/ports/emulators/dynamips.orig/files/patch-dynamips.c Thu Jan 1 03:00:00 1970 +++ /usr/ports/emulators/dynamips/files/patch-dynamips.c Mon Jun 18 08:58:15 2007 @@ -0,0 +1,87 @@ +--- dynamips.c.orig Wed Feb 14 20:37:58 2007 ++++ dynamips.c Fri Apr 6 21:11:38 2007 +@@ -61,6 +61,7 @@ + /* Hypervisor */ + int hypervisor_mode = 0; + int hypervisor_tcp_port = 0; ++char hypervisor_ip_address[263]="\000"; /* 256(MAXHOSTNAMELEN)+1(:)+5(port)+NULL */ + + /* Log file */ + char *log_file_name = NULL; +@@ -227,7 +228,7 @@ + printf("Usage: %s [options] \n\n",argv[0]); + + printf("Available options:\n" +- " -H : Run in hypervisor mode\n\n" ++ " -H [ip_address:] : Run in hypervisor mode\n\n" + " -P : Platform to emulate (7200, 3600, " + "2691, 3725 or 3745) " + "(default: 7200)\n\n" +@@ -254,7 +255,7 @@ + " -R : Load an alternate ROM (default: embedded)\n" + " -k : Set the clock divisor (default: %d)\n" + "\n" +- " -T : Console is on TCP \n" ++ " -T [ip_address:] : Console is on TCP \n" + " -U : Console in on serial interface \n" + " (default is on the terminal)\n" + "\n" +@@ -780,6 +781,7 @@ + int instance_id; + int res,option; + char *str; ++ char *index; + + /* Get the instance ID */ + instance_id = 0; +@@ -944,7 +946,15 @@ + /* TCP server for Console Port */ + case 'T': + vm->vtty_con_type = VTTY_TYPE_TCP; +- vm->vtty_con_tcp_port = atoi(optarg); ++ strncpy(hypervisor_ip_address,optarg,sizeof(hypervisor_ip_address)); ++ index=strrchr(hypervisor_ip_address,':'); ++ if (index != NULL) { ++ *index++='\000'; ++ vm->vtty_con_tcp_port = atoi(index); ++ } else { ++ vm->vtty_con_tcp_port = atoi(hypervisor_ip_address); ++ hypervisor_ip_address[0]='\000'; ++ } + break; + + /* Serial interface for Console port */ +@@ -1061,6 +1071,7 @@ + static int run_hypervisor(int argc,char *argv[]) + { + char *options_list = "H:l:hN:"; ++ char *index; + int i,option; + + for(i=1;i + #include + #include ++#include ++#include + + /* True/False definitions */ + #ifndef FALSE +@@ -35,6 +37,8 @@ + #elif defined(__i386) || defined(__i386__) || defined(i386) #define ARCH_BYTE_ORDER ARCH_LITTLE_ENDIAN #elif defined(__x86_64__) - #define ARCH_BYTE_ORDER ARCH_LITTLE_ENDIAN -+#elif defined(__ia64__) +#define ARCH_BYTE_ORDER ARCH_LITTLE_ENDIAN ++#elif defined(__ia64__) + #define ARCH_BYTE_ORDER ARCH_LITTLE_ENDIAN #endif - #ifndef ARCH_BYTE_ORDER diff -ruN --exclude=CVS /usr/ports/emulators/dynamips.orig/pkg-descr /usr/ports/emulators/dynamips/pkg-descr --- /usr/ports/emulators/dynamips.orig/pkg-descr Thu Nov 23 10:24:01 2006 +++ /usr/ports/emulators/dynamips/pkg-descr Mon Jun 18 08:58:15 2007 @@ -1,3 +1,5 @@ Cisco 3600/7200 simulator. WWW: http://www.ipflow.utc.fr/index.php/Cisco_7200_Simulator + http://www.ipflow.utc.fr/blog/ + http://hacki.at/7200emu/index.php --- dynamips-0.2.7.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted: