As-needed fix 324945, added threads and lowmem USE
authorJustin Lecher <jlec@gentoo.org>
Mon, 21 Jun 2010 15:31:15 +0000 (15:31 +0000)
committerJustin Lecher <jlec@gentoo.org>
Mon, 21 Jun 2010 15:31:15 +0000 (15:31 +0000)
Package-Manager: portage-2.2_rc67/cvs/Linux x86_64

sci-biology/yass/ChangeLog
sci-biology/yass/Manifest
sci-biology/yass/files/1.14-as-needed.patch [new file with mode: 0644]
sci-biology/yass/metadata.xml
sci-biology/yass/yass-1.14-r1.ebuild [new file with mode: 0644]

index ade40715038b430220a4e326718452bcb1f28a7f..1d57e131093fa1f57833967ce637f7a8a5573403 100644 (file)
@@ -1,6 +1,12 @@
 # ChangeLog for sci-biology/yass
 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-biology/yass/ChangeLog,v 1.1 2010/06/18 05:52:46 weaver Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-biology/yass/ChangeLog,v 1.2 2010/06/21 15:31:15 jlec Exp $
+
+*yass-1.14-r1 (21 Jun 2010)
+
+  21 Jun 2010; Justin Lecher <jlec@gentoo.org> +files/1.14-as-needed.patch,
+  +yass-1.14-r1.ebuild:
+  As-needed fix 324945, added threads and lowmem USE
 
 *yass-1.14 (18 Jun 2010)
 
index c075626e3e465e2e45e407be839202d2e6210537..f7ba84601808c84590d41ac4fb773a82969c2be6 100644 (file)
@@ -1,4 +1,16 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+AUX 1.14-as-needed.patch 6074 RMD160 25ba88710c272ce01de0aaec39b016b0ec50740f SHA1 1bdc0b6c3101e2d2a8f78526c62bfe136dbfc8e5 SHA256 8782d1ab3c1338dd79063112a4fd990c5e058c1a3f331bf139b97fa4075d135a
 DIST yass-1.14.tar.gz 235530 RMD160 76795d46e466a9f6613a391a2b85a1b795a8a18e SHA1 cb16e207f23a41472a3a301ac923b902f0980036 SHA256 f23da1c16cf98317ad11c085feede9790401e888a95d486b550f0c081d4c9018
+EBUILD yass-1.14-r1.ebuild 850 RMD160 a0cf8cf1942732ebac8ee174ae875df268018e6b SHA1 261c4a72a56218d997a955ca32cb8d38d2145088 SHA256 33ae801ac663e6f1cd9c964c4662ce4ef776b32ed765ed69b3c6f5358be3dcb9
 EBUILD yass-1.14.ebuild 554 RMD160 63aef87c7952a9b760d8f74435c0f3b318d7564f SHA1 4403063ded7f93d2bff9141c425500198b60d359 SHA256 db2b04f7e7e694ae2398c0f8a2c7171c32d5d8a2ae87c7aeead14f0c5474bc02
