pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/math/eigen2 posix_memalign() only in recent NetBSD's s...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/3ba3c0b8bae4
branches:  trunk
changeset: 552874:3ba3c0b8bae4
user:      markd <markd%pkgsrc.org@localhost>
date:      Sun Jan 11 11:45:11 2009 +0000

description:
posix_memalign() only in recent NetBSD's so use malloc() instead.

diffstat:

 math/eigen2/Makefile         |   4 ++--
 math/eigen2/distinfo         |   4 ++--
 math/eigen2/patches/patch-aa |  36 ++++++++++++++++++------------------
 3 files changed, 22 insertions(+), 22 deletions(-)

diffs (70 lines):

diff -r ae88ad71fd4f -r 3ba3c0b8bae4 math/eigen2/Makefile
--- a/math/eigen2/Makefile      Sun Jan 11 10:11:48 2009 +0000
+++ b/math/eigen2/Makefile      Sun Jan 11 11:45:11 2009 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.2 2009/01/11 10:11:48 markd Exp $
+# $NetBSD: Makefile,v 1.3 2009/01/11 11:45:11 markd Exp $
 
 DISTNAME=      eigen-2.0-beta5
 PKGNAME=       ${DISTNAME:S/-beta/beta/}
-PKGREVISION=   1
+PKGREVISION=   2
 CATEGORIES=    math
 MASTER_SITES=   http://download.tuxfamily.org/eigen/
 EXTRACT_SUFX=  .tar.bz2
diff -r ae88ad71fd4f -r 3ba3c0b8bae4 math/eigen2/distinfo
--- a/math/eigen2/distinfo      Sun Jan 11 10:11:48 2009 +0000
+++ b/math/eigen2/distinfo      Sun Jan 11 11:45:11 2009 +0000
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.2 2009/01/11 10:11:48 markd Exp $
+$NetBSD: distinfo,v 1.3 2009/01/11 11:45:11 markd Exp $
 
 SHA1 (eigen-2.0-beta5.tar.bz2) = 045155ddd498f43168d197547fdc86755497a7a8
 RMD160 (eigen-2.0-beta5.tar.bz2) = 8cf6b34f2499d7016f62419a8eae555988ec234b
 Size (eigen-2.0-beta5.tar.bz2) = 320560 bytes
-SHA1 (patch-aa) = f43e78d120fcc2810fd934da05d91ddd2e3eb20b
+SHA1 (patch-aa) = 702b670eefa101b1f48dee11bd14c17a3689a157
diff -r ae88ad71fd4f -r 3ba3c0b8bae4 math/eigen2/patches/patch-aa
--- a/math/eigen2/patches/patch-aa      Sun Jan 11 10:11:48 2009 +0000
+++ b/math/eigen2/patches/patch-aa      Sun Jan 11 11:45:11 2009 +0000
@@ -1,22 +1,22 @@
-$NetBSD: patch-aa,v 1.1 2009/01/11 10:11:48 markd Exp $
+$NetBSD: patch-aa,v 1.2 2009/01/11 11:45:12 markd Exp $
 
---- ./Eigen/src/Core/util/Memory.h.orig        2009-01-06 07:21:44.000000000 +1300
-+++ ./Eigen/src/Core/util/Memory.h
-@@ -48,7 +48,7 @@ inline T* ei_aligned_malloc(size_t size)
-   if(ei_packet_traits<T>::size>1 || ei_force_aligned_malloc<T>::ret)
-   {
-     void *void_result;
--    #ifdef __linux
-+    #if defined(__linux) || defined(__NetBSD__)
-       #ifdef EIGEN_EXCEPTIONS
-         const int failed =
-       #endif
-@@ -95,7 +95,7 @@ inline void ei_aligned_free(T* ptr, size
-       // need to call manually the dtor in case T is some user-defined fancy numeric type.
-       // always destruct an array starting from the end.
+--- Eigen/src/Core/util/Memory.h.orig  2009-01-06 07:21:44.000000000 +1300
++++ Eigen/src/Core/util/Memory.h
+@@ -56,7 +56,7 @@ inline T* ei_aligned_malloc(size_t size)
+     #else
+       #ifdef _MSC_VER
+         void_result = _aligned_malloc(size*sizeof(T), 16);
+-      #elif defined(__APPLE__)
++      #elif defined(__APPLE__) || defined(__NetBSD__)
+         void_result = malloc(size*sizeof(T)); // Apple's malloc() already returns aligned ptrs
+       #else
+         void_result = _mm_malloc(size*sizeof(T), 16);
+@@ -97,7 +97,7 @@ inline void ei_aligned_free(T* ptr, size
        while(size) ptr[--size].~T();
--      #if defined(__linux)
-+      #if defined(__linux) || defined(__NetBSD__)
+       #if defined(__linux)
          free(ptr);
-       #elif defined(__APPLE__)
+-      #elif defined(__APPLE__)
++      #elif defined(__APPLE__) || defined(__NetBSD__)
          free(ptr);
+       #elif defined(_MSC_VER)
+         _aligned_free(ptr);



Home | Main Index | Thread Index | Old Index