Re: [GNC-dev] Error building stable

Herbert Thoma <[email protected]>
Newsgroups gmane.comp.gnome.apps.gnucash.devel
Message-ID <[email protected]>
Am 27.03.23 um 18:50 schrieb john:
> stable is what used to be master, so you need to ninja uninstall && rm -rf * && cmake … && ninja if you're starting from a build directory with a 4.x build in it. If you hadn't run ninja install then ninja uninstall isn't necessary, and if did install but cleaned the build directory and lost install.manifest then you `find <install-dir> -name libgnc*.so -delete && rm -rf <install-dir>/lib/guile/<guileversion>/site-ccache/gnucash/` should be remove enough install artifacts to get the new build to work.

I used a fresh clone of the stable branch and a new clean build dir.
I removed the complete install dir as well. Still the same error.

Below is the full compiler error message.

Best,
  Herbert.

In file included from /home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:25:0:
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option-impl.hpp: In instantiation of ‘std::istream& operator>>(std::istream&, OptType&) [with OptType = GncOptionGncOwnerValue; typename std::enable_if<(is_OptionClassifier_v<OptType> && (!(is_QofInstanceValue_v<OptType> || is_RangeValue_v<OptType>))), int>::type <anonymous> = 0; std::istream = std::basic_istream<char>]’:
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:446:31:   required from ‘GncOption::in_stream(std::istream&)::<lambda(auto:28&)> [with auto:28 = GncOptionGncOwnerValue; std::istream = std::basic_istream<char>]’
/usr/include/c++/7/type_traits:2802:42:   required from ‘constexpr bool std::__call_is_nt(std::__invoke_other) [with _Fn = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>; _Args = {GncOptionGncOwnerValue&}]’
/usr/include/c++/7/type_traits:2808:34:   required by substitution of ‘template<bool __v> using __bool_constant = std::integral_constant<bool, __v> [with bool __v = std::__call_is_nt<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&>((std::__result_of_success<std::basic_istream<char>&, std::__invoke_other>::__invoke_type{}, std::__result_of_success<std::basic_istream<char>&, std::__invoke_other>::__invoke_type()))]’
/usr/include/c++/7/type_traits:2806:12:   required from ‘struct std::__call_is_nothrow<std::__invoke_result<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&>, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&>’
/usr/include/c++/7/type_traits:143:12:   required from ‘struct std::__and_<std::__is_invocable<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&>, std::__call_is_nothrow<std::__invoke_result<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&>, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionGncOwnerValue&> >’
/usr/include/c++/7/type_traits:2818:12:   [ skipping 3 instantiation contexts, use -ftemplate-backtrace-limit=0 to disable ]
/usr/include/c++/7/variant:693:28:   required from ‘static constexpr auto std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<_Result_type (*)(_Visitor, _Variants ...)>, std::tuple<_Tail ...>, std::integer_sequence<long unsigned int, __indices ...> >::_S_apply() [with _Result_type = std::basic_istream<char>&; _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}; long unsigned int ...__indices = {4}]’
/usr/include/c++/7/variant:671:61:   required from ‘static constexpr void std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<_Result_type (*)(_Visitor, _Variants ...), __dimensions ...>, std::tuple<_Variants ...>, std::integer_sequence<long unsigned int, __indices ...> >::_S_apply_single_alt(_Tp&) [with long unsigned int __index = 4; _Tp = std::__detail::__variant::_Multi_array<std::basic_istream<char>& (*)(GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&)>; _Result_type = std::basic_istream<char>&; _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&; long unsigned int ...__dimensions = {14}; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}; long unsigned int ...__indices = {}]’
/usr/include/c++/7/variant:659:39:   required from ‘constexpr const std::__detail::__variant::_Multi_array<std::basic_istream<char>& (*)(GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&), 14> std::__detail::__variant::__gen_vtable<std::basic_istream<char>&, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&>::_S_vtable’
/usr/include/c++/7/variant:711:29:   required from ‘struct std::__detail::__variant::__gen_vtable<std::basic_istream<char>&, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&>’
/usr/include/c++/7/variant:1255:23:   required from ‘constexpr decltype(auto) std::visit(_Visitor&&, _Variants&& ...) [with _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}]’
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:448:35:   required from here
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option-impl.hpp:331:45: error: variable ‘value’ set but not used [-Werror=unused-but-set-variable]
      std::decay_t<decltype(opt.get_value())> value;
                                              ^~~~~
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option-impl.hpp: In instantiation of ‘std::istream& operator>>(std::istream&, OptType&) [with OptType = GncOptionValue<const _QofQuery*>; typename std::enable_if<(is_OptionClassifier_v<OptType> && (!(is_QofInstanceValue_v<OptType> || is_RangeValue_v<OptType>))), int>::type <anonymous> = 0; std::istream = std::basic_istream<char>]’:
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:446:31:   required from ‘GncOption::in_stream(std::istream&)::<lambda(auto:28&)> [with auto:28 = GncOptionValue<const _QofQuery*>; std::istream = std::basic_istream<char>]’
/usr/include/c++/7/type_traits:2802:42:   required from ‘constexpr bool std::__call_is_nt(std::__invoke_other) [with _Fn = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>; _Args = {GncOptionValue<const _QofQuery*>&}]’
/usr/include/c++/7/type_traits:2808:34:   required by substitution of ‘template<bool __v> using __bool_constant = std::integral_constant<bool, __v> [with bool __v = std::__call_is_nt<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&>((std::__result_of_success<std::basic_istream<char>&, std::__invoke_other>::__invoke_type{}, std::__result_of_success<std::basic_istream<char>&, std::__invoke_other>::__invoke_type()))]’
/usr/include/c++/7/type_traits:2806:12:   required from ‘struct std::__call_is_nothrow<std::__invoke_result<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&>, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&>’
/usr/include/c++/7/type_traits:143:12:   required from ‘struct std::__and_<std::__is_invocable<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&>, std::__call_is_nothrow<std::__invoke_result<GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&>, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>, GncOptionValue<const _QofQuery*>&> >’
/usr/include/c++/7/type_traits:2818:12:   [ skipping 3 instantiation contexts, use -ftemplate-backtrace-limit=0 to disable ]
/usr/include/c++/7/variant:693:28:   required from ‘static constexpr auto std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<_Result_type (*)(_Visitor, _Variants ...)>, std::tuple<_Tail ...>, std::integer_sequence<long unsigned int, __indices ...> >::_S_apply() [with _Result_type = std::basic_istream<char>&; _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}; long unsigned int ...__indices = {5}]’
/usr/include/c++/7/variant:671:61:   required from ‘static constexpr void std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<_Result_type (*)(_Visitor, _Variants ...), __dimensions ...>, std::tuple<_Variants ...>, std::integer_sequence<long unsigned int, __indices ...> >::_S_apply_single_alt(_Tp&) [with long unsigned int __index = 5; _Tp = std::__detail::__variant::_Multi_array<std::basic_istream<char>& (*)(GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&)>; _Result_type = std::basic_istream<char>&; _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&; long unsigned int ...__dimensions = {14}; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}; long unsigned int ...__indices = {}]’
/usr/include/c++/7/variant:659:39:   required from ‘constexpr const std::__detail::__variant::_Multi_array<std::basic_istream<char>& (*)(GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&), 14> std::__detail::__variant::__gen_vtable<std::basic_istream<char>&, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&>::_S_vtable’
/usr/include/c++/7/variant:711:29:   required from ‘struct std::__detail::__variant::__gen_vtable<std::basic_istream<char>&, GncOption::in_stream(std::istream&)::<lambda(auto:28&)>&&, std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&>’
/usr/include/c++/7/variant:1255:23:   required from ‘constexpr decltype(auto) std::visit(_Visitor&&, _Variants&& ...) [with _Visitor = GncOption::in_stream(std::istream&)::<lambda(auto:28&)>; _Variants = {std::variant<GncOptionValue<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, GncOptionValue<bool>, GncOptionValue<long int>, GncOptionQofInstanceValue, GncOptionGncOwnerValue, GncOptionValue<const _QofQuery*>, GncOptionValue<std::vector<std::tuple<unsigned int, unsigned int, unsigned int>, std::allocator<std::tuple<unsigned int, unsigned int, unsigned int> > > >, GncOptionAccountListValue, GncOptionAccountSelValue, GncOptionMultichoiceValue, GncOptionRangeValue<int>, GncOptionRangeValue<double>, GncOptionCommodityValue, GncOptionDateValue>&}]’
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:448:35:   required from here
/home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option-impl.hpp:331:45: error: variable ‘value’ set but not used [-Werror=unused-but-set-variable]
cc1plus: all warnings being treated as errors
make[2]: *** [libgnucash/engine/CMakeFiles/gnc-engine.dir/build.make:548: libgnucash/engine/CMakeFiles/gnc-engine.dir/gnc-option.cpp.o] Fehler 1
make[1]: *** [CMakeFiles/Makefile2:4486: libgnucash/engine/CMakeFiles/gnc-engine.dir/all] Fehler 2
make: *** [Makefile:166: all] Fehler 2



