Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glib/2.78.x: Add patch to support Python 3.12 #21535

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

jwillikers
Copy link
Contributor

@jwillikers jwillikers commented Dec 1, 2023

Specify library name and version: glib/2.78.x

The distutils module was removed in Python 3.12, requiring at least Meson 1.2.3 and a patch for glib. See the upstream PR here.

Requires conan-io/conan-docker-tools#554


@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@jwillikers
Copy link
Contributor Author

Oh yes, actually need to install the Python packaging module for this to work...

This was referenced Dec 6, 2023
@ghost ghost mentioned this pull request Dec 23, 2023
3 tasks
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

1 similar comment
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline ❌

Failure in build 10 (86070b8eb252e5cbca5e22eb725d8671a3fa07d9):

  • glib/2.79.2:
    CI failed to create some packages (All logs)

    Logs for packageID e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00:
    [settings]
    arch=x86_64
    build_type=Release
    compiler=gcc
    compiler.libcxx=libstdc++11
    compiler.version=7
    os=Linux
    [options]
    glib:shared=False
    
    [...]
    Header "pthread.h" has symbol "pthread_attr_setstacksize" : YES 
    Header "pthread.h" has symbol "pthread_attr_setinheritsched" : YES 
    Header "pthread.h" has symbol "pthread_condattr_setclock" : YES 
    Header "pthread.h" has symbol "pthread_cond_timedwait_relative_np" : NO 
    Header "pthread.h" has symbol "pthread_getname_np" : YES 
    Header "pthread.h" has symbol "pthread_getaffinity_np" : YES 
    Checking if "pthread_setname_np(const char*)" with dependency threads: links: NO 
    Checking if "pthread_setname_np(pthread_t, const char*)" with dependency threads: links: YES 
    Checking if "stack grows check" runs: NO (1)
    Run-time dependency iconv found: YES
    Found pkg-config: YES (/home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/pkgconf/2.1.0/_/_/package/24647d9fe8ec489125dfbae4b3ebefaf7581674c/bin/pkgconf) 2.1.0
    Run-time dependency libpcre2-8 found: YES 10.42
    
    Executing subproject gvdb 
    
    gvdb| Project name: gvdb
    gvdb| Project version: 0.0
    gvdb| C compiler for the host machine: gcc (gcc 7.5.0 "gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0")
    gvdb| C linker for the host machine: gcc ld.bfd 2.30
    gvdb| Build targets in project: 0
    gvdb| Subproject gvdb finished.
    
    Dependency gvdb found: YES 0.0 (overridden)
    Library m found: YES
    Run-time dependency libffi found: YES 3.4.4
    Run-time dependency zlib found: YES 1.3.1
    Run-time dependency intl found: YES
    Checking for function "ngettext" with dependency intl: YES 
    Checking for function "bind_textdomain_codeset" with dependency intl: YES 
    Run-time dependency mount found: YES 2.39
    Checking for function "mnt_monitor_veil_kernel" with dependency mount: NO 
    Run-time dependency libselinux found: YES 3.5
    Checking for function "getxattr" : YES 
    Has header "sys/xattr.h" : YES 
    Checking if "XATTR_NOFOLLOW" compiles: NO 
    Checking for function "strlcpy" : NO 
    Checking if "/proc/self/cmdline" runs: YES
    Program python3 (packaging) found: NO
    
    ../src/meson.build:2421:26: ERROR: python is missing modules: packaging
    
    A full log can be found at /home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/build/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00/build-release/meson-logs/meson-log.txt
    glib/2.79.2: 
    WARN: pcre2/10.42: requirement zlib/[>=1.2.11 <2] overridden by glib/2.79.2 to zlib/1.3.1 
    glib/2.79.2: WARN: Using the new toolchains and generators without specifying a build profile (e.g: -pr:b=default) is discouraged and might cause failures and unexpected behavior
    glib/2.79.2: ERROR: Package 'e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00' build failed
    glib/2.79.2: WARN: Build folder /home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/build/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00/build-release
    ERROR: glib/2.79.2: Error in build() method, line 136
    	meson.configure()
    	ConanException: Error 1 while executing meson setup --native-file "/home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/build/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00/build-release/conan/conan_meson_native.ini" "/home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/build/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00/build-release" "/home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/build/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00/src" -Dprefix="/home/conan/w/prod-v1/bsr/118086/eaeec/.conan/data/glib/2.79.2/_/_/package/e6101fdf9edfaeac7ef98ff8c56b9d07577e2b00"
    
  • glib/2.78.3:
    Didn't run or was cancelled before finishing

  • glib/2.77.3:
    Didn't run or was cancelled before finishing

  • glib/2.78.1:
    Didn't run or was cancelled before finishing

  • glib/2.78.0:
    Didn't run or was cancelled before finishing

  • glib/2.77.1:
    Didn't run or was cancelled before finishing

  • glib/2.75.3:
    Didn't run or was cancelled before finishing

  • glib/2.77.0:
    Didn't run or was cancelled before finishing

  • glib/2.77.2:
    Didn't run or was cancelled before finishing

  • glib/2.76.3:
    Didn't run or was cancelled before finishing


Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.


Conan v2 pipeline ❌

Note: Conan v2 builds are now mandatory. Please read our discussion about it.

The v2 pipeline failed. Please, review the errors and note this is required for pull requests to be merged. In case this recipe is still not ported to Conan 2.x, please, ping @conan-io/barbarians on the PR and we will help you.

See details:

