diff options
author | wxs <wxs@FreeBSD.org> | 2012-06-22 09:49:00 +0800 |
---|---|---|
committer | wxs <wxs@FreeBSD.org> | 2012-06-22 09:49:00 +0800 |
commit | 135b2665df1287ce0c672efdfc488b348352c4b6 (patch) | |
tree | 6f9c6ba1581facc5a83af5c0c8686ea19bd14f56 /emulators/dynagen | |
parent | 3a9e1f8550ebd3ecc35a4ad303e58710441dd044 (diff) | |
download | freebsd-ports-gnome-135b2665df1287ce0c672efdfc488b348352c4b6.tar.gz freebsd-ports-gnome-135b2665df1287ce0c672efdfc488b348352c4b6.tar.zst freebsd-ports-gnome-135b2665df1287ce0c672efdfc488b348352c4b6.zip |
Fix RUN_DEPENDS.
Add LICENSE.
Switch to PLIST_FILES.
PR: ports/168937
Submitted by: Pavel I Volkov <pavelivolkov@googlemail.com> (maintainer)
Diffstat (limited to 'emulators/dynagen')
-rw-r--r-- | emulators/dynagen/Makefile | 67 | ||||
-rw-r--r-- | emulators/dynagen/files/patch-setup.py | 7 | ||||
-rw-r--r-- | emulators/dynagen/pkg-deinstall | 6 | ||||
-rw-r--r-- | emulators/dynagen/pkg-install | 4 | ||||
-rw-r--r-- | emulators/dynagen/pkg-plist | 78 |
5 files changed, 62 insertions, 100 deletions
diff --git a/emulators/dynagen/Makefile b/emulators/dynagen/Makefile index 91e5ed5267e1..dfa6c3cfe9fe 100644 --- a/emulators/dynagen/Makefile +++ b/emulators/dynagen/Makefile @@ -7,15 +7,43 @@ PORTNAME= dynagen PORTVERSION= 0.11.0 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= emulators MASTER_SITES= SF/dyna-gen/${PORTNAME}%20source%20_%20Linux/${PORTNAME}%20${PORTVERSION} MAINTAINER= pavelivolkov@googlemail.com COMMENT= Text-based front end for Dynamips development version -RUN_DEPENDS= dynamips:${PORTSDIR}/emulators/dynamips-community +LICENSE= GPLv2 + # Note that it *should* be dynamips-devel but that port installs it as dynamips +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}configobj>=4.4.0:${PORTSDIR}/devel/py-configobj \ + dynamips:${PORTSDIR}/emulators/dynamips-community + +PLIST_FILES= bin/dynagen \ + etc/dynagen.ini.sample \ + %%PYTHON_SITELIBDIR%%/confConsole.py \ + %%PYTHON_SITELIBDIR%%/confConsole.pyc \ + %%PYTHON_SITELIBDIR%%/confConsole.pyo \ + %%PYTHON_SITELIBDIR%%/console.py \ + %%PYTHON_SITELIBDIR%%/console.pyc \ + %%PYTHON_SITELIBDIR%%/console.pyo \ + %%PYTHON_SITELIBDIR%%/dynamips_lib.py \ + %%PYTHON_SITELIBDIR%%/dynamips_lib.pyc \ + %%PYTHON_SITELIBDIR%%/dynamips_lib.pyo \ + %%PYTHON_SITELIBDIR%%/pemu_lib.py \ + %%PYTHON_SITELIBDIR%%/pemu_lib.pyc \ + %%PYTHON_SITELIBDIR%%/pemu_lib.pyo \ + %%PYTHON_SITELIBDIR%%/pemubin.py \ + %%PYTHON_SITELIBDIR%%/pemubin.pyc \ + %%PYTHON_SITELIBDIR%%/pemubin.pyo \ + %%PYTHON_SITELIBDIR%%/pemuwrapper.py \ + %%PYTHON_SITELIBDIR%%/pemuwrapper.pyc \ + %%PYTHON_SITELIBDIR%%/pemuwrapper.pyo + +PORTDOCS= * +PORTEXAMPLES= * +PORTDATA= * USE_PYTHON= yes USE_PYDISTUTILS= yes @@ -25,34 +53,37 @@ USE_DOS2UNIX= yes post-install: ${INSTALL_SCRIPT} ${WRKSRC}/dynagen ${PREFIX}/bin ${INSTALL_DATA} ${WRKSRC}/dynagen.ini ${PREFIX}/etc/dynagen.ini.sample + @PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL - @if [ ! -f ${PREFIX}/etc/dynagen.ini ]; then \ - ${CP} -p ${PREFIX}/etc/dynagen.ini.sample ${PREFIX}/etc/dynagen.ini ; \ - fi - - ${MKDIR} ${DATADIR} + @${MKDIR} ${DATADIR} ${INSTALL_DATA} ${WRKSRC}/configspec ${DATADIR}/configspec -.if !defined(NOPORTDOCS) - ${MKDIR} ${DOCSDIR} +.ifndef NOPORTDOCS + @${MKDIR} ${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/docs/tutorial.htm ${DOCSDIR} - ${MKDIR} ${DOCSDIR}/tutorial_files + @${MKDIR} ${DOCSDIR}/tutorial_files ${INSTALL_DATA} ${WRKSRC}/docs/tutorial_files/* ${DOCSDIR}/tutorial_files .endif - ${MKDIR} ${EXAMPLESDIR} - ${MKDIR} ${EXAMPLESDIR}/sample_labs - ${MKDIR} ${EXAMPLESDIR}/sample_labs/ethernet_switch + +.ifndef NOPORTEXAMPLES + @${MKDIR} ${EXAMPLESDIR} + @${MKDIR} ${EXAMPLESDIR}/sample_labs + @${MKDIR} ${EXAMPLESDIR}/sample_labs/ethernet_switch ${INSTALL_DATA} ${WRKSRC}/sample_labs/ethernet_switch/ethsw1.net ${EXAMPLESDIR}/sample_labs/ethernet_switch - ${MKDIR} ${EXAMPLESDIR}/sample_labs/frame_relay + @${MKDIR} ${EXAMPLESDIR}/sample_labs/frame_relay ${INSTALL_DATA} ${WRKSRC}/sample_labs/frame_relay/frame_relay1.net ${EXAMPLESDIR}/sample_labs/frame_relay - ${MKDIR} ${EXAMPLESDIR}/sample_labs/multiserver + @${MKDIR} ${EXAMPLESDIR}/sample_labs/multiserver ${INSTALL_DATA} ${WRKSRC}/sample_labs/multiserver/multiserver.net ${EXAMPLESDIR}/sample_labs/multiserver - ${MKDIR} ${EXAMPLESDIR}/sample_labs/pix + @${MKDIR} ${EXAMPLESDIR}/sample_labs/pix ${INSTALL_DATA} ${WRKSRC}/sample_labs/pix/pixtest.net ${EXAMPLESDIR}/sample_labs/pix - ${MKDIR} ${EXAMPLESDIR}/sample_labs/simple1 + @${MKDIR} ${EXAMPLESDIR}/sample_labs/simple1 ${INSTALL_DATA} ${WRKSRC}/sample_labs/simple1/simple1.net ${EXAMPLESDIR}/sample_labs/simple1 - ${MKDIR} ${EXAMPLESDIR}/sample_labs/simple2 + @${MKDIR} ${EXAMPLESDIR}/sample_labs/simple2 ${INSTALL_DATA} ${WRKSRC}/sample_labs/simple2/simple2.net ${EXAMPLESDIR}/sample_labs/simple2 ${INSTALL_DATA} ${WRKSRC}/sample_labs/all_config_options.txt ${EXAMPLESDIR}/sample_labs +.endif + +pre-deinstall: + @PKG_PREFIX=${PREFIX} ${SH} ${PKGDEINSTALL} ${PKGNAME} DEINSTALL .include <bsd.port.mk> diff --git a/emulators/dynagen/files/patch-setup.py b/emulators/dynagen/files/patch-setup.py index c1479b0c8159..7814fd41057f 100644 --- a/emulators/dynagen/files/patch-setup.py +++ b/emulators/dynagen/files/patch-setup.py @@ -1,6 +1,6 @@ --- /dev/null 2008-06-11 11:33:00.000000000 +0400 +++ setup.py 2008-06-11 11:38:41.000000000 +0400 -@@ -0,0 +1,22 @@ +@@ -0,0 +1,21 @@ +#!/usr/bin/env python + +"""Setup script for the dynagen module distribution.""" @@ -16,9 +16,8 @@ + author_email = "dynagen@gmail.com", + url = "http://sourceforge.net/projects/dyna-gen", + -+ py_modules = ['confConsole','configobj','console','dynamips_lib', -+ 'pemu_lib', 'pemubin', 'pemuwrapper', -+ 'validate'] ++ py_modules = ['confConsole','console','dynamips_lib', ++ 'pemu_lib', 'pemubin', 'pemuwrapper'] +) + +print "If you have installed the modules, copy dynagen to some " diff --git a/emulators/dynagen/pkg-deinstall b/emulators/dynagen/pkg-deinstall new file mode 100644 index 000000000000..832f1b7289a7 --- /dev/null +++ b/emulators/dynagen/pkg-deinstall @@ -0,0 +1,6 @@ +#!/bin/sh +if [ "$2" = "DEINSTALL" ]; then + cmp -s -z "${PKG_PREFIX}/etc/dynagen.ini.sample" "${PKG_PREFIX}/etc/dynagen.ini" && \ + rm -f "${PKG_PREFIX}/etc/dynagen.ini" +fi +exit 0 diff --git a/emulators/dynagen/pkg-install b/emulators/dynagen/pkg-install new file mode 100644 index 000000000000..1a2f20b07d19 --- /dev/null +++ b/emulators/dynagen/pkg-install @@ -0,0 +1,4 @@ +#!/bin/sh +[ "$2" = "POST-INSTALL" -a ! -e ${PKG_PREFIX}/etc/dynagen.ini ] && \ + cp -p ${PKG_PREFIX}/etc/dynagen.ini.sample ${PKG_PREFIX}/etc/dynagen.ini +exit 0 diff --git a/emulators/dynagen/pkg-plist b/emulators/dynagen/pkg-plist deleted file mode 100644 index cfc8517357ee..000000000000 --- a/emulators/dynagen/pkg-plist +++ /dev/null @@ -1,78 +0,0 @@ -bin/dynagen -@unexec if cmp -s %D/etc/dynagen.ini.sample %D/etc/dynagen.ini; then rm -f %D/etc/dynagen.ini; fi -etc/dynagen.ini.sample -@exec if [ ! -f %D/etc/dynagen.ini ] ; then cp -p %D/%F %B/dynagen.ini; fi -%%PYTHON_SITELIBDIR%%/confConsole.py -%%PYTHON_SITELIBDIR%%/configobj.py -%%PYTHON_SITELIBDIR%%/console.py -%%PYTHON_SITELIBDIR%%/dynamips_lib.py -%%PYTHON_SITELIBDIR%%/pemu_lib.py -%%PYTHON_SITELIBDIR%%/pemubin.py -%%PYTHON_SITELIBDIR%%/pemuwrapper.py -%%PYTHON_SITELIBDIR%%/validate.py -%%PYTHON_SITELIBDIR%%/confConsole.pyc -%%PYTHON_SITELIBDIR%%/configobj.pyc -%%PYTHON_SITELIBDIR%%/console.pyc -%%PYTHON_SITELIBDIR%%/dynamips_lib.pyc -%%PYTHON_SITELIBDIR%%/pemu_lib.pyc -%%PYTHON_SITELIBDIR%%/pemubin.pyc -%%PYTHON_SITELIBDIR%%/pemuwrapper.pyc -%%PYTHON_SITELIBDIR%%/validate.pyc -%%PYTHON_SITELIBDIR%%/confConsole.pyo -%%PYTHON_SITELIBDIR%%/configobj.pyo -%%PYTHON_SITELIBDIR%%/console.pyo -%%PYTHON_SITELIBDIR%%/dynamips_lib.pyo -%%PYTHON_SITELIBDIR%%/pemu_lib.pyo -%%PYTHON_SITELIBDIR%%/pemubin.pyo -%%PYTHON_SITELIBDIR%%/pemuwrapper.pyo -%%PYTHON_SITELIBDIR%%/validate.pyo -%%EXAMPLESDIR%%/sample_labs/ethernet_switch/ethsw1.net -%%EXAMPLESDIR%%/sample_labs/frame_relay/frame_relay1.net -%%EXAMPLESDIR%%/sample_labs/multiserver/multiserver.net -%%EXAMPLESDIR%%/sample_labs/pix/pixtest.net -%%EXAMPLESDIR%%/sample_labs/simple1/simple1.net -%%EXAMPLESDIR%%/sample_labs/simple2/simple2.net -%%EXAMPLESDIR%%/sample_labs/all_config_options.txt -@dirrm %%EXAMPLESDIR%%/sample_labs/ethernet_switch -@dirrm %%EXAMPLESDIR%%/sample_labs/frame_relay -@dirrm %%EXAMPLESDIR%%/sample_labs/multiserver -@dirrm %%EXAMPLESDIR%%/sample_labs/pix -@dirrm %%EXAMPLESDIR%%/sample_labs/simple1 -@dirrm %%EXAMPLESDIR%%/sample_labs/simple2 -@dirrm %%EXAMPLESDIR%%/sample_labs -@dirrm %%EXAMPLESDIR%% -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image001.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image002.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image002.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image003.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image003.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image004.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image004.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image005.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image006.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image007.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image008.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image009.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image010.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image011.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image011.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image012.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image012.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image013.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image013.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image014.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image014.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image015.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image016.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image017.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image018.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image019.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image020.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image021.gif -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image022.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial_files/image023.jpg -%%PORTDOCS%%%%DOCSDIR%%/tutorial.htm -%%PORTDOCS%%@dirrm %%DOCSDIR%%/tutorial_files -%%PORTDOCS%%@dirrm %%DOCSDIR%% -%%DATADIR%%/configspec -@dirrm %%DATADIR%% |