-
-
Notifications
You must be signed in to change notification settings - Fork 717
Description
Summary
We are in the process of updating ITK build scripts in ITKPythonPackage to accommodate targeting ARM architectures. Module builds currently fail on the first CastXML generation step. With that said, I am not 100% certain whether the issue lies in CastXML.
Expected behavior
XML files are generated without error, wrapping succeeds
Observed behavior
[8/17] Completed 'castxml'
[9/17] Generating /work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/itkSplitComponentsImageFilter.xml
FAILED: /work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/itkSplitComponentsImageFilter.xml
cd /work/_skbuild/linux-aarch64-3.8/cmake-build/Wrapping/Modules/SplitComponents && /work/_skbuild/linux-aarch64-3.8/cmake-build/Wrapping/Generators/CastXML/castxml/bin/castxml -o /work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/itkSplitComponentsImageFilter.xml --castxml-gccxml --castxml-start _wrapping_ --castxml-cc-gnu "(" /opt/rh/gcc-toolset-12/root/usr/bin/c++ -std=c++14 ")" -w -c @/work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/.castxml.inc /work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/itkSplitComponentsImageFilter.cxx
In file included from /work/ITK-cp38-cp38-manylinux_2_28_aarch64/Wrapping/castxml_inputs/itkSplitComponentsImageFilter.cxx:1:
In file included from /work/ITK-source/ITK/Modules/Core/Common/include/itkCommand.h:21:
In file included from /work/ITK-source/ITK/Modules/Core/Common/include/itkObject.h:31:
In file included from /work/ITK-source/ITK/Modules/Core/Common/include/itkLightObject.h:21:
In file included from /work/ITK-source/ITK/Modules/Core/Common/include/itkMacro.h:47:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/string:41:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/allocator.h:46:
In file included from /opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/aarch64-redhat-linux/bits/c++allocator.h:33:
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/new_allocator.h:158:2: error: call to '__builtin_operator_delete' selects non-usual deallocation function
_GLIBCXX_OPERATOR_DELETE(_GLIBCXX_SIZED_DEALLOC(__p, __n));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/new_allocator.h:103:35: note: expanded from macro '_GLIBCXX_OPERATOR_DELETE'
# define _GLIBCXX_OPERATOR_DELETE __builtin_operator_delete
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/alloc_traits.h:496:13: note: in instantiation of member function 'std::__new_allocator<char>::deallocate' requested here
{ __a.deallocate(__p, __n); }
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/basic_string.h:292:24: note: in instantiation of member function 'std::allocator_traits<std::allocator<char>>::deallocate' requested here
{ _Alloc_traits::deallocate(_M_get_allocator(), _M_data(), __size + 1); }
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/basic_string.h:286:4: note: in instantiation of member function 'std::basic_string<char>::_M_destroy' requested here
_M_destroy(_M_allocated_capacity);
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/basic_string.h:794:9: note: in instantiation of member function 'std::basic_string<char>::_M_dispose' requested here
{ _M_dispose(); }
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/bits/basic_string.h:4019:12: note: in instantiation of member function 'std::basic_string<char>::~basic_string' requested here
string __str(__neg + __len, '-');
^
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/aarch64-redhat-linux/12/../../../../include/c++/12/new:135:6: note: non-usual 'operator delete' declared here
void operator delete(void*, std::size_t) _GLIBCXX_USE_NOEXCEPT
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Build output available at https://github.com/tbirdso/ITKSplitComponents/actions/runs/3604194121/jobs/6073281299
Platform Information
manylinux_2_28_aarch64 image running on an Ubuntu 20.04 Github Actions runner with aarch64 emulation.
Manylinux image: https://quay.io/repository/pypa/manylinux_2_24_aarch64?tab=info , tag=2022-11-28-5d13db4
Emulation tools: https://hub.docker.com/r/tonistiigi/binfmt
Able to reproduce on local Ubuntu 20.04 instance with aarch64 emulation + manylinux_2_28_aarch64 image.
Not yet attempted on native ARM machine.
Versions
CastXML 0.4.8
-- Using src='https://github.com/CastXML/CastXMLSuperbuild/releases/download/v0.4.8/castxml-linux-aarch64.tar.gz'
SWIG 4.0.2
ITK v5.3.0
Other Notes
- ITKPythonPackage ARM build scripts under test are here: COMP: Consolidate Linux ARM build script ITKPythonPackage#236
- ITKSplitComponents is a small header-only ITK module often used for testing build script development
- I was able to successfully build and run ITKSplitComponents tests in a local emulated ARM container with
ITK_WRAP_PYTHON:BOOL=OFFandBUILD_TESTING:BOOL=ON.
xpost from CastXML/CastXML#228