Bug#1016262: vmmlib: FTBFS: hashtable.h:1208:18: error: expected unqualified-id before ‘(’ token
Hi all. Updated debdiff. Thanks, Paul diff -Nru vmmlib-1.0/debian/changelog vmmlib-1.0/debian/changelog --- vmmlib-1.0/debian/changelog 2021-01-02 09:15:59.0 +0800 +++ vmmlib-1.0/debian/changelog 2022-09-18 16:28:02.0 +0800 @@ -1,3 +1,14 @@ +vmmlib (1.0-2.3) unstable; urgency=low + + * Non-maintainer upload. + * Fix FTBFS (Closes: #1016262) +- Remove debian/patches/fix_ftbfs_gcc8.patch +- Update debian/patches/fix-makefile to not use f2c related headers. +- Add debian/patches/fix-quaternion.patch for not returning value in + void function. + + -- Ying-Chun Liu (PaulLiu) Sun, 18 Sep 2022 16:28:02 +0800 + vmmlib (1.0-2.2) unstable; urgency=medium * Non maintainer upload by the Reproducible Builds team. diff -Nru vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch --- vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch 2018-10-29 19:46:59.0 +0800 +++ vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch 1970-01-01 08:00:00.0 +0800 @@ -1,142 +0,0 @@ -Description: Fix FTBFS on gcc-8 - There are several build failed due to min/max/abs defined somewhere. - We have to undef it to let it uses those from -Author: Ying-Chun Liu (PaulLiu) -Bug-Debian: https://bugs.debian.org/834472 -Last-Update: 2018-10-25 -Index: vmmlib-1.0/include/vmmlib/vector.hpp -=== vmmlib-1.0.orig/include/vmmlib/vector.hpp -+++ vmmlib-1.0/include/vmmlib/vector.hpp -@@ -1,6 +1,10 @@ - #ifndef __VMML__VECTOR__HPP__ - #define __VMML__VECTOR__HPP__ - -+#undef min -+#undef max -+#undef abs -+ - #include - #include - #include -Index: vmmlib-1.0/include/vmmlib/quaternion.hpp -=== vmmlib-1.0.orig/include/vmmlib/quaternion.hpp -+++ vmmlib-1.0/include/vmmlib/quaternion.hpp -@@ -757,7 +757,7 @@ quaternion< T >::operator-=( const vecto - x() -= xyz.x(); - y() -= xyz.y(); - z() -= xyz.z(); -- return *this; -+ //return *this; - } - - -Index: vmmlib-1.0/tests/tensor3_test.cpp -=== vmmlib-1.0.orig/tests/tensor3_test.cpp -+++ vmmlib-1.0/tests/tensor3_test.cpp -@@ -1,5 +1,9 @@ - #include "tensor3_test.hpp" - -+#undef max -+#undef min -+#undef abs -+ - #include - #include - -Index: vmmlib-1.0/tests/tucker3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/tucker3_tensor_test.cpp -+++ vmmlib-1.0/tests/tucker3_tensor_test.cpp -@@ -1,5 +1,9 @@ - #include "tucker3_tensor_test.hpp" - -+#undef min -+#undef max -+#undef abs -+ - #include - #include - -Index: vmmlib-1.0/tests/qtucker3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/qtucker3_tensor_test.cpp -+++ vmmlib-1.0/tests/qtucker3_tensor_test.cpp -@@ -1,4 +1,6 @@ - #include "qtucker3_tensor_test.hpp" -+#undef min -+ - #include - #include - -Index: vmmlib-1.0/tests/tucker3_exporter_importer_test.cpp -=== vmmlib-1.0.orig/tests/tucker3_exporter_importer_test.cpp -+++ vmmlib-1.0/tests/tucker3_exporter_importer_test.cpp -@@ -1,4 +1,5 @@ - #include "tucker3_exporter_importer_test.hpp" -+#undef min - #include - #include - #include -Index: vmmlib-1.0/tests/cp3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/cp3_tensor_test.cpp -+++ vmmlib-1.0/tests/cp3_tensor_test.cpp -@@ -1,4 +1,5 @@ - #include "cp3_tensor_test.hpp" -+#undef min - #include - #include - #include -Index: vmmlib-1.0/tests/t3_hosvd_test.cpp -=== vmmlib-1.0.orig/tests/t3_hosvd_test.cpp -+++ vmmlib-1.0/tests/t3_hosvd_test.cpp -@@ -1,3 +1,4 @@ -+#undef min - #include "t3_hosvd_test.hpp" - #include "vmmlib/t3_hosvd.hpp" - -Index: vmmlib-1.0/tests/t3_hooi_test.cpp -=== vmmlib-1.0.orig/tests/t3_hooi_test.cpp -+++ vmmlib-1.0/tests/t3_hooi_test.cpp -@@ -1,3 +1,4 @@ -+#undef min - #include "t3_hooi_test.hpp" - #include "vmmlib/t3_hooi.hpp" - -Index: vmmlib-1.0/tests/t3_hopm_test.cpp -=== vmmlib-1.0.orig/tests/t3_hopm_test.cpp -+++ vmmlib-1.0/tests/t3_hopm_test.cpp -@@ -1,3 +1,4 @@ -+#undef min - #include "t3_hopm_test.hpp" - #include "vmmlib/t3_hopm.hpp" - #include -Index: vmmlib-1.0/tests/t3_ihopm_test.cpp -=== vmmlib-1.0.orig/tests/t3_ihopm_test.cpp -+++ vmmlib-1.0/tests/t3_ihopm_test.cpp -@@ -1,3 +1,4 @@ -+#undef min - #include "t3_ihopm_test.hpp" - #include "vmmlib/t3_ihopm.hpp" - #include -Index: vmmlib-1.0/Makefile -===
Bug#1016262: vmmlib: FTBFS: hashtable.h:1208:18: error: expected unqualified-id before ‘(’ token
Hi all. I'm about to fix this bug. And I'll do NMU of this package. The attached file is the debdiff of the NMU. I'll wait for 10 days if no other complains about the fix. And I'll upload to delay/10 queue. So this bug is basically because #897845 and #834472 is not fixed properly by me previously. I was using a workaround to fix the above bugs. After deeply tracing, I found the root cause is we shouldn't use f2c headers in this package. f2c is not using in this package at all. And thus this bug will be fixed with removing include those headers which cause max/min/abs functions conflict with STL and standard C library. And also I removed the previously workaround. But the build still fails because one of the operator -= function returns a value while it is set to void. So I made another patch to fix this. Please review the debdiff, and I'll upload it with NMU after 10 days. To the delay/10 queue and with priority=low. Thanks, Paul diff -Nru vmmlib-1.0/debian/changelog vmmlib-1.0/debian/changelog --- vmmlib-1.0/debian/changelog 2021-01-02 09:15:59.0 +0800 +++ vmmlib-1.0/debian/changelog 2022-09-18 16:28:02.0 +0800 @@ -1,3 +1,14 @@ +vmmlib (1.0-2.3) unstable; urgency=low + + * Non-maintainer upload. + * Fix FTBFS (Closes: #1016262) +- Remove debian/patches/fix_ftbfs_gcc8.patch +- Update debian/patches/fix-makefile to not use f2c related headers. +- Add debian/patches/fix-quaternion.patch for not returning value in + void function. + + -- Ying-Chun Liu (PaulLiu) Sun, 18 Sep 2022 16:28:02 +0800 + vmmlib (1.0-2.2) unstable; urgency=medium * Non maintainer upload by the Reproducible Builds team. diff -Nru vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch --- vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch 2018-10-29 19:46:59.0 +0800 +++ vmmlib-1.0/debian/patches/fix_ftbfs_gcc8.patch 1970-01-01 08:00:00.0 +0800 @@ -1,142 +0,0 @@ -Description: Fix FTBFS on gcc-8 - There are several build failed due to min/max/abs defined somewhere. - We have to undef it to let it uses those from -Author: Ying-Chun Liu (PaulLiu) -Bug-Debian: https://bugs.debian.org/834472 -Last-Update: 2018-10-25 -Index: vmmlib-1.0/include/vmmlib/vector.hpp -=== vmmlib-1.0.orig/include/vmmlib/vector.hpp -+++ vmmlib-1.0/include/vmmlib/vector.hpp -@@ -1,6 +1,10 @@ - #ifndef __VMML__VECTOR__HPP__ - #define __VMML__VECTOR__HPP__ - -+#undef min -+#undef max -+#undef abs -+ - #include - #include - #include -Index: vmmlib-1.0/include/vmmlib/quaternion.hpp -=== vmmlib-1.0.orig/include/vmmlib/quaternion.hpp -+++ vmmlib-1.0/include/vmmlib/quaternion.hpp -@@ -757,7 +757,7 @@ quaternion< T >::operator-=( const vecto - x() -= xyz.x(); - y() -= xyz.y(); - z() -= xyz.z(); -- return *this; -+ //return *this; - } - - -Index: vmmlib-1.0/tests/tensor3_test.cpp -=== vmmlib-1.0.orig/tests/tensor3_test.cpp -+++ vmmlib-1.0/tests/tensor3_test.cpp -@@ -1,5 +1,9 @@ - #include "tensor3_test.hpp" - -+#undef max -+#undef min -+#undef abs -+ - #include - #include - -Index: vmmlib-1.0/tests/tucker3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/tucker3_tensor_test.cpp -+++ vmmlib-1.0/tests/tucker3_tensor_test.cpp -@@ -1,5 +1,9 @@ - #include "tucker3_tensor_test.hpp" - -+#undef min -+#undef max -+#undef abs -+ - #include - #include - -Index: vmmlib-1.0/tests/qtucker3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/qtucker3_tensor_test.cpp -+++ vmmlib-1.0/tests/qtucker3_tensor_test.cpp -@@ -1,4 +1,6 @@ - #include "qtucker3_tensor_test.hpp" -+#undef min -+ - #include - #include - -Index: vmmlib-1.0/tests/tucker3_exporter_importer_test.cpp -=== vmmlib-1.0.orig/tests/tucker3_exporter_importer_test.cpp -+++ vmmlib-1.0/tests/tucker3_exporter_importer_test.cpp -@@ -1,4 +1,5 @@ - #include "tucker3_exporter_importer_test.hpp" -+#undef min - #include - #include - #include -Index: vmmlib-1.0/tests/cp3_tensor_test.cpp -=== vmmlib-1.0.orig/tests/cp3_tensor_test.cpp -+++ vmmlib-1.0/tests/cp3_tensor_test.cpp -@@ -1,4 +1,5 @@ - #include "cp3_tensor_test.hpp" -+#undef min - #include - #include - #include -Index: vmmlib-1.0/tests/t3_hosvd_test.cpp -=== vmmlib-1.0.orig/tests/t3_hosvd_test.cpp -+++ vmmlib-1.0/tests/t3_hosvd_test.cpp -@@ -1,3 +1,4 @@ -+#undef min - #include "t3_hosvd_test.hpp" - #include "vmmlib/t3_hosvd.hpp" - -Index: vmmlib-1.0/tests/t3_hooi_test.cpp -
Bug#1016262: vmmlib: FTBFS: hashtable.h:1208:18: error: expected unqualified-id before ‘(’ token
Source: vmmlib Version: 1.0-2.2 Severity: serious Justification: FTBFS Tags: bookworm sid ftbfs User: lu...@debian.org Usertags: ftbfs-20220728 ftbfs-bookworm Hi, During a rebuild of all packages in sid, your package failed to build on amd64. Relevant part (hopefully): > g++ -g -O2 -ffile-prefix-map=/<>=. -fstack-protector-strong > -Wformat -Werror=format-security -I. -Iinclude -Itests -include cstdint > -include algorithm -include string -include iostream -include f2c.h -include > f2c_fix.h -c tests/lapack_gaussian_elimination_test.cpp -o > tests/lapack_gaussian_elimination_test.o > In file included from : > /usr/include/c++/12/bits/hashtable.h: In constructor ‘std::_Hashtable<_Key, > _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, _Unused, > _RehashPolicy, _Traits>::_Hashtable(_InputIterator, _InputIterator, > size_type, const _Hash&, const _Equal&, const allocator_type&, > std::false_type)’: > /usr/include/c++/12/bits/hashtable.h:1208:18: error: expected unqualified-id > before ‘(’ token > 1208 | std::max(_M_rehash_policy._M_bkt_for_elements(__nb_elems), > | ^~~ > In file included from : > /usr/include/c++/12/bits/hashtable.h: In constructor ‘std::_Hashtable<_Key, > _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, _Unused, > _RehashPolicy, _Traits>::_Hashtable(_InputIterator, _InputIterator, > size_type, const _Hash&, const _Equal&, const allocator_type&, > std::false_type)’: > /usr/include/c++/12/bits/hashtable.h:1208:18: error: expected unqualified-id > before ‘(’ token > 1208 | std::max(_M_rehash_policy._M_bkt_for_elements(__nb_elems), > | ^~~ > /usr/include/c++/12/bits/hashtable.h: In member function ‘void > std::_Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, > _Unused, _RehashPolicy, _Traits>::rehash(size_type)’: > /usr/include/c++/12/bits/hashtable.h:2516:16: error: expected unqualified-id > before ‘(’ token > 2516 | = > std::max(_M_rehash_policy._M_bkt_for_elements(_M_element_count + 1), > |^~~ > /usr/include/c++/12/bits/hashtable.h: In member function ‘void > std::_Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, > _Unused, _RehashPolicy, _Traits>::rehash(size_type)’: > /usr/include/c++/12/bits/hashtable.h:2516:16: error: expected unqualified-id > before ‘(’ token > 2516 | = > std::max(_M_rehash_policy._M_bkt_for_elements(_M_element_count + 1), > |^~~ > In file included from : > /usr/include/c++/12/bits/hashtable.h: In constructor ‘std::_Hashtable<_Key, > _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, _Unused, > _RehashPolicy, _Traits>::_Hashtable(_InputIterator, _InputIterator, > size_type, const _Hash&, const _Equal&, const allocator_type&, > std::false_type)’: > /usr/include/c++/12/bits/hashtable.h:1208:18: error: expected unqualified-id > before ‘(’ token > 1208 | std::max(_M_rehash_policy._M_bkt_for_elements(__nb_elems), > | ^~~ > /usr/include/c++/12/bits/hashtable.h: In member function ‘void > std::_Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, > _Unused, _RehashPolicy, _Traits>::rehash(size_type)’: > /usr/include/c++/12/bits/hashtable.h:2516:16: error: expected unqualified-id > before ‘(’ token > 2516 | = > std::max(_M_rehash_policy._M_bkt_for_elements(_M_element_count + 1), > |^~~ > /usr/include/c++/12/bits/stl_bvector.h: In member function ‘std::vector _Alloc>::size_type std::vector::_M_check_len(size_type, const > char*) const’: > /usr/include/c++/12/bits/stl_bvector.h:1484:47: error: expected > unqualified-id before ‘(’ token > 1484 | const size_type __len = size() + std::max(size(), __n); > | ^~~ > /usr/include/c++/12/bits/stl_bvector.h: In member function ‘std::vector _Alloc>::size_type std::vector::_M_check_len(size_type, const > char*) const’: > /usr/include/c++/12/bits/stl_bvector.h:1484:47: error: expected > unqualified-id before ‘(’ token > 1484 | const size_type __len = size() + std::max(size(), __n); > | ^~~ > In file included from : > /usr/include/c++/12/bits/hashtable.h: In constructor ‘std::_Hashtable<_Key, > _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, _Unused, > _RehashPolicy, _Traits>::_Hashtable(_InputIterator, _InputIterator, > size_type, const _Hash&, const _Equal&, const allocator_type&, > std::false_type)’: > /usr/include/c++/12/bits/hashtable.h:1208:18: error: expected unqualified-id > before ‘(’ token > 1208 | std::max(_M_rehash_policy._M_bkt_for_elements(__nb_elems), > | ^~~ > /usr/include/c++/12/bits/hashtable.h: In member function ‘void > std::_Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, _Hash, _RangeHash, > _Unused, _RehashPolicy, _Traits>::r