issue compiling on macOS big sur (11.3) [repost]
jaccl17 opened this issue · 2 comments
I understand that mvme may not be optimized for macOS but I was wondering if it would be possible to fix this issue. It could possibly be an issue on my end, I've never compiled a program like this from scratch. Following the instructions on your README, I run
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=~/local/mvme.../mvme
in the directory that contains the mvme build files and then
make -j6
which works up until
[ 26%] Built target jcon
[ 27%] Building CXX object external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_factory.cc.o
[ 28%] Built target liba2_static
[ 28%] Building CXX object external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_impl_eth.cc.o
[ 28%] Building CXX object external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_impl_support.cc.o
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.cc:1:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.h:240:26: error: implicit instantiation of undefined template 'std::__1::array<unsigned int, 7>'
for (u32 triggerVal: triggerValues)
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/__tuple:219:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
^
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.cc:1:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.h:261:48: error: implicit instantiation of undefined template 'std::__1::array<unsigned int, 7>'
std::array<u32, stacks::ReadoutStackCount> triggerValues;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/__tuple:219:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
^
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.cc:1:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.h:263:20: error: no matching function for call to 'begin'
std::transform(std::begin(triggers), std::end(triggers), std::begin(triggerValues),
^~~~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/initializer_list:99:1: note: candidate template ignored: could not match 'initializer_list' against 'array'
begin(initializer_list<_Ep> __il) _NOEXCEPT
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1772:1: note: candidate template ignored: could not match '_Tp [_Np]' against 'const std::array<StackTrigger, stacks::ReadoutStackCount>'
begin(_Tp (&__array)[_Np])
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1790:1: note: candidate template ignored: substitution failure [with _Cp = const std::__1::array<mesytec::mvlc::StackTrigger, 7>]: implicit instantiation of undefined template 'std::__1::array<mesytec::mvlc::StackTrigger, 7>'
begin(_Cp& __c) -> decltype(__c.begin())
^ ~
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1798:1: note: candidate template ignored: substitution failure [with _Cp = std::__1::array<mesytec::mvlc::StackTrigger, 7>]: implicit instantiation of undefined template 'std::__1::array<mesytec::mvlc::StackTrigger, 7>'
begin(const _Cp& __c) -> decltype(__c.begin())
^ ~
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.cc:1:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog_util.h:263:42: error: no matching function for call to 'end'
std::transform(std::begin(triggers), std::end(triggers), std::begin(triggerValues),
^~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/initializer_list:108:1: note: candidate template ignored: could not match 'initializer_list' against 'array'
end(initializer_list<_Ep> __il) _NOEXCEPT
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1780:1: note: candidate template ignored: could not match '_Tp [_Np]' against 'const std::array<StackTrigger, stacks::ReadoutStackCount>'
end(_Tp (&__array)[_Np])
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1806:1: note: candidate template ignored: substitution failure [with _Cp = const std::__1::array<mesytec::mvlc::StackTrigger, 7>]: implicit instantiation of undefined template 'std::__1::array<mesytec::mvlc::StackTrigger, 7>'
end(_Cp& __c) -> decltype(__c.end())
^ ~
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/iterator:1814:1: note: candidate template ignored: substitution failure [with _Cp = std::__1::array<mesytec::mvlc::StackTrigger, 7>]: implicit instantiation of undefined template 'std::__1::array<mesytec::mvlc::StackTrigger, 7>'
end(const _Cp& __c) -> decltype(__c.end())
^ ~
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog.cc:21:
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_dialog.h:33:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/../mesytec-mvlc/mvlc_stack_errors.h:79:53: error: implicit instantiation of undefined template 'std::__1::array<std::__1::unordered_map<mesytec::mvlc::StackErrorInfo, unsigned long>, 8>'
std::array<ErrorInfoCounts, stacks::StackCount> stackErrors;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/__tuple:219:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
^
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc.cc:29:
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc.h:40:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_stack_errors.h:79:53: error: implicit instantiation of undefined template 'std::__1::array<std::__1::unordered_map<mesytec::mvlc::StackErrorInfo, unsigned long>, 8>'
std::array<ErrorInfoCounts, stacks::StackCount> stackErrors;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/__tuple:219:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
^
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_factory.cc:28:
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_factory.h:32:
In file included from /Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/../mesytec-mvlc/mvlc.h:40:
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_stack_errors.h:79:53: error: implicit instantiation of undefined template 'std::__1::array<std::__1::unordered_map<mesytec::mvlc::StackErrorInfo, unsigned long>, 8>'
std::array<ErrorInfoCounts, stacks::StackCount> stackErrors;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/__tuple:219:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
^
4 errors generated.
make[2]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_dialog_util.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
1 error generated.
make[2]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc.cc.o] Error 1
/Users/jacksonlawrence/mvme/mvme-master/external/mesytec-mvlc/src/mesytec-mvlc/mvlc_impl_eth.cc:16:14: fatal error: 'sys/prctl.h' file not found
#include <sys/prctl.h>
^~~~~~~~~~~~~
1 error generated.
make[2]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_dialog.cc.o] Error 1
1 error generated.
make[2]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_factory.cc.o] Error 1
1 error generated.
make[2]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/mvlc_impl_eth.cc.o] Error 1
make[1]: *** [external/mesytec-mvlc/src/mesytec-mvlc/CMakeFiles/mesytec-mvlc.dir/all] Error 2
make: *** [all] Error 2
Thanks in advance for any help!
Commit bb975a7 contains fixes for OSX (You also need to update the mesytec-mvlc submodule to get its fixes too). With these changes I was able to compile and run mvme. A basic DAQ test using the MVLC_ETH worked as expected.
I cannot test MVLC_USB as I currently do not have access to apple hardware.
Thank you so much for helping! I've gotten a but further in the compilation process, but it's quit at about halfway through because of warnings
[ 45%] Building CXX object src/CMakeFiles/libmvme.dir/analysis/object_factory.cc.o
[ 46%] Building CXX object src/CMakeFiles/libmvme.dir/analysis/object_info_widget.cc.o
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/listfilter_extractor_dialog.cc:21:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/listfilter_extractor_dialog.h:25:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis_serialization.cc:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/exportsink_codegen.cc:36:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.cc:21:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.h:26:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis_ui_p.h:45:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/analysis_serialization.cc:623:25: error: no member named 'fromString' in 'QUuid'; did you mean 'from_string'?
auto moduleId = QUuid::fromString(modProps.toObject()["moduleId"].toString());
^~~~~~~~~~~~~~~~~
from_string
/Users/jacksonlawrence/mvme/mvme/src/vme_controller.h:73:39: note: 'from_string' declared here
VMEControllerType LIBMVME_CORE_EXPORT from_string(const QString &str);
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/analysis_serialization.cc:625:20: error: no viable overloaded operator[] for type 'QMap<QUuid, QString>'
moduleNames[moduleId] = moduleName;
~~~~~~~~~~~^~~~~~~~~
/opt/anaconda3/include/qt/QtCore/qmap.h:387:8: note: candidate function not viable: no known conversion from 'VMEControllerType' to 'const QUuid' for 1st argument
T &operator[](const Key &key);
^
/opt/anaconda3/include/qt/QtCore/qmap.h:388:13: note: candidate function not viable: no known conversion from 'VMEControllerType' to 'const QUuid' for 1st argument
const T operator[](const Key &key) const;
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/exportsink_codegen.cc:270:19: warning: enumeration value 'CSV' not handled in switch [-Wswitch]
switch (sink->getFormat())
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/exportsink_codegen.cc:270:19: note: add missing switch cases
switch (sink->getFormat())
^
1 warning and 2 errors generated.
make[2]: *** [src/CMakeFiles/libmvme.dir/analysis/analysis_serialization.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/object_factory.cc:22:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.cc:77:46: warning: unused parameter 'watched' [-Wunused-parameter]
bool InputSelectButton::eventFilter(QObject *watched, QEvent *event)
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.cc:218:55: warning: unused parameter 'watched' [-Wunused-parameter]
bool ExpressionOperatorPipeView::eventFilter(QObject *watched, QEvent *event)
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.cc:1029:23: warning: unused variable 'expected_size' [-Wunused-variable]
const s32 expected_size = static_cast<s32>(data.size());
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/expression_operator_dialog.cc:1022:56: warning: unused parameter 'a2_pipe' [-Wunused-parameter]
void assert_consistency(const a2::PipeVectors &a2_pipe) const
^
1 warning generated.
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/object_info_widget.cc:23:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2_adapter.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/analysis.h:24:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/a2.h:18:
In file included from /Users/jacksonlawrence/mvme/mvme/src/analysis/a2/rate_sampler.h:27:
In file included from /usr/local/include/boost/circular_buffer.hpp:57:
/usr/local/include/boost/circular_buffer/details.hpp:262:15: warning: definition of implicit copy constructor for 'iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' is deprecated because it has a user-declared copy assignment operator [-Wdeprecated-copy]
iterator& operator = (const iterator& it) {
^
/Users/jacksonlawrence/mvme/mvme/src/analysis/../rate_monitor_base.h:82:105: note: in implicit copy constructor for 'boost::cb_details::iterator<boost::circular_buffer<double>, boost::cb_details::const_traits<std::__1::allocator<double>>>' first required here
const auto f_begin = boost::make_filter_iterator<not_nan_filter, RateHistoryBuffer::const_iterator>(rh.begin());
^
1 warning generated.
1 warning generated.
2 warnings generated.
5 warnings generated.
make[1]: *** [src/CMakeFiles/libmvme.dir/all] Error 2
make: *** [all] Error 2
Is this because I have something out of data or two conflicting programs? I'll note that I had to uninstall qt6 because it was conflicting with qt5 and causing errors before this. I've got both the updated mvme and the mesytec-mvlc code.