aboutsummaryrefslogtreecommitdiff
path: root/benchmarks/nqueens
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2005-05-25 10:52:42 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2005-05-25 10:52:42 +0000
commitf497276d3cd63579f02f109990278cff4a4e6975 (patch)
treea7f1c39d72938e6469424a9d991b840fb54bf7fc /benchmarks/nqueens
parent7d74df0c3e787808e9a6615c2c7b66c982d41931 (diff)
downloadports-f497276d3cd63579f02f109990278cff4a4e6975.tar.gz
ports-f497276d3cd63579f02f109990278cff4a4e6975.zip
Notes
Diffstat (limited to 'benchmarks/nqueens')
-rw-r--r--benchmarks/nqueens/Makefile59
-rw-r--r--benchmarks/nqueens/distinfo2
-rw-r--r--benchmarks/nqueens/pkg-descr4
3 files changed, 65 insertions, 0 deletions
diff --git a/benchmarks/nqueens/Makefile b/benchmarks/nqueens/Makefile
new file mode 100644
index 000000000000..a2d1cf46a285
--- /dev/null
+++ b/benchmarks/nqueens/Makefile
@@ -0,0 +1,59 @@
+# New ports collection makefile for: N-Queens
+# Date Created: 2 March 2005
+# Whom: NAKAJI Hiroyuki <nakaji@jp.freebsd.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= nqueens
+PORTVERSION= 1.0
+CATEGORIES= benchmarks
+MASTER_SITES= http://www.yuba.is.uec.ac.jp/~kis/nq/package/
+DISTNAME= qn24b-version${PORTVERSION}
+EXTRACT_SUFX= .tgz
+
+MAINTAINER= nakaji@jp.freebsd.org
+COMMENT= N-queens benchmark
+
+WRKSRC= ${WRKDIR}/version${PORTVERSION}
+
+OPTIONS= MPI "Build distributed MPI version" off \
+ STATIC "Link resulting binaries statically" off \
+ OPTIMIZED_CFLAGS "Enable extra optimization options" off
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITH_OPTIMIZED_CFLAGS)
+CFLAGS+= -O9 -pipe -s -ffast-math -funroll-loops -fomit-frame-pointer -fexpensive-optimizations
+.endif
+.if defined(WITH_STATIC)
+CFLAGS+= -static
+.endif
+
+PROGS= qn24b_base
+
+.if defined(WITH_MPI)
+MPICC?= ${LOCALBASE}/mpich/bin/mpicc
+BUILD_DEPENDS= ${MPICC}:${PORTSDIR}/net/mpich
+PROGS+= qn24b_mpi
+.endif
+
+post-extract:
+ @${RM} -f ${WRKSRC}/qn24b_base
+
+do-build:
+ cd ${WRKSRC} && \
+ ${CC} ${CFLAGS} -o qn24b_base base/queens.c
+.if defined(WITH_MPI)
+ cd ${WRKSRC} && \
+ ${MPICC} ${CFLAGS} -o qn24b_mpi mpi/main.c
+.endif
+
+PLIST_FILES= ${PROGS:S/^/bin\//}
+
+do-install:
+.for p in ${PROGS}
+ ${INSTALL_PROGRAM} ${WRKSRC}/${p} ${PREFIX}/bin/
+.endfor
+
+.include <bsd.port.post.mk>
diff --git a/benchmarks/nqueens/distinfo b/benchmarks/nqueens/distinfo
new file mode 100644
index 000000000000..781dbe1b4eab
--- /dev/null
+++ b/benchmarks/nqueens/distinfo
@@ -0,0 +1,2 @@
+MD5 (qn24b-version1.0.tgz) = 10fc6239b5e037b3c86890918d33b8f3
+SIZE (qn24b-version1.0.tgz) = 213360
diff --git a/benchmarks/nqueens/pkg-descr b/benchmarks/nqueens/pkg-descr
new file mode 100644
index 000000000000..ef582e73b35e
--- /dev/null
+++ b/benchmarks/nqueens/pkg-descr
@@ -0,0 +1,4 @@
+N-queens benchmark written in C. Includes base version and (optinal)
+distributed MPI version.
+
+WWW: http://www.yuba.is.uec.ac.jp/~kis/nq/index.htm