diff --git a/vtk.changes b/vtk.changes index e0cf3a5..70382cc 100644 --- a/vtk.changes +++ b/vtk.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Mon Apr 27 11:00:45 UTC 2020 - Atri Bhattacharya + +- Fix serial builds broken due to disabling the building of + examples; instead of commenting out sections of the specfile + related to examples, use %bcond_with to disable building + examples by default and the corresponding conditionals where + appropriate. + ------------------------------------------------------------------- Sun Apr 26 04:21:40 UTC 2020 - Bernhard Wiedemann diff --git a/vtk.spec b/vtk.spec index fb72eb3..891eac9 100644 --- a/vtk.spec +++ b/vtk.spec @@ -18,6 +18,10 @@ %global flavor @BUILD_FLAVOR@%{nil} +# FIXME: ENABLE EXAMPLES BY DEFAULT WHEN VERSION 9.0 IS PACKAGED +# [https://gitlab.kitware.com/vtk/vtk/issues/17619] +%bcond_with examples + %if 0%{?sle_version} >= 150200 %define DisOMPI1 ExclusiveArch: do_not_build %endif @@ -381,7 +385,7 @@ export CXXFLAGS="%{optflags}" # since JDK8. %cmake \ -DBUILD_DOCUMENTATION:BOOL=ON \ - -DBUILD_EXAMPLES:BOOL=OFF \ + -DBUILD_EXAMPLES:BOOL=%{?with_examples:ON}%{!?with_examples:OFF} \ -DBUILD_TESTING:BOOL=OFF \ -DCMAKE_NO_BUILTIN_CHRPATH:BOOL=ON \ -DJava_JAVAH_EXECUTABLE:PATH=%{_bindir}/true \ @@ -433,6 +437,7 @@ find . -name \*.c -o -name \*.cxx -o -name \*.h -o -name \*.hxx -o -name \*.gif %install %cmake_install +%if %{with examples} # List of executable examples cat > examples.list << EOF AmbientSpheres @@ -484,6 +489,8 @@ done perl -pi -e's,^,%{my_bindir}/,' examples.list %endif +%endif + %fdupes -s %{buildroot} %check @@ -563,10 +570,11 @@ find %{buildroot} . -name vtk.cpython-3*.pyc -delete # drop unreproducible time- %dir %{my_libdir}/qt5/plugins/designer/ %{my_libdir}/qt5/plugins/designer/libQVTKWidgetPlugin.so -# FIXME: UNCOMMENT WHEN VERSION 9.0 IS PACKAGED [https://gitlab.kitware.com/vtk/vtk/issues/17619] -#%%if "%%{flavor}" == "" -#%%files examples -f examples.list -#%%license Copyright.txt -#%%endif +%if %{with examples} +%if "%{flavor}" == "" +%files examples -f examples.list +%license Copyright.txt +%endif +%endif %changelog