Source: libvbz-hdf-plugin
Version: 1.0.2-3.1
Severity: normal
Tags: patch
User: [email protected]
Usertags: loong64
X-Debbugs-Cc: [email protected]

Dear maintainers,

Compiling the libvbz-hdf-plugin failed for loong64 in the Debian Package Auto-Building environment.
The error log is as follows,
```
[ 33%] Built target hdf_test_utils
In file included from /build/reproducible-path/libvbz-hdf-plugin-1.0.2/vbz/v0/vbz_streamvbyte.cpp:2: In static member function ‘static std::vector<U> StreamVByteWorkerV0<T, UseZigZag>::cast(const gsl::span<V>&) [with U = int; V = const int; T = int; bool UseZigZag = true]’,     inlined from ‘static vbz_size_t StreamVByteWorkerV0<T, UseZigZag>::compress(gsl::span<const char>, gsl::span<char>) [with T = int; bool UseZigZag = true]’ at /build/reproducible-path/libvbz-hdf-plugin-1.0.2/vbz/v0/vbz_streamvbyte_impl.h:30:35,     inlined from ‘vbz_size_t vbz_delta_zig_zag_streamvbyte_compress_v0(const void*, vbz_size_t, void*, vbz_size_t, int, bool)’ at /build/reproducible-path/libvbz-hdf-plugin-1.0.2/vbz/v0/vbz_streamvbyte.cpp:54:73: /build/reproducible-path/libvbz-hdf-plugin-1.0.2/vbz/v0/vbz_streamvbyte_impl.h:75:23: error: ‘void* __builtin_memcpy(void*, const void*, long unsigned int)’ offset [0, 3] is out of the bounds [0, 0] [-Werror=array-bounds=]
   75 |             output[i] = input[i];
```

Please consider the patch attached.
I have built libvbz-hdf-plugin normally on locally.

Best regards,
Dandan Zhang

diff -Nru libvbz-hdf-plugin-1.0.2/debian/rules libvbz-hdf-plugin-1.0.2/debian/rules
--- libvbz-hdf-plugin-1.0.2/debian/rules	2023-07-23 08:52:45.000000000 +0000
+++ libvbz-hdf-plugin-1.0.2/debian/rules	2024-02-28 21:02:18.000000000 +0000
@@ -8,6 +8,10 @@
 #       vbz/vbz.cpp:314:17: error: possibly dangling reference to a temporary
 export DEB_CXXFLAGS_MAINT_APPEND = -Wno-error=dangling-reference
 
+ifeq ($(DEB_HOST_ARCH_CPU),loong64)
+        DEB_CXXFLAGS_MAINT_APPEND += -Wno-error=array-bounds
+endif
+
 include /usr/share/dpkg/default.mk
 
 %:

Reply via email to