Bug 268226 - devel/py-llfuse: fix build with clang 15
Summary: devel/py-llfuse: fix build with clang 15
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks: 265425
  Show dependency treegraph
 
Reported: 2022-12-07 16:09 UTC by Dimitry Andric
Modified: 2022-12-25 17:56 UTC (History)
0 users

See Also:


Attachments
devel/py-llfuse: fix build with clang 15 (1.84 KB, patch)
2022-12-07 16:09 UTC, Dimitry Andric
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitry Andric freebsd_committer freebsd_triage 2022-12-07 16:09:14 UTC
During an exp-run for llvm 15 (see bug 265425), it turned out that devel/py-llfuse failed to build with clang 15:

  src/llfuse.c:41839:21: error: incompatible pointer to integer conversion assigning to 'uintptr_t' (aka 'unsigned int') from 'pthread_t' (aka 'struct pthread *') [-Wint-conversion]
          __pyx_v_tid = __pyx_t_7;
                      ^ ~~~~~~~~~
  src/llfuse.c:42467:3: warning: 'PyEval_InitThreads' is deprecated [-Wdeprecated-declarations]
    PyEval_InitThreads();
    ^
  /usr/local/include/python3.9/ceval.h:130:1: note: 'PyEval_InitThreads' has been explicitly marked deprecated here
  Py_DEPRECATED(3.9) PyAPI_FUNC(void) PyEval_InitThreads(void);
  ^
  /usr/local/include/python3.9/pyport.h:508:54: note: expanded from macro 'Py_DEPRECATED'
  #define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
                                                       ^
  1 warning and 1 error generated.

The conversion from pthread_t to uintptr_t needs an explicit cast.
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2022-12-07 16:09:41 UTC
Created attachment 238606 [details]
devel/py-llfuse: fix build with clang 15
Comment 2 commit-hook freebsd_committer freebsd_triage 2022-12-25 17:55:20 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=df7a32d6fa9a8c5270a0f25990db09e25a02b3f1

commit df7a32d6fa9a8c5270a0f25990db09e25a02b3f1
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2022-12-07 16:06:21 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2022-12-25 17:49:37 +0000

    devel/py-llfuse: fix build with clang 15

    During an exp-run for llvm 15 (see bug 265425), it turned out that
    devel/py-llfuse failed to build with clang 15:

      src/llfuse.c:41839:21: error: incompatible pointer to integer conversion assigning to 'uintptr_t' (aka 'unsigned int') from 'pthread_t' (aka 'struct pthread *') [-Wint-conversion]
              __pyx_v_tid = __pyx_t_7;
                          ^ ~~~~~~~~~
      src/llfuse.c:42467:3: warning: 'PyEval_InitThreads' is deprecated [-Wdeprecated-declarations]
        PyEval_InitThreads();
        ^
      /usr/local/include/python3.9/ceval.h:130:1: note: 'PyEval_InitThreads' has been explicitly marked deprecated here
      Py_DEPRECATED(3.9) PyAPI_FUNC(void) PyEval_InitThreads(void);
      ^
      /usr/local/include/python3.9/pyport.h:508:54: note: expanded from macro 'Py_DEPRECATED'
      #define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
                                                           ^
      1 warning and 1 error generated.

    The conversion from pthread_t to uintptr_t needs an explicit cast.

    PR:             268226
    Approved by:    maintainer timeout (2 weeks)
    MFH:            2022Q4

 devel/py-llfuse/files/patch-src_llfuse.c (new) | 11 +++++++++++
 1 file changed, 11 insertions(+)