Failure in build 10 (86070b8eb252e5cbca5e22eb725d8671a3fa07d9):

  • glib/2.78.3:
    CI failed to create some packages (All logs)

    Logs for packageID 92a5fb6ee386014d1462dd42634645fb26cd90eb:
    [settings]
    arch=x86_64
    build_type=Release
    compiler=gcc
    compiler.cppstd=17
    compiler.libcxx=libstdc++11
    compiler.version=11
    os=Linux
    [options]
    */*:shared=False
    
    [...]
    [119/522] Compiling C object gobject/libgobject-2.0.a.p/gtypemodule.c.o
    [120/522] Compiling C object gobject/libgobject-2.0.a.p/gtypeplugin.c.o
    [121/522] Compiling C object gobject/libgobject-2.0.a.p/gtype.c.o
    [122/522] Compiling C object gobject/libgobject-2.0.a.p/gvalue.c.o
    [123/522] Compiling C object gobject/libgobject-2.0.a.p/gvaluearray.c.o
    [124/522] Compiling C object gobject/libgobject-2.0.a.p/gvaluetransform.c.o
    [125/522] Compiling C object gobject/libgobject-2.0.a.p/gvaluetypes.c.o
    [126/522] Linking static target gthread/libgthread-2.0.a
    [127/522] Generating gmodule/gmodule-visibility.h with a custom command
    [128/522] Compiling C object gobject/gobject-query.p/gobject-query.c.o
    [129/522] Compiling C object gmodule/libgmodule-2.0.a.p/gmodule-deprecated.c.o
    [130/522] Compiling C object gmodule/libgmodule-2.0.a.p/gmodule.c.o
    [131/522] Linking static target gmodule/libgmodule-2.0.a
    [132/522] Generating gio/xdp-dbus with a custom command
    FAILED: gio/xdp-dbus.h gio/xdp-dbus.c 
    /opt/pyenv/versions/3.7.13/bin/python3 gio/gdbus-2.0/codegen/gdbus-codegen --interface-prefix org.freedesktop.portal. --output-directory gio --generate-c-code xdp-dbus --c-namespace GXdp ../src/gio/org.freedesktop.portal.Documents.xml ../src/gio/org.freedesktop.portal.OpenURI.xml ../src/gio/org.freedesktop.portal.ProxyResolver.xml ../src/gio/org.freedesktop.portal.Trash.xml
    Traceback (most recent call last):
      File "gio/gdbus-2.0/codegen/gdbus-codegen", line 53, in <module>
        from codegen import codegen_main
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/codegen_main.py", line 29, in <module>
        from . import dbustypes
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/dbustypes.py", line 22, in <module>
        from . import utils
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/utils.py", line 22, in <module>
        import packaging.version
    ModuleNotFoundError: No module named 'packaging'
    [133/522] Generating gio/gdbus-daemon-generated with a custom command
    FAILED: gio/gdbus-daemon-generated.h gio/gdbus-daemon-generated.c 
    /opt/pyenv/versions/3.7.13/bin/python3 gio/gdbus-2.0/codegen/gdbus-codegen --interface-prefix org. --output-directory gio --generate-c-code gdbus-daemon-generated --c-namespace _G ../src/gio/dbus-daemon.xml
    Traceback (most recent call last):
      File "gio/gdbus-2.0/codegen/gdbus-codegen", line 53, in <module>
        from codegen import codegen_main
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/codegen_main.py", line 29, in <module>
        from . import dbustypes
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/dbustypes.py", line 22, in <module>
        from . import utils
      File "/home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release/gio/gdbus-2.0/codegen/utils.py", line 22, in <module>
        import packaging.version
    ModuleNotFoundError: No module named 'packaging'
    [134/522] Compiling C object gobject/libgobject-2.0.a.p/gsignal.c.o
    ninja: build stopped: subcommand failed.
    INFO: autodetecting backend as ninja
    INFO: calculating backend command to run: /home/conan/w/prod-v2/bsr/103000/addba/p/ninja6fed3c8400c5b/p/bin/ninja -j 3
    
    glib/2.78.3: ERROR: 
    Package '92a5fb6ee386014d1462dd42634645fb26cd90eb' build failed
    glib/2.78.3: WARN: Build folder /home/conan/w/prod-v2/bsr/103000/addba/p/b/glib67a2d0cdb4412/b/build-release
    ERROR: glib/2.78.3: Error in build() method, line 137
    	meson.build()
    	ConanException: Error 1 while executing
    
  • glib/2.79.2:
    Didn't run or was cancelled before finishing

  • glib/2.75.3:
    Didn't run or was cancelled before finishing

  • glib/2.77.3:
    Didn't run or was cancelled before finishing

  • glib/2.77.2:
    Didn't run or was cancelled before finishing

  • glib/2.78.1:
    Didn't run or was cancelled before finishing

  • glib/2.78.0:
    Didn't run or was cancelled before finishing

  • glib/2.77.0:
    Didn't run or was cancelled before finishing

  • glib/2.77.1:
    Didn't run or was cancelled before finishing

  • glib/2.76.3:
    Didn't run or was cancelled before finishing


Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.

Copy link
Member

@uilianries uilianries left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backporting the feature is not a good idea as the upstream no longer support it so there is no guarantee about the behavior. Let's keep trying a solution with packaging first. Thank you for checking this possibility.

@ghost ghost mentioned this pull request Mar 14, 2024
3 tasks
@ghost ghost mentioned this pull request Mar 21, 2024
3 tasks
@stevenwdv
Copy link

FYI, this is preventing glib from building on our macOS builder, see #23029 (comment)

@ghost ghost mentioned this pull request Apr 15, 2024
@ghost ghost mentioned this pull request May 14, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants