[149257] trunk/dports/science/apbs
dstrubbe at macports.org
dstrubbe at macports.org
Tue Jun 7 14:55:22 PDT 2016
Revision: 149257
https://trac.macports.org/changeset/149257
Author: dstrubbe at macports.org
Date: 2016-06-07 14:55:22 -0700 (Tue, 07 Jun 2016)
Log Message:
-----------
apbs: Add patch that may fix intermittent build failure related to eigen header. Use patch rather than reinplace where possible. Clarify error message. Remove unnecessary debug flag -g.
Modified Paths:
--------------
trunk/dports/science/apbs/Portfile
Added Paths:
-----------
trunk/dports/science/apbs/files/
trunk/dports/science/apbs/files/patch-Eigen-include-path.diff
trunk/dports/science/apbs/files/patch-apbs-CMakeLists.txt.diff
Modified: trunk/dports/science/apbs/Portfile
===================================================================
--- trunk/dports/science/apbs/Portfile 2016-06-07 21:55:02 UTC (rev 149256)
+++ trunk/dports/science/apbs/Portfile 2016-06-07 21:55:22 UTC (rev 149257)
@@ -38,12 +38,13 @@
use_parallel_build no
# do +debug and +universal work?
-# do we really want -g?
configure.args-append -DENABLE_OPENMP:BOOL=OFF \
-DENABLE_BEM=OFF \
- -DCMAKE_C_COMPILER_ARG1:STRING="-I${worksrcpath}/include -O3 -ffast-math -g" \
- -DCMAKE_CXX_COMPILER_ARG1:STRING="-I${worksrcpath}/include -O3 -ffast-math -g"
+ -DCMAKE_C_COMPILER_ARG1:STRING="-I${worksrcpath}/include -O3 -ffast-math" \
+ -DCMAKE_CXX_COMPILER_ARG1:STRING="-I${worksrcpath}/include -O3 -ffast-math"
+patchfiles patch-apbs-CMakeLists.txt.diff patch-Eigen-include-path.diff
+
test.run yes
test {
ln ${worksrcpath}/tools/manip/inputgen.py ${worksrcpath}/tests/
@@ -103,8 +104,6 @@
-DCMAKE_CXX_COMPILER=${configure.cxx} \
-DMPI_C_COMPILER=${mpi.cc} \
-DMPI_CXX_COMPILER=${mpi.cxx}
- # sometimes there will be a failure to link without this
- reinplace -W ${worksrcpath} "s/-lmaloc/-lmaloc -lreadline/" CMakeLists.txt
}
destroot {
@@ -128,7 +127,7 @@
configure.args-append -DENABLE_BEM=ON
if {![fortran_variant_isset]} {
- ui_error "+bem requires a Fortran variant, e.g. +gfortran, +gccX, or +g95."
+ ui_error "+bem requires a Fortran variant, e.g. +gccX or +g95."
return -code error "+bem requires a Fortran variant."
}
@@ -136,13 +135,10 @@
#CMake Error at CMakeLists.txt:217 (get_filename_component):
# get_filename_component called with incorrect number of arguments
post-patch {
- reinplace "s|get_filename_component(LIBGFORTRANPATH|#get_filename_component(LIBGFORTRANPATH|g" ${worksrcpath}/CMakeLists.txt
- reinplace "s|find_path(LIBGFORTRAN_PATH|#find_path(LIBGFORTRAN_PATH|g" ${worksrcpath}/CMakeLists.txt
# -lstdc++ does not seem necessary and may cause trouble; specifying full paths avoid possible use of -ltabip from an earlier installation in ${prefix}
reinplace "s|-L\${LIBGFORTRAN_PATH} -lgfortran -ltabipb -lstdc\+\+|${compilers.libfortran} ${worksrcpath}/lib/libtabipb.a|" ${worksrcpath}/CMakeLists.txt
# provide this information to subsidiary cmake command run in tabipb directory during build phase
reinplace "s|CMAKE_ARGS|CMAKE_ARGS -DCMAKE_Fortran_COMPILER:STRING=${configure.fc}|" ${worksrcpath}/CMakeLists.txt
- system -W ${worksrcpath} "echo 'include_directories(\${APBS_ROOT}/include)' >> CMakeLists.txt"
}
}
Added: trunk/dports/science/apbs/files/patch-Eigen-include-path.diff
===================================================================
--- trunk/dports/science/apbs/files/patch-Eigen-include-path.diff (rev 0)
+++ trunk/dports/science/apbs/files/patch-Eigen-include-path.diff 2016-06-07 21:55:22 UTC (rev 149257)
@@ -0,0 +1,22 @@
+--- src/geoflow/Mat.h.orig 2015-11-10 18:03:45.000000000 -0500
++++ src/geoflow/Mat.h 2015-11-10 18:04:15.000000000 -0500
+@@ -57,7 +57,7 @@
+ #include <cmath>
+ #include <vector>
+
+-#include <Eigen/Core>
++#include "Eigen/Core"
+
+ // The following is from modules.h, which includes this file, Mat.h. We need
+ // the declaration here because we use it below in the deriv method. If we
+--- src/geoflow/pbsolvercz.cpp.orig 2015-11-10 18:03:52.000000000 -0500
++++ src/geoflow/pbsolvercz.cpp 2015-11-10 18:04:31.000000000 -0500
+@@ -56,7 +56,7 @@
+ #include <valarray>
+ #include <vector>
+
+-#include <Eigen/Sparse>
++#include "Eigen/Sparse"
+
+ #include "Mat.h"
+ #include "modules.h"
Added: trunk/dports/science/apbs/files/patch-apbs-CMakeLists.txt.diff
===================================================================
--- trunk/dports/science/apbs/files/patch-apbs-CMakeLists.txt.diff (rev 0)
+++ trunk/dports/science/apbs/files/patch-apbs-CMakeLists.txt.diff 2016-06-07 21:55:22 UTC (rev 149257)
@@ -0,0 +1,27 @@
+--- CMakeLists.txt.orig 2016-06-07 15:34:23.000000000 -0400
++++ CMakeLists.txt 2016-06-07 15:31:19.000000000 -0400
+@@ -214,8 +214,8 @@
+ if(HAVE_GFORTRAN GREATER 0)
+ message(FATAL_ERROR gfortran is currently required for using BEM/TABIPB in APBS)
+ endif()
+- get_filename_component(LIBGFORTRANPATH ${LIBGFORTRANPATH} PATH)
+- find_path(LIBGFORTRAN_PATH ${LIBGFORTRAN_NAME} PATH ${LIBGFORTRANPATH})
++ #get_filename_component(LIBGFORTRANPATH ${LIBGFORTRANPATH} PATH)
++ #find_path(LIBGFORTRAN_PATH ${LIBGFORTRAN_NAME} PATH ${LIBGFORTRANPATH})
+ list(APPEND APBS_LIBS "-L${APBS_ROOT}/${LIBRARY_INSTALL_PATH} -L${LIBGFORTRAN_PATH} -lgfortran -ltabipb -lstdc++" )
+ endif() # ENABLE_BEM
+
+@@ -277,7 +277,7 @@
+ )
+ set(MALOC_LIBRARY ${LIBRARY_OUTPUT_PATH}/${MALOC_LIBRARY_BASENAME})
+ endif()
+-list(APPEND APBS_LIBS -lmaloc)
++list(APPEND APBS_LIBS -lmaloc -lreadline)
+
+
+ ##############################################################################
+@@ -676,3 +676,4 @@
+ DESTINATION ${EXECUTABLE_INSTALL_PATH})
+ endif()
+ endif()
++include_directories(${APBS_ROOT}/include)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20160607/0cf01727/attachment-0001.html>
More information about the macports-changes
mailing list