Package Details: openfoam-org 14.20261008+a4867fc-2

Git Clone URL: https://aur.archlinux.org/openfoam.git (read-only, click to copy)
Package Base: openfoam
Description: The open source CFD toolbox (www.openfoam.org)
Upstream URL: https://www.openfoam.org
Licenses: GPL-3.0-or-later
Provides: openfoam
Submitter: None
Maintainer: faruq
Last Packager: faruq
Votes: 67
Popularity: 1.33
First Submitted: 2009-07-02 09:16 (UTC)
Last Updated: 2026-11-02 19:32 (UTC)

Required by (1)

Sources (2)

Latest Comments

1 2 3 4 5 6 .. 33 Next › Last »

faruq commented on 2026-11-03 10:36 (UTC)

@gpettinello Glad you resolved the build issue!

Also, good news: upstream and Arch maintainers are already addressing this header conflict. They plan to enforce stricter isolation on scotch-metis's paths/symbols in future updates, so having both packages co-exist will no longer break the build.

gpettinello commented on 2026-11-03 09:53 (UTC)

@faruq I found the reason. I installed package scotch-metis which installs also /usr/include/scotch/parmetis.h which I think conflicts with /usr/include/parmetis.h during compiling. By removing scotch-metis the compiling went fine.

Now I can compile everything :thumbsup

faruq commented on 2026-11-02 21:56 (UTC)

