Bug 268399 - textproc/wv: fix build with clang 15
Summary: textproc/wv: 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: Dimitry Andric
URL:
Keywords:
Depends on:
Blocks: 265425
  Show dependency treegraph
 
Reported: 2022-12-15 21:00 UTC by Dimitry Andric
Modified: 2022-12-18 17:48 UTC (History)
1 user (show)

See Also:


Attachments
textproc/wv: fix build with clang 15 (1.49 KB, patch)
2022-12-15 21:00 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-15 21:00:30 UTC
During an exp-run for llvm 15 (see bug 265425), it turned out that textproc/wv failed to build with clang 15:

  wvSummary.c:104:17: error: incompatible integer to pointer conversion initializing 'const GValue *' (aka 'const struct _GValue *') with an expression of type 'int' [-Wint-conversion]
    GValue const *val = gsf_doc_prop_get_val  (prop);
                  ^     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  wvSummary.c:146:21: error: incompatible integer to pointer conversion initializing 'GsfDocMetaData *' (aka 'struct _GsfDocMetaData *') with an expression of type 'int' [-Wint-conversion]
      GsfDocMetaData *meta_data = gsf_doc_meta_data_new ();
                      ^           ~~~~~~~~~~~~~~~~~~~~~~~~

Those functions are declared in <gsf/gsf-doc-meta-data.h>, but that header is not included in wvSummary.c.
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2022-12-15 21:00:55 UTC
Created attachment 238822 [details]
textproc/wv: fix build with clang 15
Comment 2 Fernando Apesteguía freebsd_committer freebsd_triage 2022-12-16 07:05:44 UTC
^Triage: reporter is committer, assign accordingly.
Comment 3 commit-hook freebsd_committer freebsd_triage 2022-12-18 17:44:20 UTC
A commit in branch main references this bug:

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

commit b1f9d0e1db39fd59537ff549ce1d3bc808122e6d
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2022-12-15 20:56:48 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2022-12-18 17:38:29 +0000

    textproc/wv: fix build with clang 15

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

      wvSummary.c:104:17: error: incompatible integer to pointer conversion initializing 'const GValue *' (aka 'const struct _GValue *') with an expression of type 'int' [-Wint-conversion]
        GValue const *val = gsf_doc_prop_get_val  (prop);
                      ^     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      wvSummary.c:146:21: error: incompatible integer to pointer conversion initializing 'GsfDocMetaData *' (aka 'struct _GsfDocMetaData *') with an expression of type 'int' [-Wint-conversion]
          GsfDocMetaData *meta_data = gsf_doc_meta_data_new ();
                          ^           ~~~~~~~~~~~~~~~~~~~~~~~~

    Those functions are declared in <gsf/gsf-doc-meta-data.h>, but that
    header is not included in wvSummary.c.

    PR:             268399
    Approved by:    portmgr (tcberner)
    MFH:            2022Q4

 textproc/wv/files/patch-wvSummary.c (new) | 10 ++++++++++
 1 file changed, 10 insertions(+)