Bug 96161 - [NEW PORT] net/DIMES: Distributed research project for measurement topology of the Int
Summary: [NEW PORT] net/DIMES: Distributed research project for measurement topology o...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Herve Quiroz
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-22 15:30 UTC by Stas Timokhin
Modified: 2006-06-13 00:41 UTC (History)
0 users

See Also:


Attachments
dimes.shar (16.77 KB, text/plain)
2006-04-22 15:30 UTC, Stas Timokhin
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stas Timokhin 2006-04-22 15:30:09 UTC
		[NEW PORT] net/DIMES: Distributed research project for measurement topology of the Int
ernet
Comment 1 Edwin Groothuis freebsd_committer 2006-04-22 15:32:10 UTC
Class Changed
From-To: update->change-request

Fix category (new ports should be change-requests)
Comment 2 Herve Quiroz freebsd_committer 2006-05-03 10:26:34 UTC
Responsible Changed
From-To: freebsd-ports-bugs->hq

I'll handle this.
Comment 3 Herve Quiroz freebsd_committer 2006-05-03 10:26:46 UTC
State Changed
From-To: open->feedback

There are several improvements to be made to the port before it may be added to 
the tree: 

- "USE_JAVA=1.4[+]" is a wrong syntax. It's either "1.4" or "1.4+". 

- The ports defines specific requirements regarding JAVA_VENDOR and JAVA_OS. I 
think we should document (in comments) the reason why other JDKs are not 
suitable. 

- Given the Makefile in work/DIMES/ provides an empty 'all' target, the port 
could probably define NO_BUILD. 

- portlint give the following: 

WARN: Makefile: the port uses Java but is not part of the ``java'' category 

- When building as a user, the port fails: 

===>  Applying FreeBSD patches for DIMES-0.4.2 
cd /tmp/dimes/work/DIMES; /bin/sh ./fix_permissions.sh;  echo "JAVA_HOME=/usr/local/linux-sun-jdk1.4.2" >> /tmp/dimes/work/DIMES/colors.sh; 
verifying that script it running using root.....[FAILED] 
Error: you must run this script as user root 

Ports should be able to build as a normal user. Hence I suggest this task is 
performed during 'do-install' stage when we are sure user is super-user. 

- There are many INSTALL_DATA lines in the Makefile. We could probably reduce 
the size of Makefile by using FIND | INSTALL_DATA (see textproc/saxon for 
example). 

- I don't know if we really need to install *.dll files. 

- As suggested in the Porter's Handbook, Java ports should install 
machine-independent files (such as JAR files and classes) in 
DATADIR=${JAVASHAREDIR}/${PORTNAME}. BTW, installing files in 
${PREFIX}/${PORTNAME} is not a recommended practice.
Comment 4 Herve Quiroz freebsd_committer 2006-06-06 10:26:54 UTC
State Changed
From-To: feedback->suspended

No feedback from original submitter for more than a month. 

If you still want this new port to be added, please send a follow-up to this 
PR. I can help you to improve the port if you are still interested. 

NOTE: the PR will stay suspended for 2 more weeks and then I will close it if 
no feedback is received.
Comment 5 Stas Timokhin 2006-06-10 16:39:59 UTC
# 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:
#
#	/usr/ports/net/DIMES/
#	/usr/ports/net/DIMES/distinfo
#	/usr/ports/net/DIMES/Makefile
#	/usr/ports/net/DIMES/pkg-descr
#	/usr/ports/net/DIMES/files
#	/usr/ports/net/DIMES/files/patch-configure
#	/usr/ports/net/DIMES/pkg-plist
#
echo c - /usr/ports/net/DIMES/
mkdir -p /usr/ports/net/DIMES/ > /dev/null 2>&1
echo x - /usr/ports/net/DIMES/distinfo
sed 's/^X//' >/usr/ports/net/DIMES/distinfo << 
'END-of-/usr/ports/net/DIMES/distinfo'
XMD5 (DIMES-0-4-2.tar.gz) = 3396594e9e5f949c830beff62a2d07f4
XSIZE (DIMES-0-4-2.tar.gz) = 6404942
END-of-/usr/ports/net/DIMES/distinfo
echo x - /usr/ports/net/DIMES/Makefile
sed 's/^X//' >/usr/ports/net/DIMES/Makefile << 
'END-of-/usr/ports/net/DIMES/Makefile'
X# New ports collection makefile for:   DIMES
X# Date created:        18 April 2006
X# Whom:            stast
X#
X# $FreeBSD$
X#
X
XPORTNAME=	DIMES
XDISTVERSION=	0-4-2
XCATEGORIES=	net java
XMASTER_SITES=	http://netdimes.org/downloads/
X
XMAINTAINER=	stast@bsdportal.ru
XCOMMENT=	Distributed research project for measurement topology of the 
Internet
X
XNO_PACKAGE=	There is the string in properties.xml which system-depends
XNO_BUILD=	.jar files are ready for use.
X
XWRKSRC=		${WRKDIR}/DIMES
X
XUSE_JAVA=	YES
XJAVA_VERSION=	1.4+
X#java-linux required
XJAVA_OS=	linux
X#all vendors except forbidden: ibm
XJAVA_VENDOR=	sun blackdown
XJAVA_RUN=	yes
XDATADIR=	${JAVASHAREDIR}/dimes
X
Xpost-patch:
X	cd ${WRKDIR}/DIMES; \
X	echo "JAVA_HOME=${JAVA_HOME}" >> ${WRKDIR}/DIMES/colors.sh;
Xdo-install:
X	cd ${WRKDIR}/DIMES; ${SH} ./fix_permissions.sh; ./configure ${JAVASHAREDIR}
X	@${MKDIR} ${DATADIR}
X	@${MKDIR} ${DATADIR}/Classes
X	@${MKDIR} ${DATADIR}/Classes/Base
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/History
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/Incoming
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/Incoming/Keepalive
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/Outgoing
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/Outgoing/log
X	@${MKDIR} -m 0777 ${DATADIR}/Classes/Base/Outgoing/results
X	@${MKDIR} ${DATADIR}/Classes/Base/conf
X	@${MKDIR} ${DATADIR}/Classes/Base/resources
X	@${MKDIR} ${DATADIR}/Classes/Base
X	@${MKDIR} ${DATADIR}/Classes/Base
X	@${MKDIR} ${DATADIR}/Classes/JARs
X	@${MKDIR} ${DATADIR}/Licences
X	@${INSTALL_DATA} ${WRKSRC}/Classes/'AgentLauncher$$1.class' 
${DATADIR}/Classes/'AgentLauncher$$1.class'
X	@${INSTALL_DATA} ${WRKSRC}/Classes/'AgentLauncher$$2.class' 
${DATADIR}/Classes/'AgentLauncher$$2.class'
X	@${INSTALL_DATA} ${WRKSRC}/Classes/AgentLauncher.class 
${DATADIR}/Classes/AgentLauncher.class
X	@cd ${WRKSRC}/Classes/ &&  ${FIND} . -type f -and \( -name "*.jpg" -or -name 
"*.gif" -or -name "*.dll" -or -name "*.ico" -or -name "*.so" -or -name 
"*.zip"  -or -name "*.GIF" -or -name "*.txt" -or -name "*.properties" \) 
-exec ${INSTALL_DATA} {} ${DATADIR}/Classes/{} \;
X	@cd ${WRKSRC}/Classes/Base/resources/ &&  ${FIND} . -type f -and \( -name 
"*.jar" -or -name "*.txt" -or -name "*.keystore" \) -exec ${INSTALL_DATA} {} 
${DATADIR}/Classes/Base/resources/{} \;
X	@${INSTALL_DATA} -m 0666 ${WRKSRC}/Classes/Base/resources/layouts.bin 
${DATADIR}/Classes/Base/resources/layouts.bin
X	@${INSTALL_DATA} -m 0666 ${WRKSRC}/Classes/Base/resources/layouts.meta 
${DATADIR}/Classes/Base/resources/layouts.meta
X	@${INSTALL_DATA} -m 0666 ${WRKSRC}/Classes/Base/conf/properties.xml 
${DATADIR}/Classes/Base/conf/properties.xml
X	@${INSTALL_PROGRAM} ${WRKSRC}/Classes/JARs/jarsigner 
${DATADIR}/Classes/JARs/jarsigner
X	@${INSTALL_DATA} ${WRKSRC}/Classes/JARs/10.jar 
${DATADIR}/Classes/JARs/10.jar
X	@${INSTALL_DATA} ${WRKSRC}/Classes/JARs/dimesAgent.keystore 
${DATADIR}/Classes/JARs/dimesAgent.keystore
X	@cd ${WRKSRC}/Licences/ &&  ${FIND} . -type f -name "*.txt" -exec 
${INSTALL_MAN} {} ${DATADIR}/Licences/{} \;
X	@${INSTALL_SCRIPT} -m 4755 ${WRKSRC}/agent.sh ${DATADIR}/agent.sh
X	@${INSTALL_SCRIPT} ${WRKSRC}/colors.sh ${DATADIR}/colors.sh
X.include <bsd.port.mk>
END-of-/usr/ports/net/DIMES/Makefile
echo x - /usr/ports/net/DIMES/pkg-descr
sed 's/^X//' >/usr/ports/net/DIMES/pkg-descr << 
'END-of-/usr/ports/net/DIMES/pkg-descr'
XDIMES is a distributed scientific research project, 
Xaimed to study the structure and topology of the Internet, 
Xwith the help of a volunteer community 
X(similar in spirit to projects such as SETI@Home). 
X
XWWW: http://netdimes.org
X- Stas Timokhin
Xstast@bsdportal.ru
END-of-/usr/ports/net/DIMES/pkg-descr
echo c - /usr/ports/net/DIMES/files
mkdir -p /usr/ports/net/DIMES/files > /dev/null 2>&1
echo x - /usr/ports/net/DIMES/files/patch-configure
sed 's/^X//' >/usr/ports/net/DIMES/files/patch-configure << 
'END-of-/usr/ports/net/DIMES/files/patch-configure'
X*** configure.orig	Thu Nov 17 16:23:48 2005
X--- configure	Wed Apr 19 23:00:24 2006
X***************
X*** 1,40 ****
X  #!/bin/sh
X  # Written by Danny Bickson, HUJI
X  # modified by Ohad Serfaty , TAU (11.9.05)
X! #USERNAME=`whoami`
X  CURRENT_DIR=$(pwd)
X- CLASSES_DIR="$CURRENT_DIR/Classes"
X- BASE_DIR="$CURRENT_DIR/Classes/Base"
X- CONF_DIR="$BASE_DIR/conf"
X  
X! . colors.sh
X! echo "Installing DIMES"
X! echo "Updating properties file $CONF_DIR/properties.xml"
X! echo -n "You can later edit this file manually if needed........."
X  
X! test -f $CONF_DIR/properties.xml  
X! verify $?  "Missing properties file: $CONF_DIR/properties.xml" 
X  
X  echo -n "setting JARS dir: $CLASSES_DIR/JARs.........................."
X! sed -i "s#<jarDir>.*</jarDir>#<jarDir>$CLASSES_DIR/JARs</jarDir>#g" 
$CONF_DIR/properties.xml
X! sed -i "s#<base>.*</base>#<base>$BASE_DIR</base>#g" 
$CONF_DIR/properties.xml
X! verify $?
X! 
X! 
X! # deprecated : set IP address :
X! #IP_ADDR=`ifconfig eth0 | grep "inet addr" | awk '{print $2}' | sed -e 
"s/addr\://g"`
X! #echo -n "setting IP address: $IP_ADDR............................"
X! #if [ $IP_ADDR != "" ]; then
X! #	sed -i "s#132.66.48.22#$IP_ADDR#g" $CONF_DIR/properties.xml
X! #fi
X! #verify $?
X! 
X! chmod a+rx . *.sh > /dev/null 2>&1
X! #verify $? "failed to setup file permissions"
X! 
X! #The following should be executed as root!
X! echo "Going to set root priviliges for running ping and traceroute"
X! echo "Please enter root password"
X! sudo bash ./fix_permissions.sh
X! 
X! echo "Installation OK!"
X--- 1,15 ----
X  #!/bin/sh
X  # Written by Danny Bickson, HUJI
X  # modified by Ohad Serfaty , TAU (11.9.05)
X! # modified by Stas Timokhin for FreeBSD port
X  CURRENT_DIR=$(pwd)
X  
X! CLASSES_DIR="$1/dimes/Classes"
X! BASE_DIR="$1/dimes/Classes/Base"
X  
X! CONF_DIR="$CURRENT_DIR/Classes/Base/conf"
X  
X+ echo "Updating properties file $CONF_DIR/properties.xml"
X  echo -n "setting JARS dir: $CLASSES_DIR/JARs.........................."
X! sed -i .bak "s#<jarDir>.*</jarDir>#<jarDir>$CLASSES_DIR/JARs</jarDir>#g" 
$CONF_DIR/properties.xml
X! sed -i .bak "s#<base>.*</base>#<base>$BASE_DIR</base>#g" 
$CONF_DIR/properties.xml
END-of-/usr/ports/net/DIMES/files/patch-configure
echo x - /usr/ports/net/DIMES/pkg-plist
sed 's/^X//' >/usr/ports/net/DIMES/pkg-plist << 
'END-of-/usr/ports/net/DIMES/pkg-plist'
Xshare/java/dimes/Classes/AgentLauncher$1.class
Xshare/java/dimes/Classes/AgentLauncher$2.class
Xshare/java/dimes/Classes/AgentLauncher.class
Xshare/java/dimes/Classes/Base/conf/countries-xml.txt
Xshare/java/dimes/Classes/Base/conf/logging.properties
Xshare/java/dimes/Classes/Base/conf/properties.xml
Xshare/java/dimes/Classes/Base/resources/About16.gif
Xshare/java/dimes/Classes/Base/resources/CommunicationDetector.dll
Xshare/java/dimes/Classes/Base/resources/DIMES.gif
Xshare/java/dimes/Classes/Base/resources/DIMESIcon.ico
Xshare/java/dimes/Classes/Base/resources/DIMES_Large.jpg
Xshare/java/dimes/Classes/Base/resources/Delete16.gif
Xshare/java/dimes/Classes/Base/resources/DimesSplash.jpg
Xshare/java/dimes/Classes/Base/resources/Help16.gif
Xshare/java/dimes/Classes/Base/resources/IDW.jar
Xshare/java/dimes/Classes/Base/resources/MTR.dll
Xshare/java/dimes/Classes/Base/resources/MySystray4j.jar
Xshare/java/dimes/Classes/Base/resources/Pause16.gif
Xshare/java/dimes/Classes/Base/resources/Play16.gif
Xshare/java/dimes/Classes/Base/resources/Properties16.gif
Xshare/java/dimes/Classes/Base/resources/Save16.gif
Xshare/java/dimes/Classes/Base/resources/Stop16.gif
Xshare/java/dimes/Classes/Base/resources/StopRed16.gif
Xshare/java/dimes/Classes/Base/resources/WebComponent16.gif
Xshare/java/dimes/Classes/Base/resources/WebComponent24.gif
Xshare/java/dimes/Classes/Base/resources/a1.GIF
Xshare/java/dimes/Classes/Base/resources/about.txt
Xshare/java/dimes/Classes/Base/resources/changeLog.txt
Xshare/java/dimes/Classes/Base/resources/client.keystore
Xshare/java/dimes/Classes/Base/resources/dimes.jpg
Xshare/java/dimes/Classes/Base/resources/dimesIcon.jpg
Xshare/java/dimes/Classes/Base/resources/dimesTransparent2.gif
Xshare/java/dimes/Classes/Base/resources/dom4j-full.jar
Xshare/java/dimes/Classes/Base/resources/exec.gif
Xshare/java/dimes/Classes/Base/resources/fav.gif
Xshare/java/dimes/Classes/Base/resources/folder_documents.gif
Xshare/java/dimes/Classes/Base/resources/glue.gif
Xshare/java/dimes/Classes/Base/resources/hand.gif
Xshare/java/dimes/Classes/Base/resources/handtool.gif
Xshare/java/dimes/Classes/Base/resources/helpicon.gif
Xshare/java/dimes/Classes/Base/resources/layouts.bin
Xshare/java/dimes/Classes/Base/resources/layouts.meta
Xshare/java/dimes/Classes/Base/resources/libcallmtr.so
Xshare/java/dimes/Classes/Base/resources/m1.GIF
Xshare/java/dimes/Classes/Base/resources/n1.GIF
Xshare/java/dimes/Classes/Base/resources/network.gif
Xshare/java/dimes/Classes/Base/resources/packettrain.dll
Xshare/java/dimes/Classes/Base/resources/pacman.gif
Xshare/java/dimes/Classes/Base/resources/redWebComponent.gif
Xshare/java/dimes/Classes/Base/resources/s1.GIF
Xshare/java/dimes/Classes/Base/resources/scared.gif
Xshare/java/dimes/Classes/Base/resources/server.keystore
Xshare/java/dimes/Classes/Base/resources/skinlf.jar
Xshare/java/dimes/Classes/Base/resources/snail.ico
Xshare/java/dimes/Classes/Base/resources/snail.jpg
Xshare/java/dimes/Classes/Base/resources/systray4j.dll
Xshare/java/dimes/Classes/Base/resources/toxicthemepack.zip
Xshare/java/dimes/Classes/Base/resources/winnerFace.gif
Xshare/java/dimes/Classes/JARs/10.jar
Xshare/java/dimes/Classes/JARs/dimesAgent.keystore
Xshare/java/dimes/Classes/JARs/jarsigner
Xshare/java/dimes/Licences/DIMES-license.txt
Xshare/java/dimes/Licences/dom4j-license.txt
Xshare/java/dimes/Licences/gpl.txt
Xshare/java/dimes/Licences/lgpl.txt
Xshare/java/dimes/agent.sh
Xshare/java/dimes/colors.sh
Xshare/nls/POSIX
Xshare/nls/en_US.US-ASCII
X@dirrm share/java/dimes/Licences
X@dirrm share/java/dimes/Classes/JARs
X@dirrm share/java/dimes/Classes/Base/resources
X@dirrm share/java/dimes/Classes/Base/conf
X@dirrm share/java/dimes/Classes/Base/Outgoing/results
X@dirrm share/java/dimes/Classes/Base/Outgoing/log
X@dirrm share/java/dimes/Classes/Base/Outgoing
X@dirrm share/java/dimes/Classes/Base/Incoming/Keepalive
X@dirrm share/java/dimes/Classes/Base/Incoming
X@dirrm share/java/dimes/Classes/Base/History
X@dirrm share/java/dimes/Classes/Base
X@dirrm share/java/dimes/Classes
X@dirrm share/java/dimes
END-of-/usr/ports/net/DIMES/pkg-plist
exit
Comment 6 Herve Quiroz freebsd_committer 2006-06-11 21:41:56 UTC
State Changed
From-To: suspended->open

New version of the port submitted.
Comment 7 Herve Quiroz freebsd_committer 2006-06-13 00:41:31 UTC
State Changed
From-To: open->closed

New port added. 

Thanks for your contribution!