Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 11 additions & 3 deletions pkgs/by-name/ot/otb/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -234,9 +234,17 @@ stdenv.mkDerivation (finalAttrs: {
./1-otb-swig-include-itk.diff
];

postPatch = (
"substituteInPlace Modules/Core/Wrappers/SWIG/src/python/CMakeLists.txt --replace-fail '''$''{ITK_INCLUDE_DIRS}' ${otb-itk}/include/ITK-${itkMajorMinorVersion}"
);
postPatch =
''
substituteInPlace Modules/Core/Wrappers/SWIG/src/python/CMakeLists.txt \
--replace-fail ''\'''${ITK_INCLUDE_DIRS}' "${otb-itk}/include/ITK-${itkMajorMinorVersion}"
''
# Add the header file "vcl_legacy_aliases.h", which defines the legacy vcl_* functions.
# This patch fixes the unreproducible build of OTB.
# See https://gitlab.orfeo-toolbox.org/orfeotoolbox/otb/-/issues/2484.
+ ''
sed -i '/#include "vcl_compiler.h"/a #include "vcl_legacy_aliases.h"' Modules/Core/Mosaic/include/otbMosaicFunctors.h
'';

nativeBuildInputs = [
cmake
Expand Down