The package rpms/morphio.git has added or updated architecture specific content in its spec file (ExclusiveArch/ExcludeArch or %ifarch/%ifnarch) in commit(s): https://src.fedoraproject.org/cgit/rpms/morphio.git/commit/?id=fda4e64a55aad....
Change: -ExcludeArch: %{ix86} %{arm32}
Thanks.
Full change: ============
commit 16236f9951d16b07ff13a362a888089e186703ed Author: Ankur Sinha (Ankur Sinha Gmail) sanjay.ankur@gmail.com Date: Mon Feb 21 11:57:48 2022 +0000
feat: update to 3.3.2 (fixes rhbz#2021598)
diff --git a/.gitignore b/.gitignore index 979d507..4811b67 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /pybind11-799dbda.tar.gz /morphio-3.3.0.tar.gz /pybind11-b4e5d58.tar.gz +/morphio-3.3.2.tar.gz diff --git a/0001-Do-not-use-their-compiler-flags.patch b/0001-Do-not-use-their-compiler-flags.patch index 9489ad1..a7ea960 100644 --- a/0001-Do-not-use-their-compiler-flags.patch +++ b/0001-Do-not-use-their-compiler-flags.patch @@ -1,7 +1,7 @@ -From 1d1d2bb9ded0a49ff05886ab973ddc984b096b8b Mon Sep 17 00:00:00 2001 +From 1b076a454fd5ccb85255e2f1da5329f1f733badd Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 17:26:56 +0100 -Subject: [PATCH 1/7] Do not use their compiler flags +Subject: [PATCH 1/8] Do not use their compiler flags
--- CMakeLists.txt | 1 - @@ -20,5 +20,5 @@ index 875d3fa..c8c7c9e 100644
if (EXTERNAL_HIGHFIVE) -- -2.31.1 +2.35.1
diff --git a/0002-Stop-them-using-a-random-env-var.patch b/0002-Stop-them-using-a-random-env-var.patch index c81779e..44d1ba9 100644 --- a/0002-Stop-them-using-a-random-env-var.patch +++ b/0002-Stop-them-using-a-random-env-var.patch @@ -1,7 +1,7 @@ -From 980cd17b5e2decf5f7ab2d39662d1e0c1b6afe9b Mon Sep 17 00:00:00 2001 +From 6c41b2c4de8450380b77532d864d55b61f98b2ca Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 17:33:04 +0100 -Subject: [PATCH 2/7] Stop them using a random env var +Subject: [PATCH 2/8] Stop them using a random env var
--- CMakeLists.txt | 1 - @@ -20,5 +20,5 @@ index c8c7c9e..b53cd11 100644 if (EXTERNAL_HIGHFIVE) find_package(HighFive REQUIRED) -- -2.31.1 +2.35.1
diff --git a/0003-Use-gnuinstall-dirs.patch b/0003-Use-gnuinstall-dirs.patch index 8246dd5..43bab28 100644 --- a/0003-Use-gnuinstall-dirs.patch +++ b/0003-Use-gnuinstall-dirs.patch @@ -1,7 +1,7 @@ -From f2fd230b09b5b9304c3ef244f66099096090e802 Mon Sep 17 00:00:00 2001 +From 5fc0e63608be44350ba28708e437b9edd78edfe1 Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 17:36:48 +0100 -Subject: [PATCH 3/7] Use gnuinstall dirs +Subject: [PATCH 3/8] Use gnuinstall dirs
--- CMakeLists.txt | 8 +++++--- @@ -39,10 +39,10 @@ index b53cd11..1bde18e 100644
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 30e0b1a..b69461e 100644 +index 1a5a0a5..c062a59 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -115,6 +115,6 @@ install( +@@ -124,6 +124,6 @@ install( # DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} TARGETS morphio_shared EXPORT MorphIOTargets @@ -51,5 +51,5 @@ index 30e0b1a..b69461e 100644 PUBLIC_HEADER DESTINATION include ) -- -2.31.1 +2.35.1
diff --git a/0004-Remove-upstreams-flags.patch b/0004-Remove-upstreams-flags.patch index 96b72dc..d78b174 100644 --- a/0004-Remove-upstreams-flags.patch +++ b/0004-Remove-upstreams-flags.patch @@ -1,17 +1,17 @@ -From 692a5a4a3c02d0dda1459e79d484954bcf355e3e Mon Sep 17 00:00:00 2001 +From c83ab6302f36645170367038cf5665d67ec4d83f Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 17:37:35 +0100 -Subject: [PATCH 4/7] Remove upstreams flags +Subject: [PATCH 4/8] Remove upstreams flags
--- src/CMakeLists.txt | 11 ----------- 1 file changed, 11 deletions(-)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index b69461e..2b88434 100644 +index c062a59..626400a 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -81,17 +81,6 @@ if (MORPHIO_ENABLE_COVERAGE) +@@ -83,17 +83,6 @@ if (MORPHIO_ENABLE_COVERAGE) ) endif()
@@ -30,5 +30,5 @@ index b69461e..2b88434 100644 add_library(morphio_shared SHARED $<TARGET_OBJECTS:morphio_obj>)
-- -2.31.1 +2.35.1
diff --git a/0005-Version-soname.patch b/0005-Version-soname.patch index 7e26263..335ee9e 100644 --- a/0005-Version-soname.patch +++ b/0005-Version-soname.patch @@ -1,17 +1,17 @@ -From e82fa7c721f9a6f70312289d1dbb695e4a432f1d Mon Sep 17 00:00:00 2001 +From d9d7e75fa73aa6ffe4fac97e1401a800b828afc2 Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 18:22:22 +0100 -Subject: [PATCH 5/7] Version soname +Subject: [PATCH 5/8] Version soname
--- src/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 2b88434..bc697e8 100644 +index 626400a..6fd04c4 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -85,7 +85,8 @@ add_library(morphio_static STATIC $<TARGET_OBJECTS:morphio_obj>) +@@ -87,7 +87,8 @@ add_library(morphio_static STATIC $<TARGET_OBJECTS:morphio_obj>) add_library(morphio_shared SHARED $<TARGET_OBJECTS:morphio_obj>)
set_target_properties(morphio_shared PROPERTIES OUTPUT_NAME "morphio" @@ -22,5 +22,5 @@ index 2b88434..bc697e8 100644 target_include_directories(${TARGET} SYSTEM -- -2.31.1 +2.35.1
diff --git a/0006-Install-python-shared-object.patch b/0006-Install-python-shared-object.patch index e97f619..c638f0d 100644 --- a/0006-Install-python-shared-object.patch +++ b/0006-Install-python-shared-object.patch @@ -1,7 +1,7 @@ -From 3c913cfe0985bb8419b592a7384083a6d2869fe3 Mon Sep 17 00:00:00 2001 +From 85f3a861a56f647cc517407c3ff85eb93bed8a60 Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 18:30:26 +0100 -Subject: [PATCH 6/7] Install python shared object +Subject: [PATCH 6/8] Install python shared object
--- binds/python/CMakeLists.txt | 7 +++++++ @@ -23,5 +23,5 @@ index cab467e..13331c5 100644 + LIBRARY DESTINATION ${Python3_SITEARCH}/morphio/ +) -- -2.31.1 +2.35.1
diff --git a/0007-Stop-setup.py-from-cmake-build.patch b/0007-Stop-setup.py-from-cmake-build.patch index ca2e3fe..13ad714 100644 --- a/0007-Stop-setup.py-from-cmake-build.patch +++ b/0007-Stop-setup.py-from-cmake-build.patch @@ -1,25 +1,27 @@ -From 65614780348d5251825e5c3eb64b5b018364d24a Mon Sep 17 00:00:00 2001 +From e88f690a76287b076af775075ad4d5cd6e35f5af Mon Sep 17 00:00:00 2001 From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com Date: Tue, 20 Apr 2021 18:57:37 +0100 -Subject: [PATCH 7/7] Stop setup.py from cmake build +Subject: [PATCH 7/8] Stop setup.py from cmake build
--- - setup.py | 2 -- - 1 file changed, 2 deletions(-) + setup.py | 4 ---- + 1 file changed, 4 deletions(-)
diff --git a/setup.py b/setup.py -index b4a0eeb..4745011 100644 +index 76b3ee5..7a93246 100644 --- a/setup.py +++ b/setup.py -@@ -111,8 +111,6 @@ setup( +@@ -77,10 +77,6 @@ setup( 'docs': ['sphinx-bluebrain-theme'], }, url='https://github.com/BlueBrain/MorphIO/', -- ext_modules=[CMakeExtension('morphio._morphio')], -- cmdclass=dict(build_ext=CMakeBuild), +- ext_modules=[CMakeExtension('morphio._morphio'), +- ], +- cmdclass={'build_ext': CMakeBuild, +- }, packages=['morphio', 'morphio.mut', 'morphio.vasculature'], license="LGPLv3", - keywords=('computational neuroscience', + keywords=['computational neuroscience', -- -2.31.1 +2.35.1
diff --git a/MorphIO-3.3.0-pytests-float32.patch b/0008-pytest-float32.patch similarity index 68% rename from MorphIO-3.3.0-pytests-float32.patch rename to 0008-pytest-float32.patch index ce4a060..fc66f84 100644 --- a/MorphIO-3.3.0-pytests-float32.patch +++ b/0008-pytest-float32.patch @@ -1,7 +1,18 @@ -diff -Naur MorphIO-3.3.0-original/tests/test_1_swc.py MorphIO-3.3.0/tests/test_1_swc.py ---- MorphIO-3.3.0-original/tests/test_1_swc.py 2021-06-15 07:26:01.000000000 -0400 -+++ MorphIO-3.3.0/tests/test_1_swc.py 2021-08-30 09:17:07.049597252 -0400 -@@ -403,8 +403,8 @@ +From 1986f019954ba47b035c9dcd75be6d642d23de7c Mon Sep 17 00:00:00 2001 +From: "Ankur Sinha (Ankur Sinha Gmail)" sanjay.ankur@gmail.com +Date: Mon, 21 Feb 2022 10:22:37 +0000 +Subject: [PATCH 8/8] pytest float32 + +--- + tests/test_1_swc.py | 4 +- + tests/test_2_neurolucida.py | 86 ++++++++++++++++++------------------- + 2 files changed, 45 insertions(+), 45 deletions(-) + +diff --git a/tests/test_1_swc.py b/tests/test_1_swc.py +index b6ddc05..0d488df 100644 +--- a/tests/test_1_swc.py ++++ b/tests/test_1_swc.py +@@ -419,8 +419,8 @@ def test_read_duplicate(tmp_path): [1, 0, 0], [1, 1, 0]])) assert_array_equal(child1.diameters, np.array([1, 1])) @@ -11,11 +22,12 @@ diff -Naur MorphIO-3.3.0-original/tests/test_1_swc.py MorphIO-3.3.0/tests/test_1 + assert_array_equal(child3.diameters, np.array([1, 4.6, 7]))
- def test_unsupported_section_type(): -diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/tests/test_2_neurolucida.py ---- MorphIO-3.3.0-original/tests/test_2_neurolucida.py 2021-06-15 07:26:01.000000000 -0400 -+++ MorphIO-3.3.0/tests/test_2_neurolucida.py 2021-08-30 09:22:43.817429302 -0400 -@@ -138,10 +138,10 @@ + def test_unsupported_section_type(tmp_path): +diff --git a/tests/test_2_neurolucida.py b/tests/test_2_neurolucida.py +index daa1a3d..f4af91b 100644 +--- a/tests/test_2_neurolucida.py ++++ b/tests/test_2_neurolucida.py +@@ -178,10 +178,10 @@ def test_single_neurite_no_soma(tmp_path): assert len(n.root_sections) == 1 assert_array_equal(n.root_sections[0].points, np.array([[1.2, 2.7, 1.0], @@ -27,8 +39,8 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + np.array([13., 13.]))
- def test_skip_header(): -@@ -164,7 +164,7 @@ + def test_skip_header(tmp_path): +@@ -205,7 +205,7 @@ def test_skip_header(tmp_path): assert len(n.root_sections) == 1 assert_array_equal(n.root_sections[0].points, np.array([[1.2, 2.7, 1.0], @@ -37,7 +49,7 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test
without_duplicate = ''' -@@ -224,14 +224,14 @@ +@@ -265,14 +265,14 @@ would look like''' [0, -10, 0], [-3, -10, 0]]) assert_array_equal(n.root_sections[0].children[0].diameters, @@ -53,17 +65,17 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + np.array([2, 2, 0.3]))
- def test_read_without_duplicates(): -@@ -275,7 +275,7 @@ - ''') as tmp_file: + def test_read_without_duplicates(tmp_path): +@@ -317,7 +317,7 @@ def test_explicit_duplicates_with_arbitrary_diameter(tmp_path): + ''') as tmp_file: n = Morphology(tmp_file.name) assert_array_equal(n.root_sections[0].children[0].diameters, - np.array([20, 2, 0.3], dtype=np.float32)) + np.array([20, 2, 0.3]))
- def test_unfinished_file(): -@@ -319,14 +319,14 @@ + def test_unfinished_file(tmp_path): +@@ -363,14 +363,14 @@ def test_section_single_point(tmp_path): assert len(n.root_sections[0].children) == 2 assert_array_equal(n.root_sections[0].children[0].points, np.array([[3, -10, 0], @@ -80,18 +92,19 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + [3, -10, 2]]))
- def test_single_children(): -@@ -363,8 +363,7 @@ + def test_single_children(tmp_path): +@@ -408,8 +408,8 @@ def test_single_children(tmp_path): np.array([[3, -4, 0], [3, -6, 0], [3, -8, 0], - [3, -10, 0]], - dtype=np.float32)) -+ [3, -10, 0]])) ++ [3, -10, 0]] ++ )) assert len(n.root_sections[0].children) == 1
-@@ -378,7 +377,7 @@ +@@ -423,7 +423,7 @@ def test_spine(): [9.99, -4.00, 150.00], [11.38, -4.62, 150.00], [12.55, -5.16, 150.00], @@ -99,8 +112,8 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + [13.75, -5.96, 150.00]]))
- def test_single_point_section_duplicate_parent(): -@@ -395,7 +394,7 @@ + def test_single_point_section_duplicate_parent(tmp_path): +@@ -441,7 +441,7 @@ def test_single_point_section_duplicate_parent(tmp_path): neuron = Morphology(tmp_file.name) assert_array_equal(neuron.root_sections[0].points, [[ 3., -4., 0.], [ 3., -10., 0.]]) @@ -108,8 +121,8 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + assert_array_equal(neuron.root_sections[0].diameters, np.array([2, 2]))
- def test_single_point_section_duplicate_parent_complex(): -@@ -441,7 +440,7 @@ + def test_single_point_section_duplicate_parent_complex(tmp_path): +@@ -488,7 +488,7 @@ def test_spine(): [9.99, -4.00, 150.00], [11.38, -4.62, 150.00], [12.55, -5.16, 150.00], @@ -118,68 +131,74 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test
def test_markers(): -@@ -452,26 +451,20 @@ +@@ -499,26 +499,26 @@ def test_markers(): assert len(n.markers) == 5 assert_array_equal(n.markers[0].points, np.array([[-271.87, -121.14, -16.27], - [-269.34, -122.29, -15.48]], - dtype=np.float32)) -- assert_array_equal(n.markers[0].diameters, ++ [-269.34, -122.29, -15.48]] ++ )) + assert_array_equal(n.markers[0].diameters, - np.array([0.69, 0.69], dtype=np.float32)) -+ [-269.34, -122.29, -15.48]])) -+ assert_array_equal(n.markers[0].diameters, np.array([0.69, 0.69])) ++ np.array([0.69, 0.69])) assert n.markers[0].label == 'Cross'
assert_array_equal(n.markers[1].points, np.array([[-279.41, -119.99, -18.00], - [-272.98, -126.60, -21.22]], - dtype=np.float32)) -- assert_array_equal(n.markers[1].diameters, ++ [-272.98, -126.60, -21.22]] ++ )) + assert_array_equal(n.markers[1].diameters, - np.array([0.46, 0.92], dtype=np.float32)) -+ [-272.98, -126.60, -21.22]])) -+ assert_array_equal(n.markers[1].diameters, np.array([0.46, 0.92])) ++ np.array([0.46, 0.92])) assert n.markers[1].label == 'Cross'
assert_array_equal(n.markers[2].points, np.array([[-223.67, -157.92, -42.45], - [-222.76, -154.18, -39.90]], - dtype=np.float32)) -- assert_array_equal(n.markers[2].diameters, ++ [-222.76, -154.18, -39.90]] ++ )) + assert_array_equal(n.markers[2].diameters, - np.array([0.69, 0.69], dtype=np.float32)) -+ [-222.76, -154.18, -39.90]])) -+ assert_array_equal(n.markers[2].diameters, np.array([0.69, 0.69])) ++ np.array([0.69, 0.69])) assert n.markers[2].label == 'Cross' assert n.markers[3].label == 'INCOMPLETE' assert n.markers[3].section_id == 3 -@@ -483,34 +476,28 @@ - +@@ -531,33 +531,33 @@ def test_markers(): assert_array_equal(n.root_sections[0].points, np.array([[-290.87, -113.09, -16.32], -- [-290.87, -113.09, -16.32], + [-290.87, -113.09, -16.32], - ], - dtype=np.float32)) -+ [-290.87, -113.09, -16.32]])) ++ ] ++ ))
assert_array_equal(n.root_sections[0].children[0].points, np.array([[-290.87, -113.09, -16.32], [-277.14, -119.13, -18.02], - [-275.54, -119.99, -16.67]], - dtype=np.float32)) -+ [-275.54, -119.99, -16.67]])) ++ [-275.54, -119.99, -16.67]] ++ ))
assert_array_equal(n.root_sections[0].children[1].points, np.array([[-290.87, -113.09, -16.32], [-277.80, -120.28, -19.48], - [-276.65, -121.14, -20.20]], - dtype=np.float32)) -+ [-276.65, -121.14, -20.20]])) ++ [-276.65, -121.14, -20.20]] ++ ))
assert_array_equal(n.root_sections[0].children[1].children[0].points, np.array([[-276.65, -121.14, -20.20], [-267.94, -128.61, -22.57], - [-204.90, -157.63, -42.45]], - dtype=np.float32)) -+ [-204.90, -157.63, -42.45]])) ++ [-204.90, -157.63, -42.45]] ++ ))
assert_array_equal(n.root_sections[0].children[1].children[1].points, np.array([[-276.65, -121.14, -20.20], @@ -187,11 +206,12 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test [-268.17, -130.62, -24.75], - [-266.79, -131.77, -26.13]], - dtype=np.float32)) -+ [-266.79, -131.77, -26.13]])) ++ [-266.79, -131.77, -26.13]] ++ ))
def test_string_markers(): -@@ -523,7 +510,7 @@ +@@ -570,7 +570,7 @@ def test_string_markers(): np.array([[-2.87, -9.24, -5.06], [-2.76, -10.41, -5.13], [-2.03, -12.48, -5.13], @@ -200,7 +220,7 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test
assert len(m.markers) == 2 pia = m.markers[0] -@@ -538,8 +525,8 @@ +@@ -585,8 +585,8 @@ def test_string_markers(): assert m.markers[1].label == 'layer1-2' assert_array_equal(m.markers[1].points, np.array([[983.07, 455.36, -0.19], @@ -209,18 +229,38 @@ diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/test + [1192.31, 420.35, -0.19]])) + assert_array_equal(m.markers[1].diameters, np.array([0.15, 0.15]))
- def test_neurolucida_markers(): + def test_neurolucida_markers(tmp_path): SIMPLE = Morphology(DATA_DIR / 'simple.asc') +@@ -639,14 +639,14 @@ f''' + assert_array_equal(neuron.points, SIMPLE.points) + assert len(neuron.markers) == 2 + assert_array_almost_equal(neuron.markers[0].points, +- np.array([[81.58, -77.98, -20.32]], dtype=np.float32)) ++ np.array([[81.58, -77.98, -20.32]])) + assert_array_almost_equal(neuron.markers[0].diameters, +- np.array([0.5], dtype=np.float32)) ++ np.array([0.5])) + assert_array_almost_equal(neuron.markers[1].points, +- np.array([[51.580002, -77.779999, -24.32]], +- dtype=np.float32)) ++ np.array([[51.580002, -77.779999, -24.32]] ++ )) + assert_array_almost_equal(neuron.markers[1].diameters, +- np.array([0.52], dtype=np.float32)) ++ np.array([0.52]))
def test_invalid_incomplete(): -@@ -621,7 +607,7 @@ +@@ -669,7 +669,7 @@ def test_Sections_block():
def test_marker_with_string(): m = Morphology(DATA_DIR / 'marker-with-string.asc') - assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]], - dtype=np.float32)) -+ assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]])) -+ ++ assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]] ++ )) def test_version(): assert_array_equal(Morphology(DATA_DIR / 'simple.asc').version, ('asc', 1, 0)) +-- +2.35.1 + diff --git a/338.patch b/338.patch deleted file mode 100644 index 7ca2823..0000000 --- a/338.patch +++ /dev/null @@ -1,60 +0,0 @@ -From 7957918f64d0f19e2ffaa14265cba76008172ec9 Mon Sep 17 00:00:00 2001 -From: "Benjamin A. Beasley" code@musicinmybrain.net -Date: Fri, 3 Sep 2021 10:25:42 -0400 -Subject: [PATCH] Remove explicit template class instantiation - -Fixes an error on armv7hl like this: - - FAILED: binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so - : && /usr/bin/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g - -grecord-gcc-switches -pipe -Wall -Werror=format-security - -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS - -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong - -march=armv7-a -mfpu=vfpv3-d16 -mtune=generic-armv7-a -mabi=aapcs-linux - -mfloat-abi=hard -Wl,-z,relro -Wl,--as-needed -Wl,-z,now - -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -shared -o - binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so - binds/python/CMakeFiles/_morphio.dir/morphio.cpp.o - binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o - binds/python/CMakeFiles/_morphio.dir/bindings_utils.cpp.o - binds/python/CMakeFiles/_morphio.dir/bind_misc.cpp.o - binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o - binds/python/CMakeFiles/_morphio.dir/bind_vasculature.cpp.o -flto - src/libmorphio_static.a -lhdf5 && : - /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol - from plugin): in function `bind_mutable_module(pybind11::module&)': - (.text+0x0): multiple definition of `typeinfo name for - morphio::SectionBasemorphio::Section'; - binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from - plugin):(.text+0x0): first defined here - /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol - from plugin): in function `bind_mutable_module(pybind11::module&)': - (.text+0x0): multiple definition of `typeinfo for - morphio::SectionBasemorphio::Section'; - binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from - plugin):(.text+0x0): first defined here - -This indicates an identical explicit template instantiation appears in -more than one translation unit, which violates the C++ standard. Since -the instantiation is in a header, this occurs whenever the header is -included in more than one translation unit. GCC tends to produce an -error about this on 32-bit ARM but not on other common architectures. -See also https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608029. ---- - include/morphio/section.h | 3 --- - 1 file changed, 3 deletions(-) - -diff --git a/include/morphio/section.h b/include/morphio/section.h -index 7e5e9909c..fdf3e3694 100644 ---- a/include/morphio/section.h -+++ b/include/morphio/section.h -@@ -91,9 +91,6 @@ class Section: public SectionBase<Section> - : SectionBase(id_, properties) {} - }; - --// explicit instanciation --template class SectionBase<Section>; -- - } // namespace morphio - - std::ostream& operator<<(std::ostream& os, const morphio::Section& section); diff --git a/339.patch b/339.patch deleted file mode 100644 index 1a5bf6c..0000000 --- a/339.patch +++ /dev/null @@ -1,19 +0,0 @@ -From 3802b60066c98eda88b336d35770045c7b725722 Mon Sep 17 00:00:00 2001 -From: "Benjamin A. Beasley" code@musicinmybrain.net -Date: Fri, 3 Sep 2021 11:39:48 -0400 -Subject: [PATCH] Remove unused python mock dependency - ---- - tests/requirement_tests.txt | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/tests/requirement_tests.txt b/tests/requirement_tests.txt -index ffa835b8..4cef3a8e 100644 ---- a/tests/requirement_tests.txt -+++ b/tests/requirement_tests.txt -@@ -1,5 +1,4 @@ - h5py>=2.9.0 --mock>=2.0.0 - pytest>=6.0 - numpy>=1.14.2 - requests>=2.25.1 diff --git a/morphio.spec b/morphio.spec index 44dd699..bf98e9a 100644 --- a/morphio.spec +++ b/morphio.spec @@ -44,7 +44,7 @@ read/write one. %bcond_without sphinxdocs
Name: morphio -Version: 3.3.0 +Version: 3.3.2 Release: %autorelease Summary: A python and C++ library for reading and writing neuronal morphologies
@@ -58,7 +58,8 @@ Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz Source1: https://github.com/pybind/pybind11/archive/%%7Bp_commit%7D/pybind11-%%7Bp_sh...
# Patches -# TODO: Some of these will be sent upstream +# https://github.com/sanjayankur31/MorphIO/tree/fedora-3.3.2 +# Some sent upstream: https://github.com/BlueBrain/MorphIO/pull/293 # Do not use their compiler flags Patch0: 0001-Do-not-use-their-compiler-flags.patch # Do not let cmake use $FLAGS env var @@ -76,51 +77,7 @@ Patch6: 0007-Stop-setup.py-from-cmake-build.patch # Some Python tests are failing because “expected” results are float32 and then # promoted back to float64 for comparison with the actual results. We are not # sure why upstream is not experiencing this. -Patch7: MorphIO-3.3.0-pytests-float32.patch - -# Fix build failure on armv7hl: -# -# FAILED: binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so -# : && /usr/bin/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g -# -grecord-gcc-switches -pipe -Wall -Werror=format-security -# -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -# -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -# -march=armv7-a -mfpu=vfpv3-d16 -mtune=generic-armv7-a -mabi=aapcs-linux -# -mfloat-abi=hard -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -# -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -shared -o -# binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so -# binds/python/CMakeFiles/_morphio.dir/morphio.cpp.o -# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o -# binds/python/CMakeFiles/_morphio.dir/bindings_utils.cpp.o -# binds/python/CMakeFiles/_morphio.dir/bind_misc.cpp.o -# binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o -# binds/python/CMakeFiles/_morphio.dir/bind_vasculature.cpp.o -flto -# src/libmorphio_static.a -lhdf5 && : -# /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol -# from plugin): in function `bind_mutable_module(pybind11::module&)': -# (.text+0x0): multiple definition of `typeinfo name for -# morphio::SectionBasemorphio::Section'; -# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from -# plugin):(.text+0x0): first defined here -# /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol -# from plugin): in function `bind_mutable_module(pybind11::module&)': -# (.text+0x0): multiple definition of `typeinfo for -# morphio::SectionBasemorphio::Section'; -# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from -# plugin):(.text+0x0): first defined here -# -# This indicates an identical explicit template instantiation appears in more -# than one translation unit, which violates the C++ standard. Since the -# instantiation is in a header, this occurs whenever the header is included in -# more than one translation unit. GCC tends to produce an error about this on -# 32-bit ARM but not on other common architectures. See also -# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608029. -# -# https://github.com/BlueBrain/MorphIO/pull/338 -Patch8: https://github.com/BlueBrain/MorphIO/pull/338.patch -# Remove unused Python mock dependency -# https://github.com/BlueBrain/MorphIO/pull/339 -Patch9: https://github.com/BlueBrain/MorphIO/pull/339.patch +Patch7: 0008-pytest-float32.patch
BuildRequires: hdf5-devel BuildRequires: boost-devel @@ -203,9 +160,6 @@ This package provides documentation for %{name} %prep %autosetup -n %{pretty_name}-%{version} -p1
-# https://github.com/BlueBrain/MorphIO/pull/336 -mv CHANGLOG.md CHANGELOG.md - # Unbundle gsl-lite rm -rvf 3rdparty/GSL_LITE sed -r -i '/GSL_LITE/d' MANIFEST.in @@ -319,6 +273,7 @@ xdir="$(basename "${PWD}")" cd .. # Fetches from the Internet: k='not test_v2' +# Still fails in 3.3.2 # TODO: Is this a real problem? The answer is only slightly outside tolerances. # # > assert_array_almost_equal(neuron.markers[0].points, @@ -332,6 +287,7 @@ k='not test_v2' # E x: array([[ 81.58, -77.98, -20.32]]) # E y: array([[ 81.58, -77.98, -20.32]], dtype=float32) k="${k} and not test_neurolucida_markers" +# Still fails to 3.3.2 # TODO: Is this a real problem? The answer is only slightly outside tolerances. # # > assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]], @@ -345,7 +301,9 @@ k="${k} and not test_neurolucida_markers" # E x: array([[ -0.97, -141.17, 84.77]]) # E y: array([[ -0.97, -141.17, 84.77]], dtype=float32) k="${k} and not test_marker_with_string" -%pytest "${xdir}/tests" -k "${k}" +# TODO: pytest segfaults while writing a temporary file.. +k="${k} and not test_dendritic_spine_round_trip_empty_postsynaptic_density" +%pytest "${xdir}/tests" -k "${k}" -v %endif
diff --git a/sources b/sources index d19098b..d2288b8 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (morphio-3.3.0.tar.gz) = 2183de533437ebedd25ee16532836b323f35de2c6b1a4bed6464e00dce72d3695a715e983664955c3a59f0298675980c0825f08c5bc875a81b8dd116ddc06b6a +SHA512 (morphio-3.3.2.tar.gz) = 7ce9dcc355b9b12e3639796c449b440d86ed4c91aedd39cc0d9ae59eb0fcc31c444bacad6049cd47c311197888ad470c8b449681cba01a2e3f85ce8c125a71c5 SHA512 (pybind11-b4e5d58.tar.gz) = 596b7ee301b99031179334e35bb648f5c21507805e315e2fb2a33182ff733825be9b09c47ca0d378534cc13e5e045aa89b84e1a3bd92051b3b83b48e0f196c56
commit 520a388494ea65d021d2cce4600f83b2f3966982 Author: Ankur Sinha (Ankur Sinha Gmail) sanjay.ankur@gmail.com Date: Mon Feb 21 10:00:47 2022 +0000
chore: use rpmautospec
diff --git a/changelog b/changelog new file mode 100644 index 0000000..d06fb87 --- /dev/null +++ b/changelog @@ -0,0 +1,36 @@ +* Thu Jan 20 2022 Fedora Release Engineering releng@fedoraproject.org - 3.3.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Sun Nov 21 2021 Orion Poplawski orion@nwra.com - 3.3.0-3 +- Rebuild for hdf5 1.12.1 + +* Fri Nov 05 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-2 +- Rebuild with gsl-lite 0.40.0 + +* Wed Aug 25 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-1 +- Update to 3.3.0 +- Use cmake(…) dependencies where appropriate +- Unbundle lexertl14 +- Remove ExcludeArch on i686 and armv7hl since these are fixed in highfive (and + an additional problem on armv7hl is fixed here) +- Add license files to -doc subpackage; drop text doc files from others +- Enable Sphinx documentation (with an alternative theme) +- Use SETUPTOOLS_SCM_PRETEND_VERSION instead of a local git repo +- Enable Python tests +- Add header-only dependencies present in the public API to the -devel package + +* Thu Jul 22 2021 Fedora Release Engineering releng@fedoraproject.org - 3.0.2-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Fri Jun 04 2021 Python Maint python-maint@redhat.com - 3.0.2-2 +- Rebuilt for Python 3.10 + +* Thu Apr 22 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 +- Add excludearch because of highfive +- do not carry licenses in devel package, since it depends on the main package already + +* Wed Apr 21 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 +- Enable tests + +* Sat Apr 17 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 +- Initial build diff --git a/morphio.spec b/morphio.spec index f345594..44dd699 100644 --- a/morphio.spec +++ b/morphio.spec @@ -45,7 +45,7 @@ read/write one.
Name: morphio Version: 3.3.0 -Release: 4%{?dist} +Release: %autorelease Summary: A python and C++ library for reading and writing neuronal morphologies
# The entire source is LGPLv3 except the following, which are BSD: @@ -375,39 +375,4 @@ k="${k} and not test_marker_with_string"
%changelog -* Thu Jan 20 2022 Fedora Release Engineering releng@fedoraproject.org - 3.3.0-4 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild - -* Sun Nov 21 2021 Orion Poplawski orion@nwra.com - 3.3.0-3 -- Rebuild for hdf5 1.12.1 - -* Fri Nov 05 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-2 -- Rebuild with gsl-lite 0.40.0 - -* Wed Aug 25 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-1 -- Update to 3.3.0 -- Use cmake(…) dependencies where appropriate -- Unbundle lexertl14 -- Remove ExcludeArch on i686 and armv7hl since these are fixed in highfive (and - an additional problem on armv7hl is fixed here) -- Add license files to -doc subpackage; drop text doc files from others -- Enable Sphinx documentation (with an alternative theme) -- Use SETUPTOOLS_SCM_PRETEND_VERSION instead of a local git repo -- Enable Python tests -- Add header-only dependencies present in the public API to the -devel package - -* Thu Jul 22 2021 Fedora Release Engineering releng@fedoraproject.org - 3.0.2-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild - -* Fri Jun 04 2021 Python Maint python-maint@redhat.com - 3.0.2-2 -- Rebuilt for Python 3.10 - -* Thu Apr 22 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 -- Add excludearch because of highfive -- do not carry licenses in devel package, since it depends on the main package already - -* Wed Apr 21 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 -- Enable tests - -* Sat Apr 17 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 -- Initial build +%autochangelog
commit 06d0b94e5c0420f642735aee096e115f03bf8642 Author: Fedora Release Engineering releng@fedoraproject.org Date: Thu Jan 20 20:24:59 2022 +0000
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering releng@fedoraproject.org
diff --git a/morphio.spec b/morphio.spec index c9a79b9..f345594 100644 --- a/morphio.spec +++ b/morphio.spec @@ -45,7 +45,7 @@ read/write one.
Name: morphio Version: 3.3.0 -Release: 3%{?dist} +Release: 4%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
# The entire source is LGPLv3 except the following, which are BSD: @@ -375,6 +375,9 @@ k="${k} and not test_marker_with_string"
%changelog +* Thu Jan 20 2022 Fedora Release Engineering releng@fedoraproject.org - 3.3.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + * Sun Nov 21 2021 Orion Poplawski orion@nwra.com - 3.3.0-3 - Rebuild for hdf5 1.12.1
commit 19b33f812aa63e6061219e176aea5998da01a5ef Author: Orion Poplawski orion@nwra.com Date: Sat Nov 20 21:43:04 2021 -0700
Rebuild for hdf5 1.12.1
diff --git a/morphio.spec b/morphio.spec index 0eaaec9..c9a79b9 100644 --- a/morphio.spec +++ b/morphio.spec @@ -45,7 +45,7 @@ read/write one.
Name: morphio Version: 3.3.0 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
# The entire source is LGPLv3 except the following, which are BSD: @@ -375,6 +375,9 @@ k="${k} and not test_marker_with_string"
%changelog +* Sun Nov 21 2021 Orion Poplawski orion@nwra.com - 3.3.0-3 +- Rebuild for hdf5 1.12.1 + * Fri Nov 05 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-2 - Rebuild with gsl-lite 0.40.0
commit 87710a1011c3192c254f91949fd899627d344e9f Author: Benjamin A. Beasley code@musicinmybrain.net Date: Fri Nov 5 13:16:05 2021 -0400
Rebuild with gsl-lite 0.40.0
diff --git a/morphio.spec b/morphio.spec index fea61eb..0eaaec9 100644 --- a/morphio.spec +++ b/morphio.spec @@ -45,7 +45,7 @@ read/write one.
Name: morphio Version: 3.3.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
# The entire source is LGPLv3 except the following, which are BSD: @@ -375,6 +375,9 @@ k="${k} and not test_marker_with_string"
%changelog +* Fri Nov 05 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-2 +- Rebuild with gsl-lite 0.40.0 + * Wed Aug 25 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-1 - Update to 3.3.0 - Use cmake(…) dependencies where appropriate
commit fda4e64a55aadf5478dbbccbcd5a37ce98973185 Author: Benjamin A. Beasley code@musicinmybrain.net Date: Wed Sep 1 09:49:48 2021 -0400
Update to 3.3.0 (fix RHBZ#1956265)
- Use cmake(…) dependencies where appropriate - Unbundle lexertl14 - Remove ExcludeArch on i686 and armv7hl since these are fixed in highfive (and an additional problem on armv7hl is fixed here) - Add license files to -doc subpackage; drop text doc files from others - Enable Sphinx documentation (with an alternative theme) - Use SETUPTOOLS_SCM_PRETEND_VERSION instead of a local git repo - Enable Python tests - Add header-only dependencies present in the public API to the -devel package
diff --git a/.gitignore b/.gitignore index 10ff31c..979d507 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ /lexertl-799dbda.tar.gz /morphio-3.0.2.tar.gz /pybind11-799dbda.tar.gz +/morphio-3.3.0.tar.gz +/pybind11-b4e5d58.tar.gz diff --git a/338.patch b/338.patch new file mode 100644 index 0000000..7ca2823 --- /dev/null +++ b/338.patch @@ -0,0 +1,60 @@ +From 7957918f64d0f19e2ffaa14265cba76008172ec9 Mon Sep 17 00:00:00 2001 +From: "Benjamin A. Beasley" code@musicinmybrain.net +Date: Fri, 3 Sep 2021 10:25:42 -0400 +Subject: [PATCH] Remove explicit template class instantiation + +Fixes an error on armv7hl like this: + + FAILED: binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so + : && /usr/bin/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g + -grecord-gcc-switches -pipe -Wall -Werror=format-security + -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS + -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong + -march=armv7-a -mfpu=vfpv3-d16 -mtune=generic-armv7-a -mabi=aapcs-linux + -mfloat-abi=hard -Wl,-z,relro -Wl,--as-needed -Wl,-z,now + -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -shared -o + binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so + binds/python/CMakeFiles/_morphio.dir/morphio.cpp.o + binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o + binds/python/CMakeFiles/_morphio.dir/bindings_utils.cpp.o + binds/python/CMakeFiles/_morphio.dir/bind_misc.cpp.o + binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o + binds/python/CMakeFiles/_morphio.dir/bind_vasculature.cpp.o -flto + src/libmorphio_static.a -lhdf5 && : + /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol + from plugin): in function `bind_mutable_module(pybind11::module&)': + (.text+0x0): multiple definition of `typeinfo name for + morphio::SectionBasemorphio::Section'; + binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from + plugin):(.text+0x0): first defined here + /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol + from plugin): in function `bind_mutable_module(pybind11::module&)': + (.text+0x0): multiple definition of `typeinfo for + morphio::SectionBasemorphio::Section'; + binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from + plugin):(.text+0x0): first defined here + +This indicates an identical explicit template instantiation appears in +more than one translation unit, which violates the C++ standard. Since +the instantiation is in a header, this occurs whenever the header is +included in more than one translation unit. GCC tends to produce an +error about this on 32-bit ARM but not on other common architectures. +See also https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608029. +--- + include/morphio/section.h | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/include/morphio/section.h b/include/morphio/section.h +index 7e5e9909c..fdf3e3694 100644 +--- a/include/morphio/section.h ++++ b/include/morphio/section.h +@@ -91,9 +91,6 @@ class Section: public SectionBase<Section> + : SectionBase(id_, properties) {} + }; + +-// explicit instanciation +-template class SectionBase<Section>; +- + } // namespace morphio + + std::ostream& operator<<(std::ostream& os, const morphio::Section& section); diff --git a/339.patch b/339.patch new file mode 100644 index 0000000..1a5bf6c --- /dev/null +++ b/339.patch @@ -0,0 +1,19 @@ +From 3802b60066c98eda88b336d35770045c7b725722 Mon Sep 17 00:00:00 2001 +From: "Benjamin A. Beasley" code@musicinmybrain.net +Date: Fri, 3 Sep 2021 11:39:48 -0400 +Subject: [PATCH] Remove unused python mock dependency + +--- + tests/requirement_tests.txt | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/tests/requirement_tests.txt b/tests/requirement_tests.txt +index ffa835b8..4cef3a8e 100644 +--- a/tests/requirement_tests.txt ++++ b/tests/requirement_tests.txt +@@ -1,5 +1,4 @@ + h5py>=2.9.0 +-mock>=2.0.0 + pytest>=6.0 + numpy>=1.14.2 + requests>=2.25.1 diff --git a/MorphIO-3.3.0-pytests-float32.patch b/MorphIO-3.3.0-pytests-float32.patch new file mode 100644 index 0000000..ce4a060 --- /dev/null +++ b/MorphIO-3.3.0-pytests-float32.patch @@ -0,0 +1,226 @@ +diff -Naur MorphIO-3.3.0-original/tests/test_1_swc.py MorphIO-3.3.0/tests/test_1_swc.py +--- MorphIO-3.3.0-original/tests/test_1_swc.py 2021-06-15 07:26:01.000000000 -0400 ++++ MorphIO-3.3.0/tests/test_1_swc.py 2021-08-30 09:17:07.049597252 -0400 +@@ -403,8 +403,8 @@ + [1, 0, 0], + [1, 1, 0]])) + assert_array_equal(child1.diameters, np.array([1, 1])) +- assert_array_equal(child2.diameters, np.array([4.6, 7], dtype=np.float32)) +- assert_array_equal(child3.diameters, np.array([1, 4.6, 7], dtype=np.float32)) ++ assert_array_equal(child2.diameters, np.array([4.6, 7])) ++ assert_array_equal(child3.diameters, np.array([1, 4.6, 7])) + + + def test_unsupported_section_type(): +diff -Naur MorphIO-3.3.0-original/tests/test_2_neurolucida.py MorphIO-3.3.0/tests/test_2_neurolucida.py +--- MorphIO-3.3.0-original/tests/test_2_neurolucida.py 2021-06-15 07:26:01.000000000 -0400 ++++ MorphIO-3.3.0/tests/test_2_neurolucida.py 2021-08-30 09:22:43.817429302 -0400 +@@ -138,10 +138,10 @@ + assert len(n.root_sections) == 1 + assert_array_equal(n.root_sections[0].points, + np.array([[1.2, 2.7, 1.0], +- [1.2, 3.7, 2.0]], dtype=np.float32)) ++ [1.2, 3.7, 2.0]])) + + assert_array_equal(n.root_sections[0].diameters, +- np.array([13., 13.], dtype=np.float32)) ++ np.array([13., 13.])) + + + def test_skip_header(): +@@ -164,7 +164,7 @@ + assert len(n.root_sections) == 1 + assert_array_equal(n.root_sections[0].points, + np.array([[1.2, 2.7, 1.0], +- [1.2, 3.7, 2.0]], dtype=np.float32)) ++ [1.2, 3.7, 2.0]])) + + + without_duplicate = ''' +@@ -224,14 +224,14 @@ + [0, -10, 0], + [-3, -10, 0]]) + assert_array_equal(n.root_sections[0].children[0].diameters, +- np.array([2, 2, 0.3], dtype=np.float32)) ++ np.array([2, 2, 0.3])) + + assert_array_equal(n.root_sections[0].children[1].points, + [[3, -10, 0], + [6, -10, 0], + [9, -10, 0]]) + assert_array_equal(n.root_sections[0].children[1].diameters, +- np.array([2, 2, 0.3], dtype=np.float32)) ++ np.array([2, 2, 0.3])) + + + def test_read_without_duplicates(): +@@ -275,7 +275,7 @@ + ''') as tmp_file: + n = Morphology(tmp_file.name) + assert_array_equal(n.root_sections[0].children[0].diameters, +- np.array([20, 2, 0.3], dtype=np.float32)) ++ np.array([20, 2, 0.3])) + + + def test_unfinished_file(): +@@ -319,14 +319,14 @@ + assert len(n.root_sections[0].children) == 2 + assert_array_equal(n.root_sections[0].children[0].points, + np.array([[3, -10, 0], +- [3, -10, 2]], dtype=np.float32)) ++ [3, -10, 2]])) + assert_array_equal(n.root_sections[0].children[0].diameters, +- np.array([4, 4], dtype=np.float32)) ++ np.array([4, 4])) + + assert_array_equal(n.root_sections[0].children[1].points, + np.array([[3, -10, 0], + [3, -10, 1], +- [3, -10, 2]], dtype=np.float32)) ++ [3, -10, 2]])) + + + def test_single_children(): +@@ -363,8 +363,7 @@ + np.array([[3, -4, 0], + [3, -6, 0], + [3, -8, 0], +- [3, -10, 0]], +- dtype=np.float32)) ++ [3, -10, 0]])) + assert len(n.root_sections[0].children) == 1 + + +@@ -378,7 +377,7 @@ + [9.99, -4.00, 150.00], + [11.38, -4.62, 150.00], + [12.55, -5.16, 150.00], +- [13.75, -5.96, 150.00]], dtype=np.float32)) ++ [13.75, -5.96, 150.00]])) + + + def test_single_point_section_duplicate_parent(): +@@ -395,7 +394,7 @@ + neuron = Morphology(tmp_file.name) + assert_array_equal(neuron.root_sections[0].points, [[ 3., -4., 0.], + [ 3., -10., 0.]]) +- assert_array_equal(neuron.root_sections[0].diameters, np.array([2, 2], dtype=np.float32)) ++ assert_array_equal(neuron.root_sections[0].diameters, np.array([2, 2])) + + + def test_single_point_section_duplicate_parent_complex(): +@@ -441,7 +440,7 @@ + [9.99, -4.00, 150.00], + [11.38, -4.62, 150.00], + [12.55, -5.16, 150.00], +- [13.75, -5.96, 150.00]], dtype=np.float32)) ++ [13.75, -5.96, 150.00]])) + + + def test_markers(): +@@ -452,26 +451,20 @@ + assert len(n.markers) == 5 + assert_array_equal(n.markers[0].points, + np.array([[-271.87, -121.14, -16.27], +- [-269.34, -122.29, -15.48]], +- dtype=np.float32)) +- assert_array_equal(n.markers[0].diameters, +- np.array([0.69, 0.69], dtype=np.float32)) ++ [-269.34, -122.29, -15.48]])) ++ assert_array_equal(n.markers[0].diameters, np.array([0.69, 0.69])) + assert n.markers[0].label == 'Cross' + + assert_array_equal(n.markers[1].points, + np.array([[-279.41, -119.99, -18.00], +- [-272.98, -126.60, -21.22]], +- dtype=np.float32)) +- assert_array_equal(n.markers[1].diameters, +- np.array([0.46, 0.92], dtype=np.float32)) ++ [-272.98, -126.60, -21.22]])) ++ assert_array_equal(n.markers[1].diameters, np.array([0.46, 0.92])) + assert n.markers[1].label == 'Cross' + + assert_array_equal(n.markers[2].points, + np.array([[-223.67, -157.92, -42.45], +- [-222.76, -154.18, -39.90]], +- dtype=np.float32)) +- assert_array_equal(n.markers[2].diameters, +- np.array([0.69, 0.69], dtype=np.float32)) ++ [-222.76, -154.18, -39.90]])) ++ assert_array_equal(n.markers[2].diameters, np.array([0.69, 0.69])) + assert n.markers[2].label == 'Cross' + assert n.markers[3].label == 'INCOMPLETE' + assert n.markers[3].section_id == 3 +@@ -483,34 +476,28 @@ + + assert_array_equal(n.root_sections[0].points, + np.array([[-290.87, -113.09, -16.32], +- [-290.87, -113.09, -16.32], +- ], +- dtype=np.float32)) ++ [-290.87, -113.09, -16.32]])) + + assert_array_equal(n.root_sections[0].children[0].points, + np.array([[-290.87, -113.09, -16.32], + [-277.14, -119.13, -18.02], +- [-275.54, -119.99, -16.67]], +- dtype=np.float32)) ++ [-275.54, -119.99, -16.67]])) + + assert_array_equal(n.root_sections[0].children[1].points, + np.array([[-290.87, -113.09, -16.32], + [-277.80, -120.28, -19.48], +- [-276.65, -121.14, -20.20]], +- dtype=np.float32)) ++ [-276.65, -121.14, -20.20]])) + + assert_array_equal(n.root_sections[0].children[1].children[0].points, + np.array([[-276.65, -121.14, -20.20], + [-267.94, -128.61, -22.57], +- [-204.90, -157.63, -42.45]], +- dtype=np.float32)) ++ [-204.90, -157.63, -42.45]])) + + assert_array_equal(n.root_sections[0].children[1].children[1].points, + np.array([[-276.65, -121.14, -20.20], + [-269.77, -129.47, -22.57], + [-268.17, -130.62, -24.75], +- [-266.79, -131.77, -26.13]], +- dtype=np.float32)) ++ [-266.79, -131.77, -26.13]])) + + + def test_string_markers(): +@@ -523,7 +510,7 @@ + np.array([[-2.87, -9.24, -5.06], + [-2.76, -10.41, -5.13], + [-2.03, -12.48, -5.13], +- [-1.62, -13.30, -5.56]], dtype=np.float32)) ++ [-1.62, -13.30, -5.56]])) + + assert len(m.markers) == 2 + pia = m.markers[0] +@@ -538,8 +525,8 @@ + assert m.markers[1].label == 'layer1-2' + assert_array_equal(m.markers[1].points, + np.array([[983.07, 455.36, -0.19], +- [1192.31, 420.35, -0.19]], dtype=np.float32)) +- assert_array_equal(m.markers[1].diameters, np.array([0.15, 0.15], dtype=np.float32)) ++ [1192.31, 420.35, -0.19]])) ++ assert_array_equal(m.markers[1].diameters, np.array([0.15, 0.15])) + + def test_neurolucida_markers(): + SIMPLE = Morphology(DATA_DIR / 'simple.asc') + + + def test_invalid_incomplete(): +@@ -621,7 +607,7 @@ + + def test_marker_with_string(): + m = Morphology(DATA_DIR / 'marker-with-string.asc') +- assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]], +- dtype=np.float32)) ++ assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]])) ++ + def test_version(): + assert_array_equal(Morphology(DATA_DIR / 'simple.asc').version, ('asc', 1, 0)) diff --git a/morphio.spec b/morphio.spec index 917838f..fea61eb 100644 --- a/morphio.spec +++ b/morphio.spec @@ -19,56 +19,43 @@ analysis:
One important concept is that MorphIO is split into a read-only part and a read/write one. - }
- %global pretty_name MorphIO
-# Uses a forked version of lexertl that hasn't been updated since 2018 as a -# git-submodule, so we use this as a second source because we don't want to -# package it for independent use in Fedora. There is an issue already filed: -# https://github.com/BlueBrain/MorphIO/issues/224 -%global l_commit 799dbda2e081853161ae38051453308083188459 -%global l_shortcommit %(c=%{l_commit}; echo ${c:0:7}) - - # Include the pybind11 sources, which upstream includes as a sub-module # pybind11 documentation suggests that this is the correct way to use pybind11 # Using the Fedora pybind11-devel package does not work (or I've not been able # to figure out how to correctly patch this project to use it) # https://pybind11.readthedocs.io/en/stable/compiling.html#building-with-cmake +# +# Official support for external pybind11 requested upstream: +# https://github.com/BlueBrain/MorphIO/issues/337 %global p_commit b4e5d582cb656a590b256bcf4a8ffa7c8ce9ba19 -%global p_shortcommit %(c=%{l_commit}; echo ${c:0:7}) +%global p_shortcommit %(c=%{p_commit}; echo ${c:0:7}) +# pybind11/_version.py +%global p_version 2.4~dev4
# cpp tests %bcond_without tests # python tests -# use deprecated nose, so we only run these locally -# XXX: issue filed: https://github.com/BlueBrain/MorphIO/issues/289 -# Note 1: Some tests fail even though the comparison values are same perhaps because of different data types: -# Max absolute difference: 9.53674313e-08 -# Max relative difference: 2.07320507e-08 -# x: array([4.6, 7. ]) -# y: array([4.6, 7. ], dtype=float32) -# TODO: report test failures upstream -# Note 2: one test tries to get data from GitHub so --enable-network is required to run it -%bcond_with pytests - -# sphinx etc. doc generation requires package to be *installed*, so we skip them. -%bcond_with sphinxdocs +%bcond_without pytests + +%bcond_without sphinxdocs
Name: morphio -Version: 3.0.2 -Release: 3%{?dist} +Version: 3.3.0 +Release: 1%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
+# The entire source is LGPLv3 except the following, which are BSD: +# - 3rdparty/pybind11/ +# - CMake/CodeCoverage.cmake +# The “effective license” remains LGPLv3. License: LGPLv3 URL: https://github.com/BlueBrain/MorphIO Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz -# https://github.com/BlueBrain/MorphIO/tree/58210a667a8e8134cb56645cd6632c59b2... -Source1: https://github.com/wizmer/lexertl/archive/%%7Bl_commit%7D/lexertl-%%7Bl_shor... -Source2: https://github.com/pybind/pybind11/archive/%%7Bp_commit%7D/pybind11-%%7Bp_sh... +Source1: https://github.com/pybind/pybind11/archive/%%7Bp_commit%7D/pybind11-%%7Bp_sh...
# Patches # TODO: Some of these will be sent upstream @@ -84,33 +71,96 @@ Patch3: 0004-Remove-upstreams-flags.patch Patch4: 0005-Version-soname.patch # Add install target for the compiled python module Patch5: 0006-Install-python-shared-object.patch -# Stop setup.py from running the cmake build, we'll run it ourselves +# Stop setup.py from running the cmake build, we’ll run it ourselves Patch6: 0007-Stop-setup.py-from-cmake-build.patch +# Some Python tests are failing because “expected” results are float32 and then +# promoted back to float64 for comparison with the actual results. We are not +# sure why upstream is not experiencing this. +Patch7: MorphIO-3.3.0-pytests-float32.patch + +# Fix build failure on armv7hl: +# +# FAILED: binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so +# : && /usr/bin/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g +# -grecord-gcc-switches -pipe -Wall -Werror=format-security +# -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS +# -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong +# -march=armv7-a -mfpu=vfpv3-d16 -mtune=generic-armv7-a -mabi=aapcs-linux +# -mfloat-abi=hard -Wl,-z,relro -Wl,--as-needed -Wl,-z,now +# -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -shared -o +# binds/python/_morphio.cpython-310-arm-linux-gnueabihf.so +# binds/python/CMakeFiles/_morphio.dir/morphio.cpp.o +# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o +# binds/python/CMakeFiles/_morphio.dir/bindings_utils.cpp.o +# binds/python/CMakeFiles/_morphio.dir/bind_misc.cpp.o +# binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o +# binds/python/CMakeFiles/_morphio.dir/bind_vasculature.cpp.o -flto +# src/libmorphio_static.a -lhdf5 && : +# /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol +# from plugin): in function `bind_mutable_module(pybind11::module&)': +# (.text+0x0): multiple definition of `typeinfo name for +# morphio::SectionBasemorphio::Section'; +# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from +# plugin):(.text+0x0): first defined here +# /usr/bin/ld: binds/python/CMakeFiles/_morphio.dir/bind_mutable.cpp.o (symbol +# from plugin): in function `bind_mutable_module(pybind11::module&)': +# (.text+0x0): multiple definition of `typeinfo for +# morphio::SectionBasemorphio::Section'; +# binds/python/CMakeFiles/_morphio.dir/bind_immutable.cpp.o (symbol from +# plugin):(.text+0x0): first defined here +# +# This indicates an identical explicit template instantiation appears in more +# than one translation unit, which violates the C++ standard. Since the +# instantiation is in a header, this occurs whenever the header is included in +# more than one translation unit. GCC tends to produce an error about this on +# 32-bit ARM but not on other common architectures. See also +# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608029. +# +# https://github.com/BlueBrain/MorphIO/pull/338 +Patch8: https://github.com/BlueBrain/MorphIO/pull/338.patch +# Remove unused Python mock dependency +# https://github.com/BlueBrain/MorphIO/pull/339 +Patch9: https://github.com/BlueBrain/MorphIO/pull/339.patch
+BuildRequires: hdf5-devel BuildRequires: boost-devel %if %{with tests} BuildRequires: catch-devel %endif -BuildRequires: cmake -BuildRequires: gcc-c++ -BuildRequires: git-core -BuildRequires: gsl-lite-devel -BuildRequires: hdf5-devel -BuildRequires: highfive-devel
-# highfive Does not build on 32 bit architectures, so this package cannot build -# on them either -# Issue filed upstream: https://github.com/BlueBrain/HighFive/issues/443 -# https://bugzilla.redhat.com/show_bug.cgi?id=1952348 -ExcludeArch: %{ix86} %{arm32} +BuildRequires: gcc-c++ +BuildRequires: cmake +# Our choice: the make backend works fine too +BuildRequires: ninja-build + +# Header-only libraries; -static required by guidelines for tracking +BuildRequires: cmake(gsl-lite) +BuildRequires: gsl-lite-static +BuildRequires: cmake(highfive) +BuildRequires: highfive-static +BuildRequires: lexertl14-devel +BuildRequires: lexertl14-static +# We cannot currently figure out how to unbundle this: +#BuildRequires: cmake(pybind11) +#BuildRequires: pybind11-static +Provides: bundled(pybind11) = %{p_version}
%description %_description
+ %package devel Summary: Development files for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} Provides: %{name}-static = %{version}-%{release}
+# A gsl header is included from the public morphio/types.h header. +Requires: gsl-lite-devel%{?_isa} +Requires: gsl-lite-static +# A HighFive header is included from the public morphio/morphology.h header. +Requires: highfive-devel%{?_isa} +Requires: highfive-static +# Note that packages using this -devel package should ideally also BR +# gsl-lite-static and highfive-static for header-only library tracking.
%description devel The %{name}-devel package contains libraries and header files for @@ -122,26 +172,28 @@ Summary: Python bindings for %{name} BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: python3-setuptools_scm -Requires: %{py3_dist numpy} %if %{with pytests} # tests/requirements-tests.txt -BuildRequires: %{py3_dist h5py} -BuildRequires: %{py3_dist mock} -BuildRequires: %{py3_dist nose} -BuildRequires: %{py3_dist numpy} -BuildRequires: %{py3_dist requests} +BuildRequires: %{py3_dist h5py} >= 2.9.0 +BuildRequires: %{py3_dist pytest} >= 6.0 +BuildRequires: %{py3_dist numpy} >= 1.14.2 +BuildRequires: %{py3_dist requests} >= 2.25.1 %endif
+# Note that this package does not depend at all on the base package (it does +# not link against the shared library).
%description -n python3-%{name} This package includes the Python 3 bindings for %{name}.
+ %package doc Summary: Documentation for %{name} BuildArch: noarch %if %{with sphinxdocs} BuildRequires: %{py3_dist sphinx} -BuildRequires: doxygen graphviz +BuildRequires: doxygen +BuildRequires: graphviz %endif
%description doc @@ -149,41 +201,34 @@ This package provides documentation for %{name}
%prep -%autosetup -n %{pretty_name}-%{version} -S git - -# Use system gsl-lite -sed -i '/TARGET_PROPERTY.*gsl-lite/ d' src/CMakeLists.txt -# gsl-lite is header only, why is it linking (and how does it work?!) -sed -i 's/(target_link_libraries.*)PUBLIC gsl-lite(.*)/\1 \2/' src/CMakeLists.txt - -# Update includes -find . -type f -exec sed -i 's|<gsl/gsl>|<gsl/gsl-lite.hpp>|' '{}' ; - -# Correct the CMakeLists.txt to only look for lexertl bundled lib -# Better than patching: here we know exactly what is bundled and what isn't. -pushd 3rdparty -cat > CMakeLists.txt << EOF -find_package(HDF5 REQUIRED) - -add_library(lexertl INTERFACE) -target_include_directories(lexertl SYSTEM INTERFACE lexertl) - -if(BUILD_BINDINGS) - add_subdirectory(pybind11) - target_include_directories(pybind11 SYSTEM INTERFACE - pybind11) -endif() - -EOF -popd +%autosetup -n %{pretty_name}-%{version} -p1 + +# https://github.com/BlueBrain/MorphIO/pull/336 +mv CHANGLOG.md CHANGELOG.md + +# Unbundle gsl-lite +rm -rvf 3rdparty/GSL_LITE +sed -r -i '/GSL_LITE/d' MANIFEST.in +sed -r -i '/director.*(.*(gsl-lite|GSL_LITE).*)/d' 3rdparty/CMakeLists.txt +sed -r -i \ + -e '/TARGET_PROPERTY:gsl-lite,INTERFACE_INCLUDE_DIRECTORIES/d' \ + -e 's/PUBLIC[[:blank:]]+gsl-lite[[:blank:]]+(PRIVATE)/\1/' \ + src/CMakeLists.txt +# Update includes. Note that this affects the public API headers. +# +# The grep-then-sed pattern means we only modify those files that need it, +# preserving the mtimes on the others. +grep -ErIl '#[[:blank:]]*include[[:blank:]]+["<]gsl/gsl[">]' . | + xargs -r sed -r -i \ + 's@(#[[:blank:]]*include[[:blank:]]+["<]gsl/gsl)([">])@\1-lite.hpp\2@' + +# Unbundle lexertl +rm -rvf '3rdparty/lexertl' +ln -s '%{_includedir}/lexertl' '3rdparty/'
-# Manually include the lexertl sources -pushd 3rdparty/lexertl/ -%{__tar} --strip-components 1 -xvf %{SOURCE1} -popd # pybind11 pushd 3rdparty/pybind11/ -%{__tar} --strip-components 1 -xvf %{SOURCE2} +%{__tar} --strip-components 1 -xvf %{SOURCE1} popd
# Remove bundled catch.hpp @@ -192,74 +237,156 @@ rm -frv tests/contrib # Correct include find tests/ -type f -exec sed -i 's|"contrib/catch.hpp"|"catch2/catch.hpp"|' '{}' ;
-# setup.py uses setuptools_scm to pick version from the tag -git add . -git commit -m "Tag for SCM" -git tag %{version} +# Sphinx documentation uses sphinx-bluebrain-theme, which bundles +# mkdocs-material, which has pre-built compiled/minified JavaScript and CSS +# assets that cannot be packaged under guidelines (and the asset build pipeline +# is too complicated and “webby” to reproduce when building the RPM as would be +# required)—see https://bugzilla.redhat.com/show_bug.cgi?id=1960274#c3. +# Therefore, we change the theme, with the understanding that the documentation +# won’t appear as intended. It still seems to be generally usable. +sed -r -i 's/sphinx-bluebrain-theme/alabaster/' doc/source/conf.py + +# Some of these could make it into the installed package: +find . -type f -name .gitignore -print -delete +
%build -%if %{with tests} -%cmake -DEXTERNAL_HIGHFIVE:BOOL=TRUE -DMORPHIO_USE_DOUBLE:BOOL=TRUE -DBUILD_BINDINGS:BOOL=TRUE -DMORPHIO_TESTS:BOOL=TRUE -DMORPHIO_ENABLE_COVERAGE:BOOL=TRUE -%else -%cmake -DEXTERNAL_HIGHFIVE:BOOL=TRUE -DMORPHIO_USE_DOUBLE:BOOL=TRUE -DBUILD_BINDINGS:BOOL=TRUE -DMORPHIO_TESTS:BOOL=FALSE -DMORPHIO_ENABLE_COVERAGE:BOOL=TRUE -DMORPHIO_VERSION_STRING:STRING="%{version}" -%endif +export SETUPTOOLS_SCM_PRETEND_VERSION='%{version}' +%cmake \ + -DEXTERNAL_HIGHFIVE:BOOL=TRUE \ + -DMORPHIO_USE_DOUBLE:BOOL=TRUE \ + -DBUILD_BINDINGS:BOOL=TRUE \ + -DMORPHIO_TESTS:BOOL=%{?with_tests:TRUE}%{?!with_tests:FALSE} \ + -DMORPHIO_ENABLE_COVERAGE:BOOL=TRUE \ + -DMORPHIO_VERSION_STRING:STRING="%{version}" \ + -GNinja %cmake_build
# Build pure python bits %py3_build
%if %{with sphinxdocs} -pushd doc -PYTHONPATH=../build/lib/ sphinx-build-%{python3_version} source build -popd +( + # Temporary local installation so we can reliably import the Cython extension + # module to build documentation. + # + # A similar approach would work even with pyproject-rpm-macros; see + # https://src.fedoraproject.org/rpms/python-asyncpg for an example, and + # https://lists.fedoraproject.org/archives/list/ + # python-devel@lists.fedoraproject.org/message/ + # TRPRWUR4XCDSZ64RNWYVCH636CT4VHAT/ + # for alternatives. + PYTEMP="${PWD}/%{_vpath_builddir}/pytemp" + export PYTHONPATH="${PYTEMP}%{python3_sitearch}:${PYTEMP}%{python3_sitelib}" + + %{__python3} %{py_setup} %{?py_setup_args} install \ + -O1 --skip-build --root "${PYTEMP}" + + %make_build -C doc html SPHINXOPTS='%{?_smp_mflags}' + rm -vf doc/build/html/.buildinfo + + rm -rf "${PYTEMP}" +) %endif
+ %install +export SETUPTOOLS_SCM_PRETEND_VERSION='%{version}' %cmake_install - # Install pure python bits %py3_install
-# Move module to sitearch so that the binding can be correctly imported -mv -v $RPM_BUILD_ROOT/%{python3_sitelib}/%{name}/* $RPM_BUILD_ROOT/%{python3_sitearch}/%{name} -mv -v $RPM_BUILD_ROOT/%{python3_sitelib}/%{pretty_name}* $RPM_BUILD_ROOT/%{python3_sitearch}/ +# Move module to sitearch so that the binding can be correctly imported. +if [ '%{python3_sitelib}' != '%{python3_sitearch}' ] +then + mv -v $RPM_BUILD_ROOT/%{python3_sitelib}/%{name}/* \ + $RPM_BUILD_ROOT/%{python3_sitearch}/%{name} + mv -v $RPM_BUILD_ROOT/%{python3_sitelib}/%{pretty_name}* \ + $RPM_BUILD_ROOT/%{python3_sitearch}/ +fi +
%check +export SETUPTOOLS_SCM_PRETEND_VERSION='%{version}' %if %{with tests} # From ci/cpp_test.sh %ctest %endif %if %{with pytests} -# Remove src folder so that it doesn't try to import it -rm -rf %{name} +# We will change directories so that the “un-built” package is not imported +xdir="$(basename "${PWD}")" # From ci/python_test.sh -PYTHONPATH=$PYTHONPATH:$RPM_BUILD_ROOT/%{python3_sitelib}:$RPM_BUILD_ROOT/%{python3_sitearch} nosetests -P tests/ +cd .. +# Fetches from the Internet: +k='not test_v2' +# TODO: Is this a real problem? The answer is only slightly outside tolerances. +# +# > assert_array_almost_equal(neuron.markers[0].points, +# np.array([[81.58, -77.98, -20.32]], dtype=np.float32)) +# E AssertionError: +# E Arrays are not almost equal to 6 decimals +# E +# E Mismatched elements: 2 / 3 (66.7%) +# E Max absolute difference: 3.35693359e-06 +# E Max relative difference: 4.30486464e-08 +# E x: array([[ 81.58, -77.98, -20.32]]) +# E y: array([[ 81.58, -77.98, -20.32]], dtype=float32) +k="${k} and not test_neurolucida_markers" +# TODO: Is this a real problem? The answer is only slightly outside tolerances. +# +# > assert_array_equal(m.markers[0].points, np.array([[ -0.97 , -141.169998, 84.769997]], +# dtype=np.float32)) +# E AssertionError: +# E Arrays are not equal +# E +# E Mismatched elements: 3 / 3 (100%) +# E Max absolute difference: 3.35693359e-06 +# E Max relative difference: 3.96004922e-08 +# E x: array([[ -0.97, -141.17, 84.77]]) +# E y: array([[ -0.97, -141.17, 84.77]], dtype=float32) +k="${k} and not test_marker_with_string" +%pytest "${xdir}/tests" -k "${k}" %endif
+ %files %license COPYING COPYING.LESSER -%doc CHANGLOG.md CONTRIBUTING.md README.rst %{_libdir}/libmorphio.so.0.0.0
+ %files devel -%doc CHANGLOG.md CONTRIBUTING.md README.rst %{_includedir}/%{name} %{_libdir}/libmorphio.so %{_libdir}/cmake/%{pretty_name}
+ %files -n python3-%{name} %license COPYING COPYING.LESSER -%doc CHANGLOG.md CONTRIBUTING.md README.rst %{python3_sitearch}/%{name} %{python3_sitearch}/%{pretty_name}-%{version}-py%{python3_version}.egg-info
+ %files doc -%doc CHANGLOG.md CONTRIBUTING.md README.rst examples +%license COPYING COPYING.LESSER +%doc CHANGELOG.md CONTRIBUTING.md README.rst examples %if %{with sphinxdocs} %doc doc/build/html %endif
+ %changelog +* Wed Aug 25 2021 Benjamin A. Beasley code@musicinmybrain.net - 3.3.0-1 +- Update to 3.3.0 +- Use cmake(…) dependencies where appropriate +- Unbundle lexertl14 +- Remove ExcludeArch on i686 and armv7hl since these are fixed in highfive (and + an additional problem on armv7hl is fixed here) +- Add license files to -doc subpackage; drop text doc files from others +- Enable Sphinx documentation (with an alternative theme) +- Use SETUPTOOLS_SCM_PRETEND_VERSION instead of a local git repo +- Enable Python tests +- Add header-only dependencies present in the public API to the -devel package + * Thu Jul 22 2021 Fedora Release Engineering releng@fedoraproject.org - 3.0.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
diff --git a/sources b/sources index adc766b..d19098b 100644 --- a/sources +++ b/sources @@ -1,3 +1,2 @@ -SHA512 (lexertl-799dbda.tar.gz) = 6b6e67ff3e48273aa5fa383bdbcccae08823b8f3a1ec863952b4f80eddf4c9276cea689920fca8bbfd76e1258bb6c9a9fd3373b311f2114514fc13ecb4fee0d6 -SHA512 (morphio-3.0.2.tar.gz) = 55f5dbca2f8b0817bf06e8c702ea4d9877d633bcd5cea48c2248ef4e354a182ae731f2c802f4dcbab70e34f03e3a840f35130433b7e9527f9f24c392411695bc -SHA512 (pybind11-799dbda.tar.gz) = 596b7ee301b99031179334e35bb648f5c21507805e315e2fb2a33182ff733825be9b09c47ca0d378534cc13e5e045aa89b84e1a3bd92051b3b83b48e0f196c56 +SHA512 (morphio-3.3.0.tar.gz) = 2183de533437ebedd25ee16532836b323f35de2c6b1a4bed6464e00dce72d3695a715e983664955c3a59f0298675980c0825f08c5bc875a81b8dd116ddc06b6a +SHA512 (pybind11-b4e5d58.tar.gz) = 596b7ee301b99031179334e35bb648f5c21507805e315e2fb2a33182ff733825be9b09c47ca0d378534cc13e5e045aa89b84e1a3bd92051b3b83b48e0f196c56
commit 198c5b724cac1b9a0319e6763b22c780b74ef924 Author: Fedora Release Engineering releng@fedoraproject.org Date: Thu Jul 22 15:22:25 2021 +0000
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering releng@fedoraproject.org
diff --git a/morphio.spec b/morphio.spec index b4d0cca..917838f 100644 --- a/morphio.spec +++ b/morphio.spec @@ -60,7 +60,7 @@ read/write one.
Name: morphio Version: 3.0.2 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
License: LGPLv3 @@ -260,6 +260,9 @@ PYTHONPATH=$PYTHONPATH:$RPM_BUILD_ROOT/%{python3_sitelib}:$RPM_BUILD_ROOT/%{pyth %endif
%changelog +* Thu Jul 22 2021 Fedora Release Engineering releng@fedoraproject.org - 3.0.2-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + * Fri Jun 04 2021 Python Maint python-maint@redhat.com - 3.0.2-2 - Rebuilt for Python 3.10
commit 72572552ce4e428ef0b008e02f43c2151e8f7b1b Author: Python Maint python-maint@redhat.com Date: Fri Jun 4 20:12:08 2021 +0200
Rebuilt for Python 3.10
diff --git a/morphio.spec b/morphio.spec index 4ec4a09..b4d0cca 100644 --- a/morphio.spec +++ b/morphio.spec @@ -60,7 +60,7 @@ read/write one.
Name: morphio Version: 3.0.2 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A python and C++ library for reading and writing neuronal morphologies
License: LGPLv3 @@ -260,6 +260,9 @@ PYTHONPATH=$PYTHONPATH:$RPM_BUILD_ROOT/%{python3_sitelib}:$RPM_BUILD_ROOT/%{pyth %endif
%changelog +* Fri Jun 04 2021 Python Maint python-maint@redhat.com - 3.0.2-2 +- Rebuilt for Python 3.10 + * Thu Apr 22 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 3.0.2-1 - Add excludearch because of highfive - do not carry licenses in devel package, since it depends on the main package already