> Regards,
> John Ralls
> 
> 
>> On Mar 27, 2023, at 8:59 AM, Herbert Thoma <[email protected]> wrote:
>>
>> Hi!
>>
>> I tried to build the current stable branch and got the following error:
>>
>> [ 10%] Building CXX object libgnucash/engine/CMakeFiles/gnc-engine.dir/gnc-option.cpp.o
>> In file included from /home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:25:0:
>>
>> <lots of c++ dependency information (I assume, I don't really understand this>
>>
>> /home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option.cpp:448:35:   required from here
>> /home/tma/gnucash/gnucash_cvs/gnucash_stable/libgnucash/engine/gnc-option-impl.hpp:331:45: error: variable ‘value’ set but not used [-Werror=unused-but-set-variable]
>> cc1plus: all warnings being treated as errors
>>
>>
>> The last 4.x maint branch compiled for me, but I updated the OS in the meantime
>>
>> openSUSE 13.4
>> gcc 7.5.0
>>
>> Herbert.
>> _______________________________________________
>> gnucash-devel mailing list
>> [email protected]
>> https://lists.gnucash.org/mailman/listinfo/gnucash-devel
> 
> _______________________________________________
> gnucash-devel mailing list
> [email protected]
> https://lists.gnucash.org/mailman/listinfo/gnucash-devel

_______________________________________________
gnucash-devel mailing list
[email protected]
https://lists.gnucash.org/mailman/listinfo/gnucash-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.