From dd1993c8721fec246d3fd208e87025b35ea1da89 Mon Sep 17 00:00:00 2001 From: yopito Date: Sun, 28 Jun 2020 17:19:25 +0200 Subject: [PATCH 1/3] coin3: update to 4.0.0 --- common/shlibs | 2 +- srcpkgs/coin3/patches/0005-gcc-4.7.patch | 28 -------- .../coin3/patches/0010-GCC-4.8.0-fixes.patch | 40 ----------- .../0012-memhandler-initialization.patch | 22 ------ srcpkgs/coin3/patches/fix-missing-deref.patch | 20 ------ srcpkgs/coin3/patches/no-cpack.patch | 8 +++ srcpkgs/coin3/template | 69 ++++++------------- srcpkgs/coin3/update | 1 - 8 files changed, 30 insertions(+), 160 deletions(-) delete mode 100644 srcpkgs/coin3/patches/0005-gcc-4.7.patch delete mode 100644 srcpkgs/coin3/patches/0010-GCC-4.8.0-fixes.patch delete mode 100644 srcpkgs/coin3/patches/0012-memhandler-initialization.patch delete mode 100644 srcpkgs/coin3/patches/fix-missing-deref.patch create mode 100644 srcpkgs/coin3/patches/no-cpack.patch delete mode 100644 srcpkgs/coin3/update diff --git a/common/shlibs b/common/shlibs index a1abc82974e..4574d182d08 100644 --- a/common/shlibs +++ b/common/shlibs @@ -2715,7 +2715,7 @@ libKF5DNSSD.so.5 kdnssd-5.26.0_1 libtwaindsm.so.2 twaindsm-2.3.0_1 libspnav.so.0 libspnav-0.2.3_1 libsimage.so.20 simage-1.7.0_1 -libCoin.so.60 coin3-3.1.3_1 +libCoin.so.80 coin3-4.0.0_1 libgl2ps.so.1 gl2ps-1.3.9_1 libFWOSPlugin.so.11 oce-0.18_1 libPTKernel.so.11 oce-0.18_1 diff --git a/srcpkgs/coin3/patches/0005-gcc-4.7.patch b/srcpkgs/coin3/patches/0005-gcc-4.7.patch deleted file mode 100644 index e2d16652445..00000000000 --- a/srcpkgs/coin3/patches/0005-gcc-4.7.patch +++ /dev/null @@ -1,28 +0,0 @@ -Source: http://pkgs.fedoraproject.org/cgit/rpms/Coin3.git/plain/0005-gcc-4.7.patch - -From a5bf6656215837a9bdf4d70cdce4be0fedd522e0 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Ralf=20Cors=C3=A9pius?= -Date: Fri, 4 May 2012 13:30:20 +0200 -Subject: [PATCH 05/10] gcc-4.7. - ---- - include/Inventor/SbBasic.h | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/include/Inventor/SbBasic.h b/include/Inventor/SbBasic.h -index d038bb1..2ee6b70 100644 ---- a/include/Inventor/SbBasic.h -+++ b/include/Inventor/SbBasic.h -@@ -25,6 +25,9 @@ - \**************************************************************************/ - - #include -+#ifndef NDEBUG -+#include -+#endif // !NDEBUG - - /* ********************************************************************** */ - /* Trap people trying to use Inventor headers while compiling C source code. --- -1.8.1.4 - diff --git a/srcpkgs/coin3/patches/0010-GCC-4.8.0-fixes.patch b/srcpkgs/coin3/patches/0010-GCC-4.8.0-fixes.patch deleted file mode 100644 index bc5167e8f13..00000000000 --- a/srcpkgs/coin3/patches/0010-GCC-4.8.0-fixes.patch +++ /dev/null @@ -1,40 +0,0 @@ -Source: http://pkgs.fedoraproject.org/cgit/rpms/Coin3.git/plain/0010-GCC-4.8.0-fixes.patch - -From 9f5d96a2b9a71ab539237d2dab4c54fc46fc5c5b Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Ralf=20Cors=C3=A9pius?= -Date: Thu, 18 Apr 2013 19:17:06 +0200 -Subject: [PATCH 10/10] GCC-4.8.0 fixes - ---- - src/fonts/freetype.cpp | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/src/fonts/freetype.cpp b/src/fonts/freetype.cpp -index 760b88b..e705d3a 100644 ---- a/src/fonts/freetype.cpp -+++ b/src/fonts/freetype.cpp -@@ -32,18 +32,18 @@ - - 20050613 mortene. */ - --#include "fonts/freetype.h" -- - #ifdef HAVE_CONFIG_H - #include "config.h" - #endif /* HAVE_CONFIG_H */ - --#include -+#include - #include - - #include "glue/freetype.h" - #include "glue/GLUWrapper.h" - -+#include "fonts/freetype.h" -+ - /* ************************************************************************* */ - - #ifdef __cplusplus --- -1.8.1.4 - diff --git a/srcpkgs/coin3/patches/0012-memhandler-initialization.patch b/srcpkgs/coin3/patches/0012-memhandler-initialization.patch deleted file mode 100644 index 7ad4dc68116..00000000000 --- a/srcpkgs/coin3/patches/0012-memhandler-initialization.patch +++ /dev/null @@ -1,22 +0,0 @@ -Source: http://pkgs.fedoraproject.org/cgit/rpms/Coin3.git/plain/0012-memhandler-initialization.patch -Additional information: https://bugzilla.redhat.com/show_bug.cgi?id=1323159 ---- Coin-3.1.3/src/misc/SbHash.h.init 2010-03-02 22:20:09.000000000 +0900 -+++ Coin-3.1.3/src/misc/SbHash.h 2016-04-22 16:52:39.888883757 +0900 -@@ -89,6 +89,8 @@ - cc_memalloc_deallocate(entry->memhandler, ptr); - } - SbHashEntry(const Key & key, const Type & obj) : key(key), obj(obj) {} -+ SbHashEntry(const Key & key, const Type & obj, cc_memalloc *memhandler) -+ : key(key), obj(obj), memhandler(memhandler) {} - - Key key; - Type obj; -@@ -218,7 +220,7 @@ - /* Key not already in the hash table; insert a new - * entry as the first element in the bucket - */ -- entry = new (this->memhandler) SbHashEntry(key, obj); -+ entry = new (this->memhandler) SbHashEntry(key, obj, this->memhandler); - entry->next = this->buckets[i]; - this->buckets[i] = entry; - diff --git a/srcpkgs/coin3/patches/fix-missing-deref.patch b/srcpkgs/coin3/patches/fix-missing-deref.patch deleted file mode 100644 index 8c50078b8b7..00000000000 --- a/srcpkgs/coin3/patches/fix-missing-deref.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- ./src/3ds/SoStream.cpp.orig 2018-01-16 11:18:58.965420684 +0100 -+++ ./src/3ds/SoStream.cpp 2018-01-16 11:18:23.140563596 +0100 -@@ -176,7 +176,7 @@ do { \ - if (!gotNum) { setBadBit(); return FALSE; } \ - \ - char *ce; \ -- s = '\0'; \ -+ *s = '\0'; \ - _convertType_ tempVal = _convertFunc_(buf, &ce, 0); \ - \ - if (ce != s) \ -@@ -273,7 +273,7 @@ do { \ - gotAll: \ - \ - char *ce; \ -- s = '\0'; \ -+ *s = '\0'; \ - double tempVal = _convertFunc_(buf, &ce); \ - \ - if (ce != s) \ diff --git a/srcpkgs/coin3/patches/no-cpack.patch b/srcpkgs/coin3/patches/no-cpack.patch new file mode 100644 index 00000000000..5417d2e66c9 --- /dev/null +++ b/srcpkgs/coin3/patches/no-cpack.patch @@ -0,0 +1,8 @@ +--- CMakeLists.txt.ORIG ++++ CMakeLists.txt +@@ -815,4 +815,4 @@ + + # ############################################################################ + # New CPACK section, please see the README file inside cpack.d directory. +-add_subdirectory(cpack.d) ++#add_subdirectory(cpack.d) diff --git a/srcpkgs/coin3/template b/srcpkgs/coin3/template index 4150c863e9f..80a65803395 100644 --- a/srcpkgs/coin3/template +++ b/srcpkgs/coin3/template @@ -1,55 +1,30 @@ # Template file for 'coin3' pkgname=coin3 -version=3.1.3 -revision=5 -wrksrc="Coin-${version}" -build_style=gnu-configure -configure_args="--includedir=/usr/include/Coin3 --disable-dependency-tracking - --disable-static --enable-threadsafe --enable-exceptions - --disable-dl-simage --disable-dl-glu --disable-dl-libbzip2 - --disable-dl-zlib --disable-dl-freetype --disable-dl-fontconfig - --enable-3ds-import --enable-html - sim_ac_simage_configcmd=$XBPS_CROSS_BASE/usr/bin/simage-config" -hostmakedepends="pkg-config doxygen perl" -makedepends="freetype-devel glu-devel zlib-devel bzip2-devel - fontconfig-devel boost-devel simage-devel" +version=4.0.0 +revision=1 +wrksrc="coin-Coin-${version}" +build_style=cmake +configure_args="-DCMAKE_INSTALL_INCLUDEDIR=/usr/include/Coin3 + -DCMAKE_BUILD_TYPE=Release -DCOIN_BUILD_TESTS=OFF -DCOIN_BUILD_DOCUMENTATION=ON" +hostmakedepends="doxygen graphviz" +makedepends="boost-devel glu-devel" short_desc="High-level 3D graphics toolkit" maintainer="yopito " -# HomePage tells BSD 3-Clause license, but tarball is GPLv2 -license="GPL-2.0-only" -homepage="https://bitbucket.org/Coin3D/coin/wiki/Home" -distfiles="https://bitbucket.org/Coin3D/coin/downloads/Coin-${version}.tar.gz" -checksum=583478c581317862aa03a19f14c527c3888478a06284b9a46a0155fa5886d417 -patch_args="-Np1" +license="BSD-3-Clause" +homepage="https://coin3d.github.io" +distfiles="https://github.com/coin3d/coin/archive/Coin-${version}.tar.gz" +checksum=b00d2a8e9d962397cf9bf0d9baa81bcecfbd16eef675a98c792f5cf49eb6e805 -post_extract() { - # remove bundled boost headers - rm -rf ${wrksrc}/include/boost -} - -do_configure() { - # only way to compute and point freetype2 stuff to configure - : ${configure_script:=./configure} - CPPFLAGS+="$(pkg-config --cflags freetype2)" ${configure_script} ${configure_args} -} - -post_configure() { - case "$XBPS_TARGET_MACHINE" in - *-musl) - # configure checks are awfull - sed -i -e 's,^#define SIM_TIMEVAL_TV_SEC_T { },#define SIM_TIMEVAL_TV_SEC_T time_t,' \ - -e 's,^#define SIM_TIMEVAL_TV_USEC_T { },#define SIM_TIMEVAL_TV_USEC_T suseconds_t,' \ - ${wrksrc}/src/config.h - ;; - esac -} +if [ "$CROSS_BUILD" ]; then + # bypass runtime test (quote hashing is fine with gcc 9.3) + configure_args+=" -DHAVE_HASH_QUOTING_EXITCODE=0" + configure_args+=" -DHAVE_HASH_QUOTING_EXITCODE__TRYRUN_OUTPUT=''" +fi post_install() { - if [ "$CROSS_BUILD" ]; then - sed -i -e "s,$XBPS_CROSS_BASE,,g" \ - $DESTDIR/usr/share/Coin/conf/coin-default.cfg \ - $DESTDIR/usr/lib/pkgconfig/Coin.pc - fi + # coin-config is superseeded by cmake support + rm $DESTDIR/usr/bin/coin-config + vlicense COPYING } coin3-devel_package() { @@ -57,11 +32,9 @@ coin3-devel_package() { depends="${makedepends} ${sourcepkg}>=${version}_${revision}" pkg_install() { vmove usr/include - vmove usr/bin/coin-config + vmove usr/lib/cmake vmove "usr/lib/*.so" vmove usr/lib/pkgconfig - vmove usr/share/aclocal - vmove usr/share/man } } diff --git a/srcpkgs/coin3/update b/srcpkgs/coin3/update deleted file mode 100644 index 6494e81f18f..00000000000 --- a/srcpkgs/coin3/update +++ /dev/null @@ -1 +0,0 @@ -pattern="Coin-\K[\d.]+(?=\.tar)" From f5fc4014aea1da0d2eda2cde36c127d4b409a34d Mon Sep 17 00:00:00 2001 From: yopito Date: Sun, 28 Jun 2020 17:19:28 +0200 Subject: [PATCH 2/3] python3-pivy: update to 0.6.5 --- srcpkgs/python3-pivy/patches/73cd928f.patch | 36 ------------------- srcpkgs/python3-pivy/template | 39 +++++++-------------- srcpkgs/python3-pivy/update | 3 -- 3 files changed, 12 insertions(+), 66 deletions(-) delete mode 100644 srcpkgs/python3-pivy/patches/73cd928f.patch delete mode 100644 srcpkgs/python3-pivy/update diff --git a/srcpkgs/python3-pivy/patches/73cd928f.patch b/srcpkgs/python3-pivy/patches/73cd928f.patch deleted file mode 100644 index edff803822a..00000000000 --- a/srcpkgs/python3-pivy/patches/73cd928f.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 73cd928fe1a9c2abbe6f28844a7fc695ad11d7cf Mon Sep 17 00:00:00 2001 -From: Peter Lama -Date: Fri, 24 Aug 2018 17:25:47 -0700 -Subject: [PATCH] Fix issue #39: PyUnicode_AsUTF8 returns const char* - -Even with python 2, it doesn't seem like char* is needed - ---- Inventor/nodes/SoMarkerSet.i -+++ Inventor/nodes/SoMarkerSet.i -@@ -5,7 +5,7 @@ - short WIDTH, HEIGHT; - size.getValue(WIDTH, HEIGHT); - short BYTEWIDTH = (WIDTH + 7) / 2; -- char* coin_marker; -+ const char* coin_marker; - #ifdef PY_2 - if (PyString_Check(string)) - { -@@ -49,4 +49,4 @@ - delete[] bitmapbytes; - bitmapbytes = NULL; - } --} -\ No newline at end of file -+} ---- Inventor/sensors/SoSensor.i -+++ Inventor/sensors/SoSensor.i -@@ -4,7 +4,7 @@ SoSensorPythonCB(void * data, SoSensor * sensor) - { - PyGILState_STATE gil = PyGILState_Ensure(); - swig_type_info * swig_type = 0; -- char * sensor_cast_name = NULL; -+ const char * sensor_cast_name = NULL; - PyObject * func, * arglist; - PyObject * result, * pysensor; - diff --git a/srcpkgs/python3-pivy/template b/srcpkgs/python3-pivy/template index d58767f93d4..14152c54c79 100644 --- a/srcpkgs/python3-pivy/template +++ b/srcpkgs/python3-pivy/template @@ -1,41 +1,26 @@ # Template file for 'python3-pivy' pkgname=python3-pivy -version=0.6.4 -revision=2 -wrksrc="Coin3D-pivy-a84100beff22" +version=0.6.5 +revision=1 +wrksrc="pivy-${version}" build_style=python3-module -hostmakedepends="python3-devel swig" -makedepends="python3-devel coin3-devel qt5-devel" +hostmakedepends="python3-devel swig cmake" +makedepends="python3-devel coin3-devel" short_desc="Python3 bindings for the high-level 3D graphics library Coin" maintainer="yopito " -license="0BSD" -homepage="https://bitbucket.org/Coin3D/pivy" -distfiles="https://bitbucket.org/Coin3D/pivy/get/${version}.tar.gz" -checksum=2ee684dbf0f52c05b491c5423013fd82e679614bffee23641485248c8a790c4e +license="ISC" +homepage="https://github.com/coin3d/pivy" +distfiles="https://github.com/coin3d/pivy/archive/${version}.tar.gz" +checksum=16f2e339e5c59a6438266abe491013a20f53267e596850efad1559564a2c1719 + +# pivy 0.6.6 is supposed to use cmake (https://github.com/coin3d/pivy/issues/59) +nocross="setup.py calls cmake directly, can't use cmake crossbuild support" case "$XBPS_TARGET_MACHINE" in ppc64*);; ppc*) broken="{standard input}:3376761: Error: operand out of range";; esac -if [ "$CROSS_BUILD" ]; then - CFLAGS+=" -I$XBPS_CROSS_BASE/usr/include/Coin3" -fi - -post_extract() ( - # use setup_old.py until have Coin with cmake support - mv -f setup_old.py setup.py -) - -post_patch() { - if [ "$CROSS_BUILD" ]; then - vsed -i setup.py \ - -e '/if not self[.]check_cmd_exists.*coin-config/,+1d' \ - -e "s!coin-config!$XBPS_CROSS_BASE/usr/bin/coin-config!" \ - -e "/INCLUDE_DIR.*coin-config/s!=!= \"$XBPS_CROSS_BASE\" +!" - fi -} - post_install() { vlicense LICENSE } diff --git a/srcpkgs/python3-pivy/update b/srcpkgs/python3-pivy/update deleted file mode 100644 index d4a4e715386..00000000000 --- a/srcpkgs/python3-pivy/update +++ /dev/null @@ -1,3 +0,0 @@ -site=https://bitbucket.org/Coin3D/pivy/downloads/?tab=tags -pkgname= -ignore="20101207" From 2f0d507b0dd8b9f24b4d6b607541373400a6cc1b Mon Sep 17 00:00:00 2001 From: yopito Date: Wed, 8 Jul 2020 07:55:11 +0200 Subject: [PATCH 3/3] freecad: rebuild with coin3 4.0.0 and python3-pivy 0.6.5 add compression lib for salomesh build (not provided anymore by Coin) [ci skip] --- .../patches/103-find-coin3v4-doc.patch | 50 +++++++++++++++++++ srcpkgs/freecad/template | 3 +- 2 files changed, 52 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/freecad/patches/103-find-coin3v4-doc.patch diff --git a/srcpkgs/freecad/patches/103-find-coin3v4-doc.patch b/srcpkgs/freecad/patches/103-find-coin3v4-doc.patch new file mode 100644 index 00000000000..5b7de514de4 --- /dev/null +++ b/srcpkgs/freecad/patches/103-find-coin3v4-doc.patch @@ -0,0 +1,50 @@ +From 04833a5f1cbc07f8f6ae94453c4535e13789aa05 Mon Sep 17 00:00:00 2001 +From: yopito +Date: Mon, 6 Jul 2020 06:54:07 +0200 +Subject: [PATCH] build: fix Coin 3d documentation discovering + +* coin3d 4.0.0 default location is /usr/share/doc/Coin/html/ +* misuses of find_files() if several candidates for filename +* export variable COIN3D_DOC_FOUND that is used by cMake/FreeCAD_Helpers/PrintFinalReport.cmake +--- + cMake/FindCoin3DDoc.cmake | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git cMake/FindCoin3DDoc.cmake cMake/FindCoin3DDoc.cmake +index 883368445..c6c92f260 100644 +--- cMake/FindCoin3DDoc.cmake ++++ cMake/FindCoin3DDoc.cmake +@@ -23,18 +23,19 @@ IF (COIN3D_FOUND) + find_path(COIN3D_DOC_PATH index.html + /usr/share/doc/libcoin80-doc/html + /usr/share/doc/coin/html ++ /usr/share/doc/Coin/html + ) + IF( EXISTS ${COIN3D_DOC_PATH}) + message(STATUS "Coin3D doc is installed") +- find_file(COIN3D_DOC_TAGFILE coin.tag Coin.tag +- ${COIN3D_DOC_PATH} ++ find_file(COIN3D_DOC_TAGFILE NAMES coin.tag Coin.tag ++ PATHS ${COIN3D_DOC_PATH} + ) + IF( EXISTS ${COIN3D_DOC_TAGFILE}) + SET( COIN3D_DOC_FOUND "YES" + ) + ELSE( EXISTS ${COIN3D_DOC_TAGFILE}) +- find_file(COIN3D_DOC_TAGFILE_GZ coin.tag.gz Coin.tag.gz +- ${COIN3D_DOC_PATH} ++ find_file(COIN3D_DOC_TAGFILE_GZ NAMES coin.tag.gz Coin.tag.gz ++ PATHS ${COIN3D_DOC_PATH} + ) + IF( EXISTS ${COIN3D_DOC_TAGFILE_GZ}) + message(STATUS " Found ${COIN3D_DOC_TAGFILE_GZ}") +@@ -85,4 +86,5 @@ if(COIN3D_DOC_FOUND) + message(STATUS " Location: ${COIN3D_DOC_PATH}") + endif(COIN3D_DOC_FOUND) + +- ++# export for others ++SET( COIN3D_DOC_FOUND "${COIN3D_DOC_FOUND}" CACHE BOOL "Coin3d documentation available") +-- +2.27.0 + diff --git a/srcpkgs/freecad/template b/srcpkgs/freecad/template index 9f296b6086c..2904be5dea9 100644 --- a/srcpkgs/freecad/template +++ b/srcpkgs/freecad/template @@ -1,7 +1,7 @@ # Template file for 'freecad' pkgname=freecad version=0.18.4 -revision=7 +revision=8 wrksrc="FreeCAD-${version}" build_style=cmake @@ -17,6 +17,7 @@ configure_args=" -DPYSIDE2UICBINARY=/usr/bin/uic-qt5" hostmakedepends="pkg-config swig doxygen graphviz" makedepends="python3-devel boost-devel libxerces-c-devel zlib-devel occt-devel + liblzma-devel libjpeg-turbo-devel tiff-devel vtk-devel hdf5-devel openmpi-devel libmed-devel eigen double-conversion-devel coin3-devel libshiboken2-devel libspnav-devel pyside2-tools liblz4-devel libpyside2-python3-devel python3-matplotlib netcdf-devel