aboutsummaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
authorWen Heping <wen@FreeBSD.org>2010-05-06 08:14:51 +0000
committerWen Heping <wen@FreeBSD.org>2010-05-06 08:14:51 +0000
commit06613f3ac6f8eb916daab2227cd516ac226d1deb (patch)
tree45e32c43b3068c442e6df5f92ff2129d2c978d3b /math
parent6696bb366b4199738da3b5ed9ca437d9357944b7 (diff)
downloadports-06613f3ac6f8eb916daab2227cd516ac226d1deb.tar.gz
ports-06613f3ac6f8eb916daab2227cd516ac226d1deb.zip
Notes
Diffstat (limited to 'math')
-rw-r--r--math/Makefile1
-rw-r--r--math/ann/Makefile30
-rw-r--r--math/ann/distinfo3
-rw-r--r--math/ann/files/patch-Makefile149
-rw-r--r--math/ann/pkg-descr5
-rw-r--r--math/ann/pkg-plist9
6 files changed, 197 insertions, 0 deletions
diff --git a/math/Makefile b/math/Makefile
index b9cdf226735a..e64f71fd29bf 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -19,6 +19,7 @@
SUBDIR += add
SUBDIR += algae
SUBDIR += algotutor
+ SUBDIR += ann
SUBDIR += apc
SUBDIR += aribas
SUBDIR += arpack
diff --git a/math/ann/Makefile b/math/ann/Makefile
new file mode 100644
index 000000000000..8fbe200649ff
--- /dev/null
+++ b/math/ann/Makefile
@@ -0,0 +1,30 @@
+# New ports collection makefile for: ann
+# Date created: 2010-04-23
+# Whom: Tz-Huan Huang <tzhuan@csie.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= ann
+PORTVERSION= 1.1.2
+CATEGORIES= math science
+MASTER_SITES= http://www.cs.umd.edu/~mount/ANN/Files/1.1.2/
+DISTNAME= ann_1.1.2
+
+MAINTAINER= tzhuan@csie.org
+COMMENT= A Library for Approximate Nearest Neighbor Searching
+
+WRKSRC= ${WRKDIR}/ann_1.1.2
+USE_LDCONFIG= yes
+USE_GMAKE= yes
+
+post-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/lib/libann.so.0 ${PREFIX}/lib
+ ${INSTALL_PROGRAM} ${WRKSRC}/lib/libann.a ${PREFIX}/lib
+ ${LN} -fs libann.so.0 ${PREFIX}/lib/libann.so
+ ${MKDIR} ${PREFIX}/include/ANN
+ ${INSTALL_DATA} ${WRKSRC}/include/ANN/* ${PREFIX}/include/ANN
+ ${MKDIR} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/doc/ANNmanual.pdf ${DOCSDIR}
+
+.include <bsd.port.mk>
diff --git a/math/ann/distinfo b/math/ann/distinfo
new file mode 100644
index 000000000000..cad2cd11d0f6
--- /dev/null
+++ b/math/ann/distinfo
@@ -0,0 +1,3 @@
+MD5 (ann_1.1.2.tar.gz) = 7ffaacc7ea79ca39d4958a6378071365
+SHA256 (ann_1.1.2.tar.gz) = eea03f2e224b66813226d775053316675375dcec45bd263674c052d9324a49a5
+SIZE (ann_1.1.2.tar.gz) = 590517
diff --git a/math/ann/files/patch-Makefile b/math/ann/files/patch-Makefile
new file mode 100644
index 000000000000..d9309c87d7d5
--- /dev/null
+++ b/math/ann/files/patch-Makefile
@@ -0,0 +1,149 @@
+--- Makefile.orig 2010-01-28 12:40:01.000000000 +0800
++++ Makefile 2010-04-23 20:57:18.091096908 +0800
+@@ -1,115 +1,32 @@
+-#-----------------------------------------------------------------------------
+-# Top-level Makefile for ANN.
+-#
+-# ANN: Approximate Nearest Neighbors
+-# Version: 1.1 05/03/05
+-#-----------------------------------------------------------------------------
+-# Copyright (c) 1997-2005 University of Maryland and Sunil Arya and
+-# David Mount. All Rights Reserved.
+-#
+-# This software and related documentation is part of the Approximate
+-# Nearest Neighbor Library (ANN). This software is provided under
+-# the provisions of the Lesser GNU Public License (LGPL). See the
+-# file ../ReadMe.txt for further information.
+-#
+-# The University of Maryland (U.M.) and the authors make no
+-# representations about the suitability or fitness of this software for
+-# any purpose. It is provided "as is" without express or implied
+-# warranty.
+-#-----------------------------------------------------------------------------
+-# Revision 0.1 09/06/97
+-# alpha release
+-# Revision 0.2 06/26/98
+-# Minor changes to fix compilation errors on SGI systems.
+-# Revision 1.0 04/01/05
+-# Initial release (finally!)
+-# Added linux-g++ target
+-# Revision 1.1 05/03/05
+-# Added macosx-g++ target
+-#-----------------------------------------------------------------------------
+-
+-#-----------------------------------------------------------------------------
+-# default: list the options
+-# The following legacy targets are also available.
+-# make sunos4 for Sun with SunOS 4.x
+-# make sunos4-g++ for Sun with SunOS 4.x and g++
+-# make alpha-g++ for DEC Alpha and g++
+-# The following targets are used for internal development only
+-# make authors-debug author's debugging
+-# make authors-perf author's performance evaluations
+-# make distribution author's generation of distribution file
+-#-----------------------------------------------------------------------------
+-default:
+- @echo "Enter one of the following:"
+- @echo " make linux-g++ for Linux and g++"
+- @echo " make macosx-g++ for Mac OS X and g++"
+- @echo " make sunos5 for Sun with SunOS 5.x"
+- @echo " make sunos5-sl for Sun with SunOS 5.x, make shared libs"
+- @echo " make sunos5-g++ for Sun with SunOS 5.x and g++"
+- @echo " make sunos5-g++-sl for Sun with SunOS 5.x, g++, make shared libs"
+- @echo " make clean remove .o files"
+- @echo " make realclean remove .o, library and executable files"
+- @echo " "
+- @echo "See file Makefile for other compilation options, such as disabling"
+- @echo "performance measurement code."
+-
+-#-----------------------------------------------------------------------------
+-# main make entry point
+-#-----------------------------------------------------------------------------
+-alpha-g++ macosx-g++ linux-g++ sgi sunos4 sunos4-g++ sunos5 sunos5-g++ sunos5-g++-sl authors-debug authors-perf:
+- cd src ; $(MAKE) $@
+- cd test ; $(MAKE) $@
+- cd sample ; $(MAKE) $@
+- cd ann2fig ; $(MAKE) $@
+-
+-#-----------------------------------------------------------------------------
+-# Remove .o files and core files
+-#-----------------------------------------------------------------------------
++CXXFLAGS+=-Iinclude -Isrc -fPIC
++LDFLAGS+=
++VPATH=src
++SRCS=ANN.cpp \
++ bd_fix_rad_search.cpp bd_pr_search.cpp bd_search.cpp bd_tree.cpp \
++ brute.cpp perf.cpp kd_tree.cpp kd_util.cpp \
++ kd_dump.cpp kd_fix_rad_search.cpp kd_pr_search.cpp kd_search.cpp kd_split.cpp
++OBJS=$(SRCS:.cpp=.o)
++LIBDIR=lib
++
++ANN_SO=libann.so
++ANN_A=libann.a
++ANN_SONAME=$(ANN_SO).0
++LIBANN_SO=$(LIBDIR)/$(ANN_SONAME)
++LIBANN_A=$(LIBDIR)/$(ANN_A)
++TARGETS=$(LIBANN_SO) $(LIBANN_A)
++
++all: $(TARGETS)
++
++install: all
++
++%.o: %.cpp
++ $(CXX) $(CXXFLAGS) -c $< -o $@
++
++$(LIBANN_SO): $(OBJS)
++ $(CXX) $^ -o $@ -shared -Wl,-soname,$(ANN_SONAME) $(LDFLAGS)
++
++$(LIBANN_A): $(OBJS)
++ $(AR) rcs $@ $^
++
+ clean:
+- cd src ; $(MAKE) clean
+- cd test ; $(MAKE) clean
+- cd sample ; $(MAKE) clean
+- cd ann2fig ; $(MAKE) clean
+- cd doc ; $(MAKE) clean
+- cd MS_Win32; $(MAKE) clean
+- cd validate ; $(MAKE) clean
+-
+-#-----------------------------------------------------------------------------
+-# Remove everthing that can be remade
+-#-----------------------------------------------------------------------------
+-realclean:
+- -rm -f lib/*
+- -rm -f bin/*
+- cd src ; $(MAKE) realclean
+- cd test ; $(MAKE) realclean
+- cd sample ; $(MAKE) realclean
+- cd ann2fig ; $(MAKE) realclean
+- cd doc ; $(MAKE) realclean
+- cd MS_Win32; $(MAKE) realclean
+- cd validate ; $(MAKE) realclean
+-
+-#-----------------------------------------------------------------------------
+-# Make distribution package (for use by authors only)
+-#-----------------------------------------------------------------------------
+-DISTR = ann_1.1.2
+-
+-distribution: realclean
+- cd .. ; mv -f $(DISTR) $(DISTR)-old; mkdir $(DISTR)
+- cp Copyright.txt ../$(DISTR)
+- cp License.txt ../$(DISTR)
+- cp Make-config ../$(DISTR)
+- cp Makefile ../$(DISTR)
+- cp ReadMe.txt ../$(DISTR)
+- cp -r MS_Win32 ../$(DISTR)
+-# cd ..; mv -f $(DISTR)_MS_Win32_bin $(DISTR)_MS_Win32_bin-old
+- cp -r MS_Win32_bin ../$(DISTR)_MS_Win32_bin
+- cp -r bin ../$(DISTR)
+- cp -r include ../$(DISTR)
+- cp -r lib ../$(DISTR)
+- cp -r src ../$(DISTR)
+- cp -r test ../$(DISTR)
+- cp -r sample ../$(DISTR)
+- cp -r ann2fig ../$(DISTR)
+- cd ../$(DISTR); mkdir doc
+- cp doc/*.pdf ../$(DISTR)/doc
+-# cd .. ; tar -cfv $(DISTR).tar $(DISTR) ; gzip $(DISTR).tar
++ rm -f $(TARGETS) $(OBJS)
diff --git a/math/ann/pkg-descr b/math/ann/pkg-descr
new file mode 100644
index 000000000000..9d341444642e
--- /dev/null
+++ b/math/ann/pkg-descr
@@ -0,0 +1,5 @@
+ANN is a library written in C++, which supports data structures
+and algorithms for both exact and approximate nearest neighbor
+neighbor searching in arbitrarily high dimensions.
+
+WWW: http://www.cs.umd.edu/~mount/ANN/
diff --git a/math/ann/pkg-plist b/math/ann/pkg-plist
new file mode 100644
index 000000000000..e3bf24fcdb64
--- /dev/null
+++ b/math/ann/pkg-plist
@@ -0,0 +1,9 @@
+include/ANN/ANN.h
+include/ANN/ANNx.h
+include/ANN/ANNperf.h
+lib/libann.so.0
+lib/libann.so
+lib/libann.a
+%%DOCSDIR%%/ANNmanual.pdf
+@dirrm include/ANN
+@dirrm %%DOCSDIR%%