Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 929973 - media-gfx/freecad-0.21.2-r2 fails to build with qt/pyside6/shiboken6-6.7: cannot convert ‘Shiboken::Module::TypeInitStruct*’ to ‘PyTypeObject**’ {aka ‘_typeobject**’} in assignment
Summary: media-gfx/freecad-0.21.2-r2 fails to build with qt/pyside6/shiboken6-6.7: can...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Paul Zander
URL: https://github.com/FreeCAD/FreeCAD/is...
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2024-04-13 23:17 UTC by J.Borme
Modified: 2024-06-03 14:33 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (media-gfx:freecad-0.21.2-r2:20240413-170436.log.xz,75.34 KB, application/x-xz)
2024-04-13 23:20 UTC, J.Borme
Details
freecad-0.21.2-pyside6-6.7.0.patch (freecad-0.21.2-pyside6-6.7.0.patch,310 bytes, patch)
2024-04-14 01:55 UTC, Ionen Wolkens
Details | Diff
freecad-0.21.2-pyside6-6.7.0.patch (freecad-0.21.2-pyside6-6.7.0.patch,306 bytes, patch)
2024-04-14 02:14 UTC, Ionen Wolkens
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description J.Borme 2024-04-13 23:17:57 UTC
After upgrading to dev-python/shiboken6-6.7.0 and dev-python/pyside6-6.7.0, freecad-0.21.2-r2 fails to rebuild.

FAILED: src/Gui/CMakeFiles/FreeCADGui.dir/PythonWrapper.cpp.o
In function ‘bool Gui::loadPySideModule(const std::string&, PyTypeObject**&)’:
PythonWrapper.cpp:481:43: error: cannot convert ‘Shiboken::Module::TypeInitStruct*’ to ‘PyTypeObject**’ {aka ‘_typeobject**’} in assignment

Maybe see also Bug 928592

Reproducible: Always




Portage 3.0.61 (python 3.11.8-final-0, default/linux/amd64/23.0/split-usr/desktop, gcc-13, glibc-2.38-r11, 6.8.4-gentoo-x86_64 x86_64)
=================================================================
System uname: Linux-6.8.4-gentoo-x86_64-x86_64-AMD_Ryzen_9_3950X_16-Core_Processor-with-glibc2.38
KiB Mem:   131825660 total,  54755020 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Sat, 13 Apr 2024 09:30:00 +0000
Head commit of repository gentoo: 27eebee0223b71bd5f9864294b00ca4aa8f39c11
Head commit of repository supertux88: ce2584fb751a1ca2e02cf2038c1a3bff6cc47600

Head commit of repository oubliette: d74b8676d696ec4a5304fda055d2c7fe9b528288

Head commit of repository palemoon: cab330888e37dfa0d340a236a8fe27b44159fc5e

Head commit of repository pentoo: e0dd684fbfd46f6eed34add267b38ee7a249ca6e

Head commit of repository pf4public: 8d24b01c6f1f578941e07ef6390b4a189a92595d

Head commit of repository pg_overlay: 896b08dfd38e97f9e8c223d34b5394210ba5364f

Head commit of repository science: d92a65a7066fd6bc6467e88a26c33e9e5a152a8e

Head commit of repository stuff: 497a13f20ae408b0141d38c7e26191e4d1963fa5

sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.41 p5) 2.41.0
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-build/autoconf:        2.13-r8::gentoo, 2.71-r6::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.28.3::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r1::gentoo
dev-build/meson:           1.3.2::gentoo
dev-java/java-config:      2.3.3-r1::gentoo
dev-lang/perl:             5.38.2-r2::gentoo
dev-lang/python:           2.7.18_p16-r2::gentoo, 3.10.14_p1::gentoo, 3.11.8_p1::gentoo, 3.12.3::gentoo
dev-lang/rust:             1.75.0-r1::gentoo
sys-apps/baselayout:       2.14-r2::gentoo
sys-apps/openrc:           0.54::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-devel/binutils:        2.41-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           17.0.6::gentoo, 18.1.3::gentoo
sys-devel/gcc:             12.3.1_p20240209::gentoo, 13.2.1_p20240210::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/lld:             17.0.6::gentoo, 18.1.3::gentoo
sys-devel/llvm:            17.0.6::gentoo, 18.1.3::gentoo
sys-kernel/linux-headers:  6.8-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.38-r11::gentoo
Repositories:

