blosc_test_malloc() has 4 options of aligned memory allocation, of which
aligned_alloc and posix_memalign are supported on OpenBSD, but none of
the guards are satisfied and we hit:
#error Cannot determine how to allocate aligned memory on the target platform
I think the easiest way to pick one is to just enable
-D_XOPEN_SOURCE=600 inside CMakeLists.txt. Since this is also most
likely the one used on amd64, which includes it in the build options.
After building the following tests fail on alpha:
2 - test_plugin_test_zfp_acc_float (Bus error)
3 - test_plugin_test_zfp_prec_float (Bus error)
4 - test_plugin_test_zfp_rate_float (Bus error)
5 - test_plugin_test_zfp_rate_getitem (Bus error)
11 - test_b2nd_append (Bus error)
12 - test_b2nd_concatenate (Bus error)
13 - test_b2nd_copy (Bus error)
15 - test_b2nd_delete (Bus error)
16 - test_b2nd_expand_dims (Bus error)
18 - test_b2nd_get_slice (Bus error)
19 - test_b2nd_get_slice_buffer (Bus error)
20 - test_b2nd_insert (Bus error)
24 - test_b2nd_persistency (Bus error)
26 - test_b2nd_roundtrip (Bus error)
27 - test_b2nd_save (Bus error)
28 - test_b2nd_save_append (Bus error)
29 - test_b2nd_serialize (Failed)
30 - test_b2nd_set_slice_buffer (Bus error)
31 - test_b2nd_squeeze (Bus error)
32 - test_b2nd_squeeze_index (Bus error)
442 - test_copy (Failed)
443 - test_delete_chunk (Bus error)
450 - test_frame (Bus error)
453 - test_get_slice_buffer (Bus error)
855 - test_insert_chunk (Bus error)
856 - test_lazychunk (Bus error)
866 - test_reorder_offsets (Bus error)
868 - test_schunk_frame (Bus error)
869 - test_schunk_header (Bus error)
870 - test_set_slice_buffer (Failed)
871 - test_sframe (Bus error)
872 - test_sframe_lazychunk (Bus error)
1141 - test_update_chunk (Bus error)
1203 - test_example_sframe_simple (Bus error)
1212 - test_example_frame_big (Bus error)
1217 - b2nd_example_plugins_codecs (Failed) b2nd
While here, include some offset fixes as found by update-patches.
OK?
martijn@
diff /usr/ports
path + /usr/ports
commit - dabb10645831ae72b913c35289ee6efebe0b40ed
blob - 1fca137a2838a4c8f5b9e9114e7aaeb8f91d9ed7
file + archivers/blosc2/Makefile
--- archivers/blosc2/Makefile
+++ archivers/blosc2/Makefile
@@ -2,6 +2,7 @@ V = 2.23.1
COMMENT = fast, compressed, persistent binary data store library for C
PKGNAME = blosc2-${V}
CATEGORIES = archivers
+REVISION = 0
SHARED_LIBS += blosc2 6.0 # 0.0
commit - dabb10645831ae72b913c35289ee6efebe0b40ed
blob - /dev/null
file + archivers/blosc2/patches/patch-CMakeLists_txt (mode 644)
--- /dev/null
+++ archivers/blosc2/patches/patch-CMakeLists_txt
@@ -0,0 +1,17 @@
+OpenBSD supports _XOPEN_SOURCE=600, and is required to let
+tests/test_common.h make a choice for blosc_test_malloc().
+Index: CMakeLists.txt
+--- CMakeLists.txt.orig
++++ CMakeLists.txt
+@@ -409,10 +409,7 @@ if(CMAKE_C_COMPILER_ID MATCHES GNU|Clang|Intel|IntelLL
+ endif()
+ endif()
+
+-if(CMAKE_C_COMPILER_ID MATCHES Intel|IntelLLVM|Clang OR HAIKU)
+- # We need to tell Intel and Clang compilers about what level of POSIX
they support
+- SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600")
+-endif()
++SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600")
+
+ if(MSVC)
+ if(NOT CMAKE_C_FLAGS)
commit - dabb10645831ae72b913c35289ee6efebe0b40ed
blob - 63f8403aeed7c560548d9b95aa4500f849ddbfcc
file + archivers/blosc2/patches/patch-blosc_CMakeLists_txt
--- archivers/blosc2/patches/patch-blosc_CMakeLists_txt
+++ archivers/blosc2/patches/patch-blosc_CMakeLists_txt
@@ -1,7 +1,7 @@
Index: blosc/CMakeLists.txt
--- blosc/CMakeLists.txt.orig
+++ blosc/CMakeLists.txt
-@@ -234,7 +234,9 @@ if(HAVE_IPP)
+@@ -173,7 +173,9 @@ if(HAVE_IPP)
endif()
if(UNIX AND NOT APPLE)