[118589] trunk/dports/science/lal

ram at macports.org ram at macports.org
Sat Apr 5 03:16:58 PDT 2014


Revision: 118589
          https://trac.macports.org/changeset/118589
Author:   ram at macports.org
Date:     2014-04-05 03:16:58 -0700 (Sat, 05 Apr 2014)
Log Message:
-----------
science/lal: support SWIG-3.0.0 #43186

Modified Paths:
--------------
    trunk/dports/science/lal/Portfile

Added Paths:
-----------
    trunk/dports/science/lal/files/0001-SWIG-make-wrappings-compatible-with-SWIG-v3.0.0.patch

Modified: trunk/dports/science/lal/Portfile
===================================================================
--- trunk/dports/science/lal/Portfile	2014-04-05 10:11:18 UTC (rev 118588)
+++ trunk/dports/science/lal/Portfile	2014-04-05 10:16:58 UTC (rev 118589)
@@ -5,7 +5,7 @@
 
 name          lal
 version       6.12.0
-revision      2
+revision      3
 categories    science
 platforms     darwin
 maintainers   ram
@@ -22,6 +22,9 @@
 checksums     rmd160 426102023e57cfb4c4d35369711db728b0ec1e5c \
               sha256 d7f345cb4a903e6bded4b008b25fee41a9bff3328b98cf0a6157215ec43eeff1
 
+patchfiles    0001-SWIG-make-wrappings-compatible-with-SWIG-v3.0.0.patch
+patch.pre_args -p2
+
 depends_build-append port:pkgconfig
 
 depends_lib   port:python27 \

Added: trunk/dports/science/lal/files/0001-SWIG-make-wrappings-compatible-with-SWIG-v3.0.0.patch
===================================================================
--- trunk/dports/science/lal/files/0001-SWIG-make-wrappings-compatible-with-SWIG-v3.0.0.patch	                        (rev 0)
+++ trunk/dports/science/lal/files/0001-SWIG-make-wrappings-compatible-with-SWIG-v3.0.0.patch	2014-04-05 10:16:58 UTC (rev 118589)
@@ -0,0 +1,99 @@
+From 20d0cb2d0c60c0feeb5f6ff5518b9d3b41574e2b Mon Sep 17 00:00:00 2001
+From: Karl Wette <karl.wette at ligo.org>
+Date: Sun, 30 Mar 2014 00:20:56 +0100
+Subject: [PATCH] SWIG: make wrappings compatible with SWIG v3.0.0
+
+- %typemaps_string_alloc() has an extra argument
+- structs containing pointer-to-const members now
+  need SWIGLAL(IMMUTABLE_MEMBERS(...))
+
+(cherry picked from commit 4558d05958962d8240e19651c72dc1699fa63807)
+---
+ lal/packages/date/include/Date.h                   | 3 +++
+ lal/packages/std/include/swiglal_common.i          | 7 +++++++
+ lal/packages/tools/include/DetResponse.h           | 3 +++
+ lal/packages/tools/include/EllipsoidOverlapTools.h | 3 +++
+ lal/packages/tools/include/Units.h                 | 3 +++
+ 5 files changed, 19 insertions(+)
+
+diff --git a/lal/packages/date/include/Date.h b/lal/packages/date/include/Date.h
+index 1edf9ec..e450136 100644
+--- a/lal/packages/date/include/Date.h
++++ b/lal/packages/date/include/Date.h
+@@ -94,6 +94,9 @@ extern "C"
+  * ::LIGOTimeGPS. Its sole purpose is to aggregate these
+  * structures for passing to functions.
+  */
++#ifdef SWIG /* SWIG interface directives */
++SWIGLAL(IMMUTABLE_MEMBERS(tagLALPlaceAndGPS, p_detector));
++#endif /* SWIG */
+ typedef struct
+ tagLALPlaceAndGPS
+ {
+diff --git a/lal/packages/std/include/swiglal_common.i b/lal/packages/std/include/swiglal_common.i
+index 03aa466..fb405b6 100644
+--- a/lal/packages/std/include/swiglal_common.i
++++ b/lal/packages/std/include/swiglal_common.i
+@@ -1020,10 +1020,17 @@ if (swiglal_release_parent(PTR)) {
+     return SWIG_AsLALcharPtrAndSize(obj, pstr, 0, &alloc);
+   }
+ }
++#if SWIG_VERSION >= 0x030000
++%typemaps_string_alloc(%checkcode(STRING), %checkcode(char), char, LALchar,
++                       SWIG_AsLALcharPtrAndSize, SWIG_FromLALcharPtrAndSize,
++                       strlen, SWIG_strnlen, %swiglal_new_copy_array, XLALFree,
++                       "<limits.h>", CHAR_MIN, CHAR_MAX);
++#else
+ %typemaps_string_alloc(%checkcode(STRING), %checkcode(char), char, LALchar,
+                        SWIG_AsLALcharPtrAndSize, SWIG_FromLALcharPtrAndSize,
+                        strlen, %swiglal_new_copy_array, XLALFree,
+                        "<limits.h>", CHAR_MIN, CHAR_MAX);
++#endif
+ 
+ // Typemaps for string pointers.  By default, treat arguments of type char**
+ // as output-only arguments, which do not require a scripting-language input
+diff --git a/lal/packages/tools/include/DetResponse.h b/lal/packages/tools/include/DetResponse.h
+index ccd9510..926261f 100644
+--- a/lal/packages/tools/include/DetResponse.h
++++ b/lal/packages/tools/include/DetResponse.h
+@@ -119,6 +119,9 @@ LALSource;
+  * LALComputeDetAMResponse() and
+  * LALComputeDetAMResponseSeries().
+  */
++#ifdef SWIG /* SWIG interface directives */
++SWIGLAL(IMMUTABLE_MEMBERS(tagLALDetAndSource, pDetector));
++#endif /* SWIG */
+ typedef struct
+ tagLALDetAndSource
+ {
+diff --git a/lal/packages/tools/include/EllipsoidOverlapTools.h b/lal/packages/tools/include/EllipsoidOverlapTools.h
+index fc6a4e3..c0bf9ac 100644
+--- a/lal/packages/tools/include/EllipsoidOverlapTools.h
++++ b/lal/packages/tools/include/EllipsoidOverlapTools.h
+@@ -52,6 +52,9 @@ Author: Robinson, C. A. and Sengupta, A. S.
+ extern "C" {
+ #endif
+ 
++#ifdef SWIG /* SWIG interface directives */
++SWIGLAL(IMMUTABLE_MEMBERS(tagfContactWorkSpace, invQ1, invQ2));
++#endif /* SWIG */
+ typedef struct tagfContactWorkSpace
+ {
+     /* Dimension of the matrices & vectors */
+diff --git a/lal/packages/tools/include/Units.h b/lal/packages/tools/include/Units.h
+index c8e7e1c..15f53dd 100644
+--- a/lal/packages/tools/include/Units.h
++++ b/lal/packages/tools/include/Units.h
+@@ -164,6 +164,9 @@ tagRAT4
+  * Consists of a pair of unit structures; used as an input structure for
+  * the LALUnitCompare() and LALUnitMultiply() functions.
+  */
++#ifdef SWIG /* SWIG interface directives */
++SWIGLAL(IMMUTABLE_MEMBERS(tagLALUnitPair, unitOne, unitTwo));
++#endif /* SWIG */
+ typedef struct
+ tagLALUnitPair
+ {
+-- 
+1.9.1
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140405/efa763b1/attachment.html>


More information about the macports-changes mailing list