-MISC ChangeLog 354 RMD160 7f27042c9d9ccbd53d9105c8c31e47b7599e0c3a SHA1 8491adbdf9c91906195bd2e1db5b91808d07aa96 SHA256 c66f4c1c39fc0d0eaa497a229d9b8c8b65d1fe89809c49ad0b38e54ddae11bad
-MISC metadata.xml 259 RMD160 d9d81b67d635fabd81aef8ae0edf971211ae9072 SHA1 8e32f751c67ff891fa35405a2cf6fb33752d6eb1 SHA256 541c3fbcf299d9a8ccf4132ee61f9e53a5d737cefdaa6fdc77764d8d4c7f3110
+MISC ChangeLog 535 RMD160 40e68d814c415c1f9deae391df8f2f3d0bd68c4e SHA1 9cc79e659385e83783d914ab88144982eb060c0e SHA256 969ce0153ca97ec997f4565e6779417ea77fab0d078ec0a651693939d2a031ce
+MISC metadata.xml 423 RMD160 691c8d710a9c959c229432abe7fd68abbc16030f SHA1 0c24243dcc71bd2129811a63a51a9bb1821baa86 SHA256 0e4899e979d9902e3beb03dfdf867e78b91c1ef68f890dc6eff80a99f4d0a8b6
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v2.0.15 (GNU/Linux)
+
+iEYEARECAAYFAkwfhcgACgkQgAnW8HDreRZ7eACfYUMNlW8KrpRtt/awbEiU1zPJ
+1QMAnA+dcNUEy5qyfgISI/Z+EqBcTJ3w
+=k2CM
+-----END PGP SIGNATURE-----
diff --git a/sci-biology/yass/files/1.14-as-needed.patch b/sci-biology/yass/files/1.14-as-needed.patch
new file mode 100644 (file)
index 0000000..cafc0f1
--- /dev/null
@@ -0,0 +1,208 @@
+diff --git a/configure.ac b/configure.ac
+index 68453ef..3ecfd21 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -28,13 +28,11 @@ AC_CHECK_FUNCS([floor memset clock pow sqrt strchr strdup strtol strtoul])
+ dnl 1) threads options
+ 
+ dnl abc) : with-threads option
+-AC_ARG_WITH(
+-      threads,
+-      [  --with-threads          compile with all threads],
+-      [threads="yes"],
+-      [threads="no"])
++AC_ARG_ENABLE(
++      [threads],
++      AS_HELP_STRING([--enable-threads], [compile with all threads]))
+ 
+-if test "$threads" = "yes"; then
++AS_IF([test "x$enable_threads" = "xyes"], [
+   AC_MSG_RESULT(detected cpu parameter: threads);
+  
+   dnl pthread library here ? (UNIX system)
+@@ -46,167 +44,25 @@ if test "$threads" = "yes"; then
+     AC_MSG_RESULT(yes)
+     AC_DEFINE([HAVE_PTHREAD],[1],[pthread available on the computer])
+        CFLAGS=" $CFLAGS -DTHREAD_ASSEMBLE_ALIGN -DTHREAD_FORWARD_REVERSE -DTHREAD_QUERY_CHUNK "
+-       LDFLAGS="$LDFLAGS -lpthread"
++       LIBS="$LIBS -lpthread"
+   else
+     AC_MSG_RESULT(no : disabling \"--with-threads\" parameter)
+   fi
+-
+-else
+-   if test -s /proc/cpuinfo; then
+-      AC_MSG_CHECKING(for multi-processor)
+-      dnl Multithread advice
+-      if test `grep -c '^processor' /proc/cpuinfo` -gt 2; then
+-         AC_MSG_RESULT(yes) 
+-         AC_MSG_RESULT(- try \"configure --with-threads\")
+-      else
+-         AC_MSG_RESULT(no)
+-      fi;
+-   fi;
+-fi
+-
+-
+-
+-
+-
+-dnl a) : with-thread-fr option
+-AC_ARG_WITH(
+-      thread-fr,
+-      [  --with-thread-fr        compile with two separate threads for Forward and Reverse sequence],
+-      [thread_forward_reverse="yes"],
+-      [thread_forward_reverse="no"])
+-
+-if test "$thread_forward_reverse" = "yes"; then
+-  AC_MSG_RESULT(detected cpu parameter: thread-fr);
+- 
+-  dnl pthread library here ? (UNIX system)
+-  AC_MSG_CHECKING(for pthread lib)
+-  AC_CHECK_LIB(pthread, pthread_create,
+-      [have_pthread="yes"],
+-      [have_pthread="no"])
+-  if test "$have_pthread" = "yes"; then
+-    AC_MSG_RESULT(yes)
+-    AC_DEFINE([HAVE_PTHREAD],[1],[pthread available on the computer])
+-       CFLAGS=" $CFLAGS -DTHREAD_FORWARD_REVERSE "
+-       LDFLAGS="$LDFLAGS -lpthread"  
+-  else
+-    AC_MSG_RESULT(no : disabling \"--with-thread-fr\" parameter)
+-  fi
+-
+-else
+-   if test -s /proc/cpuinfo; then
+-      AC_MSG_CHECKING(for multi-processor)
+-      dnl Multithread advice
+-      if test `grep -c '^processor' /proc/cpuinfo` -gt 1; then
+-         AC_MSG_RESULT(yes) 
+-         AC_MSG_RESULT(- try \"configure --with-thread-fr\")
+-      else
+-         AC_MSG_RESULT(no)
+-      fi;
+-   fi;
+-fi
+-
+-
+-
+-
+-
+-dnl b) : with-thread-aa option
+-AC_ARG_WITH(
+-      thread-aa,
+-      [  --with-thread-aa        compile with two separate threads for Assemble and Align steps],
+-      [thread_assemble_align="yes"],
+-      [thread_assemble_align="no"])
+-
+-if test "$thread_assemble_align" = "yes"; then
+-  AC_MSG_RESULT(detected cpu parameter: thread-aa);
+- 
+-  dnl pthread library here ? (UNIX system)
+-  AC_MSG_CHECKING(for pthread lib)
+-  AC_CHECK_LIB(pthread, pthread_create,
+-      [have_pthread="yes"],
+-      [have_pthread="no"])
+-  if test "$have_pthread" = "yes"; then
+-    AC_MSG_RESULT(yes)
+-    AC_DEFINE([HAVE_PTHREAD],[1],[pthread available on the computer])
+-       CFLAGS=" $CFLAGS -DTHREAD_ASSEMBLE_ALIGN "
+-       LDFLAGS="$LDFLAGS -lpthread"  
+-  else
+-    AC_MSG_RESULT(no : disabling \"--with-thread-aa\" parameter)
+-  fi
+-
+-else
+-   if test -s /proc/cpuinfo; then
+-      AC_MSG_CHECKING(for multi-processor)
+-      dnl Multithread advice
+-      if test `grep -c '^processor' /proc/cpuinfo` -gt 1; then
+-         AC_MSG_RESULT(yes) 
+-         AC_MSG_RESULT(- try \"configure --with-thread-aa\")
+-      else
+-         AC_MSG_RESULT(no)
+-      fi;
+-   fi;
+-fi
+-
+-
+-dnl c) : with-thread-qc option
+-AC_ARG_WITH(
+-      thread-qc,
+-      [  --with-thread-qc        compile with threads for the query chunks],
+-      [thread_query_chunk="yes"],
+-      [thread_query_chunk="no"])
+-
+-if test "$thread_query_chunk" = "yes"; then
+-  AC_MSG_RESULT(detected cpu parameter: thread-qc);
+- 
+-  dnl pthread library here ? (UNIX system)
+-  AC_MSG_CHECKING(for pthread lib)
+-  AC_CHECK_LIB(pthread, pthread_create,
+-      [have_pthread="yes"],
+-      [have_pthread="no"])
+-  if test "$have_pthread" = "yes"; then
+-    AC_MSG_RESULT(yes)
+-    AC_DEFINE([HAVE_PTHREAD],[1],[pthread available on the computer])
+-       CFLAGS=" $CFLAGS -DTHREAD_QUERY_CHUNK "
+-       LDFLAGS="$LDFLAGS -lpthread"  
+-  else
+-    AC_MSG_RESULT(no : disabling \"--with-thread-qc\" parameter)
+-  fi
+-
+-else
+-   if test -s /proc/cpuinfo; then
+-      AC_MSG_CHECKING(for multi-processor)
+-      dnl Multithread advice
+-      if test `grep -c '^processor' /proc/cpuinfo` -gt 1; then
+-         AC_MSG_RESULT(yes) 
+-         AC_MSG_RESULT(- try \"configure --with-thread-qc\")
+-      else
+-         AC_MSG_RESULT(no)
+-      fi;
+-   fi;
+-fi
+-
+-
+-
++])
+ 
+ dnl 2) : low-memory option
+-AC_ARG_WITH(
+-      low-memory,
+-      [  --with-low-memory       use less memory, but can miss some repeats],
+-      [low_memory="yes"],
+-      [low_memory="no"])
++AC_ARG_ENABLE(
++      [lowmemory],
++      AS_HELP_STRING([--enable-lowmemory], [use less memory, but can miss some repeats]))
+ 
+-if test "$low_memory" = "yes"; then
++AS_IF([test "x$enable_lowmemory" = "xyes"], [
+    AC_MSG_RESULT(detected memory parameter: low memory);
+    CFLAGS=" $CFLAGS -DLOW_MEMORY "
+-else
+-   AC_MSG_RESULT(detected memory parameter : plain memory) 
+-fi
+-
+-
+-CFLAGS="$CFLAGS -O3 -Wall -ansi -pedantic -funroll-loops -pipe -fomit-frame-pointer "
+-LDFLAGS="$LDFLAGS -lm"
++])
+ 
+ AC_SUBST(CFLAGS)
+ AC_SUBST(LDFLAGS)
++
+ AM_WITH_DMALLOC
+ AM_INIT_AUTOMAKE
+ AC_CONFIG_FILES([Makefile
+diff --git a/src/Makefile.am b/src/Makefile.am
+index e456f94..ff8400a 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -6,3 +6,5 @@
+ bin_PROGRAMS = yass
+ yass_SOURCES = align.c assemble.c avl.c display.c global_var.c hash.c kword.c list.c main.c prdyn.c proba.c red_black.c regroup.c threads.c tuple.c util.c \
+                align.h assemble.h avl.h display.h global_var.h hash.h kword.h list.h        prdyn.h proba.h red_black.h regroup.h threads.h tuple.h util.h
++yass_LDADD = -lm
++# yass_LDADD = -lm $(LIBS)
index 3302123e5718863b3d43510ff6025ae25c0f3ae1..1207dd1755bc9da6b723928f17176cc07714bf81 100644 (file)
@@ -6,4 +6,8 @@
                <name>Andrey Kislyuk</name>
        </maintainer>
        <herd>sci-biology</herd>
+<use>
+  <flag name='dmalloc'>Enable debugging with the dmalloc library</flag>
+  <flag name='lowmem'>Build for environments with low amounts of memory</flag>
+</use>
 </pkgmetadata>
diff --git a/sci-biology/yass/yass-1.14-r1.ebuild b/sci-biology/yass/yass-1.14-r1.ebuild
new file mode 100644 (file)
index 0000000..b111088
--- /dev/null
@@ -0,0 +1,36 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-biology/yass/yass-1.14-r1.ebuild,v 1.1 2010/06/21 15:31:15 jlec Exp $
+
+EAPI="2"
+
+inherit autotools eutils
+
+DESCRIPTION="Genomic similarity search with multiple transition constrained spaced seeds"
+HOMEPAGE="http://bioinfo.lifl.fr/yass/"
+SRC_URI="http://bioinfo.lifl.fr/yass/files/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="dmalloc lowmem threads"
+KEYWORDS="~amd64 ~x86"
+
+DEPEND="dmalloc? ( dev-libs/dmalloc )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+       epatch "${FILESDIR}"/${PV}-as-needed.patch
+       eautoreconf
+}
+
+src_configure() {
+       econf \
+               $(use_enable threads) \
+               $(use_enable lowmem lowmemory) \
+               $(use_with dmalloc)
+}
+
+src_install() {
+       emake DESTDIR="${D}" install || die
+       dodoc AUTHORS README NEWS
+}