gentoo
    location: /tmp/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: True
    sync-rsync-verify-max-age: 24
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts: --quiet --times --omit-dir-times --omit-link-times

localrepo
    location: /var/db/repos/localrepo
    masters: gentoo
    volatile: False

supertux88
    location: /var/db/repos/supertux88
    sync-type: git
    sync-uri: https://github.com/SuperTux88/gentoo-overlay.git
    masters: gentoo
    volatile: False

x-portage
    location: /usr/local/portage
    masters: gentoo
    priority: 0
    volatile: True

oubliette
    location: /var/lib/layman/oubliette
    sync-type: git
    sync-uri: https://github.com/nabbi/oubliette-overlay.git
    masters: gentoo
    priority: 50
    volatile: True

palemoon
    location: /var/lib/layman/palemoon
    sync-type: git
    sync-uri: https://github.com/deu/palemoon-overlay.git
    masters: gentoo
    priority: 50
    volatile: True

pentoo
    location: /var/lib/layman/pentoo
    sync-type: git
    sync-uri: https://github.com/pentoo/pentoo-overlay.git
    masters: gentoo
    priority: 50
    volatile: True

pf4public
    location: /var/lib/layman/pf4public
    sync-type: git
    sync-uri: https://github.com/PF4Public/gentoo-overlay.git
    masters: gentoo
    priority: 50
    volatile: True

pg_overlay
    location: /var/lib/layman/pg_overlay
    sync-type: git
    sync-uri: https://gitlab.com/Perfect_Gentleman/PG_Overlay.git
    masters: gentoo
    priority: 50
    volatile: True

science
    location: /var/lib/layman/science
    sync-type: git
    sync-uri: https://anongit.gentoo.org/git/proj/sci.git
    masters: gentoo
    priority: 50
    volatile: True

stuff
    location: /var/lib/layman/stuff
    sync-type: git
    sync-uri: https://github.com/istitov/stuff.git
    masters: gentoo
    priority: 50
    volatile: True

Binary Repositories:

binhost
    priority: 9999
    sync-uri: https://ftp.rnl.tecnico.ulisboa.pt/pub/gentoo/gentoo-distfiles/releases/amd64/binpackages/23.0/x86-64-v3

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=native"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -pipe -march=native"
DISTDIR="/tmp/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps=y --complete-graph --keep-going --jobs 10 --load-average 30"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -pipe -march=native"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe -march=native"
GENTOO_MIRRORS="ftp://ftp.halifax.rwth-aachen.de/gentoo/ ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo http://distfiles.gentoo.org http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LANG="fr_FR.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs"
LEX="flex"
MAKEOPTS="-j32"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_EXTRA_OPTS="--quiet --times --omit-dir-times --omit-link-times"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/tmp/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac acl acpi alsa amd64 avif bluetooth branding bzip2 cairo cdda cdr cdrom cet crypt cuda cups dbus dri dropbox dts dvd dvdr elogind encode exif ffmpeg flac gdbm gif gmic gmp gpm gtk gui iconv icu ipv6 jpeg jpeg2k jpegxl kde lcms libnotify libtirpc mad mp3 mp4 mpeg multilib ncurses nls nvenc ogg openexr opengl openmp opus pam pango pcre pdf png policykit ppds qt5 readline replaygain sdl seccomp sound spell split-usr ssl startup-notification svg test-rust tiff truetype udev udisks unicode upower usb v4l vdpau vim-syntax vorbis vpx vulkan webp wxwidgets x264 xattr xcb xft xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets stage words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt sha sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 ntrip navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="libinput" KERNEL="linux" L10N="fr fr-FR" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LLVM_TARGETS="NVPTX" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11" RUBY_TARGETS="ruby25" SANE_BACKENDS="pixma net" VIDEO_CARDS="fbdev vesa dummy nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PYTHONPATH, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 J.Borme 2024-04-13 23:20:58 UTC
Created attachment 890743 [details]
build log
Comment 2 Ionen Wolkens gentoo-dev 2024-04-14 01:55:33 UTC
Created attachment 890745 [details, diff]
freecad-0.21.2-pyside6-6.7.0.patch

Haven't tried building, but had a quick peek at Arch given they had a pyside6-6.7.0 snapshot for a while (in testing) and I see a sed that's most likely this:

https://gitlab.archlinux.org/archlinux/packaging/packages/freecad/-/blob/main/PKGBUILD?ref_type=heads#L46

  sed -e 's|Shiboken::Module::getTypes(requiredModule)|reinterpret_cast<PyTypeObject **>(Shiboken::Module::getTypes(requiredModule))|' \
    -i freecad/src/Gui/PythonWrapper.cpp # Fix build with PySide 6.7

Imagine they preferred sed because of the CRLF terminators, the resulting patch is fairly small (attached). Not that I tried using it so good luck.

No idea if it harms building with 6.6.2, albeit that one does not have long left to live in the tree anyway.

wrt Arch they also have the needed backports for py3.12 if someone wanted to look at that in the coming month before the default target switch (current plan is early June, so not that long left and imagine freecad may not do a release in time).
Comment 3 Ionen Wolkens gentoo-dev 2024-04-14 02:14:44 UTC
Created attachment 890746 [details, diff]
freecad-0.21.2-pyside6-6.7.0.patch

(In reply to Ionen Wolkens from comment #2)
> Created attachment 890745 [details, diff] [details, diff]
> freecad-0.21.2-pyside6-6.7.0.patch
oh bleh, hadn't noticed our ebuild does dos2unix for some reason, so that patch won't work

new version then
Comment 4 Ionen Wolkens gentoo-dev 2024-04-14 02:24:26 UTC
$URL isn't about this exact issue (albeit Andrew did mention it), but linking for reference as there could be more problems.
Comment 5 Larry the Git Cow gentoo-dev 2024-04-14 08:56:45 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=91f702aa09d2fd99e78bb974ae80440daf8dc74b

commit 91f702aa09d2fd99e78bb974ae80440daf8dc74b
Author:     Andrew Ammerlaan <andrewammerlaan@gentoo.org>
AuthorDate: 2024-04-14 08:53:53 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan@gentoo.org>
CommitDate: 2024-04-14 08:53:53 +0000

    media-gfx/freecad: add patch for build with shiboken 6.7.0
    
    patch is added conditional because not sure what this does with older shiboken
    
    and block against opencascade[inspector] which breaks qt6 configure
    
    Bug: https://bugs.gentoo.org/929973
    Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>

 media-gfx/freecad/files/freecad-0.21.2-shiboken-6.7.0.patch | 8 ++++++++
 media-gfx/freecad/freecad-0.21.2-r2.ebuild                  | 6 ++++++
 2 files changed, 14 insertions(+)
Comment 6 Nowa Ammerlaan gentoo-dev 2024-04-14 13:59:39 UTC
(In reply to Ionen Wolkens from comment #2)
> wrt Arch they also have the needed backports for py3.12 if someone wanted to
> look at that in the coming month before the default target switch (current
> plan is early June, so not that long left and imagine freecad may not do a
> release in time).

I'm kinda hoping we will see a new release soon, because the current live version fixes not only python3.12 but also vtk-9.3.0 and opencascade-7.8.0 compatibility. 

Especially that last one is a rather big patch that does not apply cleanly to 0.21.2. So I think I'll wait a bit longer and if we do not have a new release before the py3.12 switch then I think we should consider adding a snapshot instead and fix all of this in one go.