@gpettinello I rebuilt Zoltan and checked the logs, but it seems we are encountering different issues. Since the current PKGBUILD for parmetis actually fails to build, fixing parmetis (https://aur.archlinux.org/packages/parmetis#comment-1088861) makes Zoltan build completely fine. The logs do show some warnings, but those are just PKGBUILD quality issues in the zoltan package itself and don't actually break the build. You can try building again using the fixed parmetis PKGBUILD I posted in the link.

gpettinello commented on 2026-11-02 20:18 (UTC)

@faruq

Thanks so much. I see you are working also on zoltan which gives me the error because for some reason third_library_const.h assumes parmetis version 3 (I think) and not version 4. So it chooses the wrong type data I was able to compile zoltan by forcing the data type but it is not elegant :(

faruq commented on 2026-11-02 19:17 (UTC)

@gpettinello Yes, you're right about the VTK headers.

wmkdep only understands -I, but CMake passes the VTK paths as -isystem /usr/include/vtk, so it can't see them and warns on every header. Build still works, just noisy and the .dep files miss those headers.

Easy fix in PVReaders/Allwmake (turn -isystem into -I); I'll include it in the next pkgrel. Thanks !

faruq commented on 2026-11-02 18:39 (UTC)

Hi @gpettinello Thank you for pointing out this error. Since parmetis was broken, I tested it with parmetis-git and forgot to change it back (which also broke the build of zoltan). I submitted an orphan request for parmetis a few days ago, and if all goes well, it will be fixed shortly after I take over the package. As for the VTK warning you mentioned, I will look into the cause.

gpettinello commented on 2026-11-02 18:22 (UTC) (edited on 2026-11-02 20:14 (UTC) by gpettinello)

Hi faruq,

I see you updated the PKGBUILD (thanks!!!) Would it be possible to switch dependency from parmetis-git to parmetis? It would accept both as parmetis-git provides parmetis. I compiled openfoam-org with parmetis. Also I see warnings when wkmdep is processing vtkPVblockMesh.C and vtkPVFoam. I think it is because openfoam is not seeing the correct path of vtk headers. What do you think? Gianluca

gpettinello commented on 2026-08-02 16:29 (UTC) (edited on 2026-08-02 16:31 (UTC) by gpettinello)

Hi, I have updated the PKGBUILD to version 14. Below the code


# Maintainer: envolution
# Contributor: Gianluca Pettinello <g_pet@hotmail.com>
# Contributor: Jingbei Li <i@jingbei.li>
# Contributor: Xwang <xwaang1976@gmail.com>
# Contributor: George Eleftheriou <eleftg>
# Contributor: Andrew Fischer <andrew_at_apastron.co>
# shellcheck shell=bash disable=SC2034,SC2154

pkgbase=openfoam
pkgname=openfoam-org
pkgver=14.20260724+7b05503
_pkgver="${pkgver%%.*}"
_subver_and_commit="${pkgver#*.}"
_subver="${_subver_and_commit%+*}"
_commit="${pkgver#*+}"
pkgrel=1
pkgdesc="The open source CFD toolbox (www.openfoam.org)"
_distpkgbase=OpenFOAM
_gitname=$_distpkgbase-$_pkgver
options=(!strip)
arch=('x86_64')
url="http://www.openfoam.org"
license=("GPL-3.0-or-later")
depends=(
  glibc
  qt6-base
  gcc-libs
  metis
  vtk
  bzip2
  paraview
  parmetis
  scotch
  boost
  cgal
  zoltan
  openmpi
  gnuplot
  libxt
  libxml2
  freetype2
  double-conversion
  glew
  utf8cpp
  gl2ps
  python
  hdf5
  zlib
)
makedepends=(
  git
  cmake
  cli11 
  nlohmann-json 
  fast_float 
  flex
)
provides=(openfoam)
source=(
  "$_gitname-$_subver::git+https://github.com/OpenFOAM/OpenFOAM-${_pkgver}.git#commit=${_commit}"
  paraview.arch
  openfoam.install
)
install="${pkgbase}.install"
sha256sums=('SKIP'
            'bbec057b1153a616ea388dc80fdaeb6337edc6150e0601f140a1304f82a10ddb'
            'a94080d4e5bc4736868269d66f61f5430dec961c70bdcdaa1c9a402dba5203d2')

_cache_notify() {
  local yellow='\033[1;33m'
  local red='\033[1;31m'
  local nc='\033[0m'
  echo -e "${yellow}==> Using build cache:${nc}"
  echo "    ${srcdir}/${_distpkgbase}-${_pkgver}"
  echo
  echo -e "${yellow}==> To build from scratch, run:${nc}"
  echo -e "    ${red}rm -rf ${srcdir}/${_distpkgbase}-${_pkgver}${nc}"
}

prepare() {
  _cachefile=${_distpkgbase}-${_pkgver}/.arch_cache
  if [[ -f "$_cachefile" ]] && grep -q "$pkgver" "$_cachefile"; then
    _cache_notify
  else
    rm -rf $_distpkgbase-$_pkgver
    mv $_gitname-$_subver $_distpkgbase-$_pkgver

    _bashrc=${_distpkgbase}-${_pkgver}/etc/bashrc
    sed -i "s|^export WM_PROJECT_VERSION=.*|export WM_PROJECT_VERSION=${_pkgver}|" "$_bashrc"
    cp ${_bashrc} ${_bashrc}.prepared

    # we'll be using $bashrc while building, and replace it with $bashrc.prepared
    # (below) during install - so we have to modify the FOAM_INST_DIR for post-install use
    sed -i 's|^# export FOAM_INST_DIR=.*|export FOAM_INST_DIR=/opt/\$WM_PROJECT|' \
      ${_bashrc}.prepared

    # Add system library settings to prefs.sh
    cat <<EOF >"${_distpkgbase}-${_pkgver}/etc/prefs.sh"
# System-wide settings for Arch Linux
export SCOTCH_TYPE=system
export METIS_TYPE=system
export PARMETIS_TYPE=system
export ZOLTAN_TYPE=system
EOF

    echo $pkgver >$_cachefile
  fi

  # Drop in Arch paraview environment script
  cd ${_distpkgbase}-${_pkgver}
  cp ${srcdir}/paraview.arch etc/config.sh/paraview
}

build() {
  cd ${_distpkgbase}-${_pkgver}
  # export FOAM_VERBOSE=1
  # export PS1='~' # required for verbosity checks
  # Setup the build environment
  source etc/bashrc || true

  # see if we have extra threads available in /etc/makepkg.conf MAKEFLAGS
  [[ $MAKEFLAGS =~ -j[[:space:]]*([0-9]+) ]] &&
    _jval="${BASH_REMATCH[1]}" || _jval=1

  export PATH="$PWD/wmake:$PATH" 
  wmakeLnIncludeAll
  ./Allwmake -s -q -j ${_jval:=1}
}

package() {
  # Create destination directories
  install -d "${pkgdir}/opt/${_distpkgbase}" "${pkgdir}/etc/profile.d"

  # Copy package to pkgdir
  cp -r "${_distpkgbase}-${_pkgver}" "${pkgdir}/opt/${_distpkgbase}"

  # Clean up build files
  # https://openfoamwiki.net/index.php/Installation/Delete_intermediate_files#OpenFOAM_v1706_and_newer
  _baseclean="${pkgdir}/opt/${_distpkgbase}/${_distpkgbase}-${_pkgver}"
  rm -rf ${_baseclean}/platforms/*/applications ${_baseclean}/platforms/*/src

  # Add bash profile
  _bash_profile=${pkgdir}/etc/profile.d/openfoam-${_pkgver}.sh
  echo "export FOAM_INST_DIR=/opt/${_distpkgbase}" >$_bash_profile
  echo "alias ofoam=\"source \${FOAM_INST_DIR}/${_distpkgbase}-${_pkgver}/etc/bashrc\"" \
    >>$_bash_profile
  echo "alias ofoam${_pkgver}=\"source \${FOAM_INST_DIR}/${_distpkgbase}-${_pkgver}/etc/bashrc\"" \
    >>$_bash_profile
  chmod 755 $_bash_profile

  # Add stub thirdparty directory to keep openfoam happy
  install -d "${pkgdir}/opt/${_distpkgbase}/ThirdParty-${_pkgver}"

  install -Dm755 "${_distpkgbase}-${_pkgver}/etc/bashrc.prepared" \
    "${pkgdir}/opt/${_distpkgbase}/${_distpkgbase}-${_pkgver}/etc/bashrc"
  install -Dm644 ${_distpkgbase}-${_pkgver}/COPYING -t $pkgdir/usr/share/licenses/$pkgname
}

# vim:set ts=2 sw=2 et:

I kindly ask the maintainer to check the code and update if he thinks it is ok. I compiled in my system and it worked

pspssp commented on 2026-03-11 20:03 (UTC) (edited on 2026-03-11 20:07 (UTC) by pspssp)

Hi @carlosal1015 , opening like the wiki suggests (with 'paraFoam -builtin') works but paraView doesn't load a lagrangian mesh (for example, like the one needed for the cyclone tutorial for incompressibleDenseParticleFluid). Not sure it's a problem with the install though, just checked an Ubuntu machine with OF13 (same as here) but paraview 5 and everything works. Thanks for the reply :)

edit: tried foamToVTK and it also doesn't work

carlosal1015 commented on 2026-03-11 16:37 (UTC)

Hi @pspssp, which paraview plugin is missing? Did you tried https://wiki.archlinux.org/title/OpenFOAM#Paraview_not_installed