Bug 1657958 - gnome.mkenums_simple() does not work properly with file() targets
Summary: gnome.mkenums_simple() does not work properly with file() targets
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: meson
Version: 8.0
Hardware: All
OS: Linux
Target Milestone: rc
: 8.0
Assignee: Stephen Gallagher
QA Contact: Desktop QE
Depends On:
Blocks: 1646436
TreeView+ depends on / blocked
Reported: 2018-12-10 19:59 UTC by Stephen Gallagher
Modified: 2019-06-14 01:45 UTC (History)
4 users (show)

Fixed In Version: meson-0.45.1-3.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2019-06-14 01:45:07 UTC
Type: Bug
Target Upstream Version:

Attachments (Terms of Use)
dist-git patch backporting the upstream patch (3.84 KB, patch)
2018-12-10 19:59 UTC, Stephen Gallagher
no flags Details | Diff

Description Stephen Gallagher 2018-12-10 19:59:50 UTC
Created attachment 1513212 [details]
dist-git patch backporting the upstream patch

Description of problem:
When passed header files as a list of files(), meson generates the enum files incorrectly, such that the headers cannot be imported properly.

Version-Release number of selected component (if applicable):

How reproducible:
Every time

Steps to Reproduce:
1. `git clone https://github.com/fedora-modularity/libmodulemd.git`
2. `meson -Dbuild_api_v2=True -Dbuild_api_v1=False api2 -Ddeveloper_build=False`
3. `ninja build -C api2`

Actual results:
FAILED: modulemd/v2/modulemd@sha/meson-generated_.._modulemd-enums.c.o 
cc  -Imodulemd/v2/modulemd@sha -Imodulemd/v2 -I../modulemd/v2 -I../modulemd/v2/include/modulemd-2.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c11 -O2 -g -Wpointer-arith -Werror=missing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wuninitialized -Werror=format-security -Werror=format=2 -Werror=implicit -Werror=init-self -Werror=main -Werror=missing-braces -Werror=return-type -Werror=array-bounds -Werror=write-strings -DG_LOG_USE_STRUCTURED '-DG_LOG_DOMAIN="libmodulemd"' -fPIC -MD -MQ 'modulemd/v2/modulemd@sha/meson-generated_.._modulemd-enums.c.o' -MF 'modulemd/v2/modulemd@sha/meson-generated_.._modulemd-enums.c.o.d' -o 'modulemd/v2/modulemd@sha/meson-generated_.._modulemd-enums.c.o' -c modulemd/v2/modulemd-enums.c
modulemd/v2/modulemd-enums.c:5:10: fatal error: modulemd/v2/include/modulemd-2.0/modulemd.h: No such file or directory
 #include "modulemd/v2/include/modulemd-2.0/modulemd.h"

Expected results:
Build should succeed (and does, with 0.47+)

Additional info:
Upstream patch is attached to this BZ which resolves the issue (I monkey-patched it in a container to verify). It applies cleanly

Note You need to log in before you can comment on or make changes to this bug.