unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#51071: OpenFOAM 4.1 fails to build
@ 2021-10-07  8:57 Ludovic Courtès
  2023-06-15 21:02 ` Ludovic Courtès
  0 siblings, 1 reply; 2+ messages in thread
From: Ludovic Courtès @ 2021-10-07  8:57 UTC (permalink / raw)
  To: 51071

[-- Attachment #1: Type: text/plain, Size: 7987 bytes --]

Hello,

On 1327ec822fa6dd396e979efd8d4e1f7479f1d5b3 (current master),
OpenFOAM 4.1 fails to build (from
<https://ci.guix.gnu.org/build/396746/details>):

--8<---------------cut here---------------start------------->8---
g++ -std=c++0x -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -O3  -DNoRepository -ftemplate-depth-100 -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/finiteVolume/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/dynamicMesh/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/meshTools/lnInclude -IlnInclude -I. -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/OpenFOAM/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/OSspecific/POSIX/lnInclude   -fPIC -c moveMesh.C -o /tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/platforms/linux64GccDPInt32Opt/applications/utilities/mesh/manipulation/moveMesh/moveMesh.o
In file included from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/IO/Color.h:21:0,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/IO/io.h:30,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/Needs_parens_as_product.h:20,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_type_basic.h:45,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/basic.h:33,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/Delaunay_triangulation_3.h:22,
                 from lnInclude/CGALTriangulation3DKernel.H:36,
                 from lnInclude/CGALTriangulation3Ddefs.H:41,
                 from DelaunayMeshTools/DelaunayMeshTools.H:45,
                 from DelaunayMeshTools/DelaunayMeshTools.C:26:
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/array.h:72:44: error: ?std::index_sequence? has not been declared
 make_filled_array_aux(const T& value, std::index_sequence<Is...>)
                                            ^~~~~~~~~~~~~~
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/array.h:72:58: error: expected ?,? or ?...? before ?<? token
 make_filled_array_aux(const T& value, std::index_sequence<Is...>)
                                                          ^
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/array.h: In function ?constexpr std::array<T, N> CGAL::make_filled_array(const T&)?:
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/array.h:80:44: error: ?make_index_sequence? is not a member of ?std?
   return make_filled_array_aux(value, std::make_index_sequence<N>());
                                            ^~~~~~~~~~~~~~~~~~~
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/array.h:80:67: error: expected primary-expression before ?)? token
   return make_filled_array_aux(value, std::make_index_sequence<N>());
                                                                   ^
In file included from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/double.h:22:0,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_type_basic.h:51,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/basic.h:33,
                 from /gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/Delaunay_triangulation_3.h:22,
                 from lnInclude/CGALTriangulation3DKernel.H:36,
                 from lnInclude/CGALTriangulation3Ddefs.H:41,
                 from DelaunayMeshTools/DelaunayMeshTools.H:45,
                 from DelaunayMeshTools/DelaunayMeshTools.C:26:
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h: At global scope:
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected primary-expression before ?auto?
 decltype(auto) approximate_sqrt(const NT& nt)
          ^~~~
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected ?)? before ?auto?
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected primary-expression before ?auto?
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected primary-expression before ?auto?
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected primary-expression before ?auto?
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:10: error: expected primary-expression before ?auto?
/gnu/store/86p0n4k4ahkc0kg7n4qz1mfg02czhyhd-cgal-5.2.2/include/CGAL/number_utils.h:319:1: error: expected unqualified-id before ?decltype?
 decltype(auto) approximate_sqrt(const NT& nt)
 ^~~~~~~~
--8<---------------cut here---------------end--------------->8---

(It hasn’t been touched since 2017, so it might have been failing for a
long time.)

I naively tried building against CGAL 4.x (patch below) but that failed
elsewhere:

--8<---------------cut here---------------start------------->8---
g++ -std=c++0x -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -O3  -DNoRepository -ftemplate-depth-100 -frounding-math -DNDEBUG -I/gnu/store/hwrhh7icnj2rsr208szblzys2j91gqq3-cgal-4.14.2/include -I/gnu/store/5jf395qa3v4amdi60850rz2a15zlsrza-mpfr-4.0.2/include -I/gnu/store/35afkywncrr5xsb4cxcljf6rpjcb7f61-gmp-6.2.0/include -I/gnu/store/vp2s1nxsc9vvc1ix66xpbf041f8nacxr-boost-1.72.0/include -I/usr/include -Wno-old-style-cast -Wno-unused-local-typedefs -Wno-array-bounds -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/applications/utilities/mesh/generation/extrude2DMesh/extrude2DMesh/lnInclude -I../conformalVoronoi2DMesh/lnInclude -I../conformalVoronoiMesh/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/parallel/decompose/decompositionMethods/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/finiteVolume/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/meshTools/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/surfMesh/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/edgeMesh/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/dynamicMesh/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/mesh/extrudeModel/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/sampling/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/triSurface/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/fileFormats/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/mesh/snappyHexMesh/lnInclude -IlnInclude -I. -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/OpenFOAM/lnInclude -I/tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/src/OSspecific/POSIX/lnInclude   -fPIC -c foamyQuadMesh.C -o /tmp/guix-build-openfoam-4.1.drv-0/OpenFOAM-4.1/platforms/linux64GccDPInt32Opt/applications/utilities/mesh/generation/foamyMesh/foamyQuadMesh/foamyQuadMesh.o
In file included from insertSurfaceNearPointPairs.C:26:0:
CV2D.H:352:51: error: ‘point’ does not name a type
             inline const point2D& toPoint2D(const point&) const;
                                                   ^~~~~
CV2D.H:354:20: error: ‘point’ does not name a type
             inline point toPoint3D(const point2D&) const;
                    ^~~~~
--8<---------------cut here---------------end--------------->8---

It would probably be best to upgrade, but that’s an intimidating piece
of software and it takes a lot of CPU time to build.

Thoughts?

Ludo’.


[-- Attachment #2: Type: text/x-patch, Size: 1596 bytes --]

diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm
index 3f2be5766c..7f091c02e3 100644
--- a/gnu/packages/graphics.scm
+++ b/gnu/packages/graphics.scm
@@ -1,5 +1,5 @@
 ;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2015, 2016 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2015, 2016, 2021 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015 Tomáš Čech <sleep_walker@gnu.org>
 ;;; Copyright © 2016, 2019 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016, 2017, 2019 Ricardo Wurmus <rekado@elephly.net>
@@ -796,6 +796,19 @@ (define-public cgal
     ;; permissive licenses.
     (license license:gpl3+)))
 
+(define-public cgal-4
+  (package
+    (inherit cgal)
+    (version "4.14.2")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "https://github.com/CGAL/cgal/releases/download/v" version
+                    "/CGAL-" version ".tar.xz"))
+              (sha256
+               (base32
+                "08lrp3hfwdypggz4138bnkh6bjxn441zg2y9xnq5mrjfc5ini6w1"))))))
+
 (define-public ilmbase
   (package
     (name "ilmbase")
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 23580322bb..f95356d913 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -88,7 +88,7 @@ (define-public openfoam
     (build-system gnu-build-system)
     (inputs
      `(("boost" ,boost)
-       ("cgal" ,cgal)
+       ("cgal" ,cgal-4)
        ("flex" ,flex)
        ("git" ,git)
        ("gmp" ,gmp)

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#51071: OpenFOAM 4.1 fails to build
  2021-10-07  8:57 bug#51071: OpenFOAM 4.1 fails to build Ludovic Courtès
@ 2023-06-15 21:02 ` Ludovic Courtès
  0 siblings, 0 replies; 2+ messages in thread
From: Ludovic Courtès @ 2023-06-15 21:02 UTC (permalink / raw)
  To: 51071-done

Ludovic Courtès <ludovic.courtes@inria.fr> skribis:

> On 1327ec822fa6dd396e979efd8d4e1f7479f1d5b3 (current master),
> OpenFOAM 4.1 fails to build (from
> <https://ci.guix.gnu.org/build/396746/details>):

It builds fine now:

--8<---------------cut here---------------start------------->8---
$ guix weather openfoam
computing 1 package derivations for x86_64-linux...
looking for 2 store items on https://ci.guix.gnu.org...
https://ci.guix.gnu.org ☀
  100.0% substitutes available (2 out of 2)
  at least 57.6 MiB of nars (compressed)
  136.6 MiB on disk (uncompressed)
  0.106 seconds per request (0.2 seconds in total)
  9.4 requests per second

  492 queued builds
      aarch64-linux: 491 (99.8%)
      x86_64-linux: 1 (.2%)
  build rate: 34.16 builds per hour
      i686-linux: 5.81 builds per hour
      powerpc64le-linux: 5.67 builds per hour
      aarch64-linux: 9.43 builds per hour
      x86_64-linux: 13.71 builds per hour
looking for 2 store items on https://bordeaux.guix.gnu.org...
https://bordeaux.guix.gnu.org ☀
  100.0% substitutes available (2 out of 2)
  28.3 MiB of nars (compressed)
  136.6 MiB on disk (uncompressed)
  0.085 seconds per request (0.2 seconds in total)
  11.8 requests per second
  (continuous integration information unavailable)
$ guix build openfoam -n 
29.6 MB would be downloaded:
  /gnu/store/rwh040q7049ayhn79xs33ipz9brzhcwv-openfoam-4.1-debug
  /gnu/store/jp9syfs3gnkfvczr9yrhhmsl07c420jk-openfoam-4.1
$ guix describe
Generation 266  Jun 12 2023 00:09:25    (current)
  guix 299f64a
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: 299f64adea72a4b360da54b0bffd06ee57a5517b
--8<---------------cut here---------------end--------------->8---

Ludo’.




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-06-15 21:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-07  8:57 bug#51071: OpenFOAM 4.1 fails to build Ludovic Courtès
2023-06-15 21:02 ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).