From a6af48d842146d49a27f9f41ec8be04ddd83e6148c57c3500092790e1d504df2 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Mon, 2 Apr 2018 14:52:00 +0000 Subject: [PATCH] Accepting request 591758 from home:StefanBruens:branches:graphics - Build with PHP5 for Leap 42.x and earlier, PHP7 requires swig 3.0.11 Drop graphviz-plugins-fix_install_dirs.patch, use sed script to fix directories, same as for Lua - Do not delete dotty/lefty/lneato man pages which are part of the x11 subpackage, built from the addons package/spec. (No changelog entry). - Build with PHP5 for Leap 42.x and earlier, PHP7 requires swig 3.0.11 Drop graphviz-plugins-fix_install_dirs.patch, use sed script to fix directories, same as for Lua - Do not delete dotty/lefty/lneato man pages which are part of the x11 subpackage, built from the addons package/spec. (No changelog entry). OBS-URL: https://build.opensuse.org/request/show/591758 OBS-URL: https://build.opensuse.org/package/show/graphics/graphviz?expand=0&rev=129 --- graphviz-addons.changes | 14 ++++++++ graphviz-addons.spec | 28 ++++++++++------ graphviz-plugins-fix_install_dirs.patch | 44 ------------------------- graphviz.changes | 14 ++++++++ graphviz.spec | 28 ++++++++++------ 5 files changed, 64 insertions(+), 64 deletions(-) delete mode 100644 graphviz-plugins-fix_install_dirs.patch diff --git a/graphviz-addons.changes b/graphviz-addons.changes index bbf25ba..65e508f 100644 --- a/graphviz-addons.changes +++ b/graphviz-addons.changes @@ -1,3 +1,17 @@ +------------------------------------------------------------------- +Tue Mar 27 20:12:49 UTC 2018 - stefan.bruens@rwth-aachen.de + +- Build with PHP5 for Leap 42.x and earlier, PHP7 requires swig 3.0.11 + Drop graphviz-plugins-fix_install_dirs.patch, use sed script to + fix directories, same as for Lua + +------------------------------------------------------------------- +Tue Mar 27 19:53:42 UTC 2018 - stefan.bruens@rwth-aachen.de + +- Do not delete dotty/lefty/lneato man pages which are part of + the x11 subpackage, built from the addons package/spec. + (No changelog entry). + ------------------------------------------------------------------- Sat Feb 10 17:36:20 UTC 2018 - stefan.bruens@rwth-aachen.de diff --git a/graphviz-addons.spec b/graphviz-addons.spec index f96bff9..e69e220 100644 --- a/graphviz-addons.spec +++ b/graphviz-addons.spec @@ -26,6 +26,12 @@ # Java and ocaml are not in ring1, thus this gets overriden in staging %bcond_without java %bcond_with ocaml +# PHP7 requires swig >= 3.0.11, not available on Leap 42.x +%if 0%{?suse_version} >= 1500 +%define php_version 7 +%else +%define php_version 5 +%endif Name: graphviz-addons Version: 2.40.1 Release: 0 @@ -44,7 +50,6 @@ Patch2: graphviz-fix-pkgIndex.patch Patch3: graphviz-array_overflow.patch #PATCH-FIX-UPSTREAM Make build reproducible - merged in next release Patch4: reproducible.patch -Patch5: graphviz-plugins-fix_install_dirs.patch Patch6: graphviz-2.20.2-interpreter_names.patch #PATCH-FIX-UPSTREAM Don't warn about harmless issues with swig generated code Patch7: graphviz-useless_warnings.patch @@ -67,9 +72,14 @@ BuildRequires: freeglut-devel BuildRequires: libjpeg-devel BuildRequires: libpng-devel BuildRequires: perl +%if 0%{?suse_version} >= 1500 BuildRequires: php7-devel -BuildRequires: ruby-devel +BuildRequires: swig >= 3.0.11 +%else +BuildRequires: php5-devel BuildRequires: swig +%endif +BuildRequires: ruby-devel BuildRequires: pkgconfig(Qt5Core) BuildRequires: pkgconfig(Qt5PrintSupport) BuildRequires: pkgconfig(Qt5Widgets) @@ -211,7 +221,7 @@ tools. Summary: PHP Extension for Graphviz Group: Productivity/Graphics/Visualization/Graph Requires: graphviz = %{version} -Requires: php7 +Requires: php%{php_version} %description -n graphviz-php The graphviz-php package contains the PHP extension for the graphviz @@ -293,7 +303,6 @@ programs that use the graphviz libraries including man3 pages. %patch2 %patch3 %patch4 -p1 -%patch5 %patch6 %patch7 %patch8 @@ -303,9 +312,11 @@ sed "s/guile-2.0/guile-2.2/" -i configure.ac rm -f contrib/gprof2dot.awk -# Fix path for lua install +# Fix path for lua/php install sed -i \ -e 's@LUA_INSTALL_DIR="/usr.*@LUA_INSTALL_DIR=%{lua_archdir}@' \ + -e 's@\(PHP_INSTALL_DIR=.*\)/php/modules@\1/php%{php_version}/extensions@' \ + -e 's@\(PHP_INSTALL_DATADIR=.*\)/php@\1/php%{php_version}@' \ configure.ac %build @@ -389,9 +400,6 @@ rm -rf %{buildroot}%{_includedir} rm -rf %{buildroot}%{_datadir}/graphviz/examples rm -rf %{buildroot}%{_datadir}/graphviz/graphs rm -rf %{buildroot}%{_datadir}/graphviz/gvpr -rm -f %{buildroot}%{_mandir}/man1/dotty*1* -rm -f %{buildroot}%{_mandir}/man1/lefty*1* -rm -f %{buildroot}%{_mandir}/man1/lneato*1* rm -f %{buildroot}%{_mandir}/man3/*.3 rm -f %{buildroot}%{_mandir}/man7/*.7 rm -f %{buildroot}%{_libdir}/graphviz/%{config_file} @@ -526,8 +534,8 @@ fi %{_mandir}/man3/gv.3perl%{ext_man} %files -n graphviz-php -%{_libdir}/php7/extensions/gv.so -%{_datadir}/php7/gv.php +%{_libdir}/php%{php_version}/extensions/gv.so +%{_datadir}/php%{php_version}/gv.php %{_mandir}/man3/gv.3php%{ext_man} %files -n graphviz-python diff --git a/graphviz-plugins-fix_install_dirs.patch b/graphviz-plugins-fix_install_dirs.patch deleted file mode 100644 index 5c11f26..0000000 --- a/graphviz-plugins-fix_install_dirs.patch +++ /dev/null @@ -1,44 +0,0 @@ ---- - configure | 6 +++--- - configure.ac | 4 ++-- - 2 files changed, 5 insertions(+), 5 deletions(-) - -Index: configure -=================================================================== ---- configure.orig -+++ configure -@@ -22158,8 +22158,8 @@ test -n "$PHP" || PHP="php" - PHP_INCLUDES="-I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib" - fi - fi -- PHP_INSTALL_DIR="/usr/lib${LIBPOSTFIX}/php/modules" -- PHP_INSTALL_DATADIR="/usr/share/php" -+ PHP_INSTALL_DIR="/usr/lib${LIBPOSTFIX}/php7/extensions" -+ PHP_INSTALL_DATADIR="/usr/share/php7" - PHP_LIBS= - save_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS $PHP_INCLUDES" -@@ -23834,7 +23834,7 @@ $as_echo "using $TCLCONFIG" >&6; } - $as_echo "$as_me: WARNING: Unable to find tclConfig.sh. The Tcl packages will not be built" >&2;} - use_tcl="No (missing tclConfig.sh)" - fi -- TCL_INSTALL_DIR="${TCLSH_EXEC_PREFIX}/lib${LIBPOSTFIX}/tcl${TCL_VERSION_FOUND}" -+ TCL_INSTALL_DIR="${TCLSH_EXEC_PREFIX}/lib${LIBPOSTFIX} - fi - - if test "x$use_tcl" = "x"; then -Index: configure.ac -=================================================================== ---- configure.ac.orig -+++ configure.ac -@@ -1102,8 +1102,8 @@ else - PHP_INCLUDES="-I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib" - fi - fi -- PHP_INSTALL_DIR="/usr/lib${LIBPOSTFIX}/php/modules" -- PHP_INSTALL_DATADIR="/usr/share/php" -+ PHP_INSTALL_DIR="/usr/lib${LIBPOSTFIX}/php7/extensions" -+ PHP_INSTALL_DATADIR="/usr/share/php7" - PHP_LIBS= - save_CPPFLAGS=$CPPFLAGS - CPPFLAGS="$CPPFLAGS $PHP_INCLUDES" diff --git a/graphviz.changes b/graphviz.changes index bbf25ba..65e508f 100644 --- a/graphviz.changes +++ b/graphviz.changes @@ -1,3 +1,17 @@ +------------------------------------------------------------------- +Tue Mar 27 20:12:49 UTC 2018 - stefan.bruens@rwth-aachen.de + +- Build with PHP5 for Leap 42.x and earlier, PHP7 requires swig 3.0.11 + Drop graphviz-plugins-fix_install_dirs.patch, use sed script to + fix directories, same as for Lua + +------------------------------------------------------------------- +Tue Mar 27 19:53:42 UTC 2018 - stefan.bruens@rwth-aachen.de + +- Do not delete dotty/lefty/lneato man pages which are part of + the x11 subpackage, built from the addons package/spec. + (No changelog entry). + ------------------------------------------------------------------- Sat Feb 10 17:36:20 UTC 2018 - stefan.bruens@rwth-aachen.de diff --git a/graphviz.spec b/graphviz.spec index 145f981..779d1c6 100644 --- a/graphviz.spec +++ b/graphviz.spec @@ -26,6 +26,12 @@ # Java and ocaml are not in ring1, thus this gets overriden in staging %bcond_without java %bcond_with ocaml +# PHP7 requires swig >= 3.0.11, not available on Leap 42.x +%if 0%{?suse_version} >= 1500 +%define php_version 7 +%else +%define php_version 5 +%endif Name: graphviz Version: 2.40.1 Release: 0 @@ -44,7 +50,6 @@ Patch2: graphviz-fix-pkgIndex.patch Patch3: graphviz-array_overflow.patch #PATCH-FIX-UPSTREAM Make build reproducible - merged in next release Patch4: reproducible.patch -Patch5: graphviz-plugins-fix_install_dirs.patch Patch6: graphviz-2.20.2-interpreter_names.patch #PATCH-FIX-UPSTREAM Don't warn about harmless issues with swig generated code Patch7: graphviz-useless_warnings.patch @@ -67,9 +72,14 @@ BuildRequires: freeglut-devel BuildRequires: libjpeg-devel BuildRequires: libpng-devel BuildRequires: perl +%if 0%{?suse_version} >= 1500 BuildRequires: php7-devel -BuildRequires: ruby-devel +BuildRequires: swig >= 3.0.11 +%else +BuildRequires: php5-devel BuildRequires: swig +%endif +BuildRequires: ruby-devel BuildRequires: pkgconfig(Qt5Core) BuildRequires: pkgconfig(Qt5PrintSupport) BuildRequires: pkgconfig(Qt5Widgets) @@ -211,7 +221,7 @@ tools. Summary: PHP Extension for Graphviz Group: Productivity/Graphics/Visualization/Graph Requires: graphviz = %{version} -Requires: php7 +Requires: php%{php_version} %description -n graphviz-php The graphviz-php package contains the PHP extension for the graphviz @@ -293,7 +303,6 @@ programs that use the graphviz libraries including man3 pages. %patch2 %patch3 %patch4 -p1 -%patch5 %patch6 %patch7 %patch8 @@ -303,9 +312,11 @@ sed "s/guile-2.0/guile-2.2/" -i configure.ac rm -f contrib/gprof2dot.awk -# Fix path for lua install +# Fix path for lua/php install sed -i \ -e 's@LUA_INSTALL_DIR="/usr.*@LUA_INSTALL_DIR=%{lua_archdir}@' \ + -e 's@\(PHP_INSTALL_DIR=.*\)/php/modules@\1/php%{php_version}/extensions@' \ + -e 's@\(PHP_INSTALL_DATADIR=.*\)/php@\1/php%{php_version}@' \ configure.ac %build @@ -389,9 +400,6 @@ rm -rf %{buildroot}%{_includedir} rm -rf %{buildroot}%{_datadir}/graphviz/examples rm -rf %{buildroot}%{_datadir}/graphviz/graphs rm -rf %{buildroot}%{_datadir}/graphviz/gvpr -rm -f %{buildroot}%{_mandir}/man1/dotty*1* -rm -f %{buildroot}%{_mandir}/man1/lefty*1* -rm -f %{buildroot}%{_mandir}/man1/lneato*1* rm -f %{buildroot}%{_mandir}/man3/*.3 rm -f %{buildroot}%{_mandir}/man7/*.7 rm -f %{buildroot}%{_libdir}/graphviz/%{config_file} @@ -526,8 +534,8 @@ fi %{_mandir}/man3/gv.3perl%{ext_man} %files -n graphviz-php -%{_libdir}/php7/extensions/gv.so -%{_datadir}/php7/gv.php +%{_libdir}/php%{php_version}/extensions/gv.so +%{_datadir}/php%{php_version}/gv.php %{_mandir}/man3/gv.3php%{ext_man} %files -n graphviz-python