Skip to content

Erroneous warning when configuring file with same name but different build_subdir #15500

@shyun3

Description

@shyun3

Describe the bug
Meson gives an erroneous warning about the output file for configure_file() being overwritten if multiple configure_file() calls are being made from the same directory with the same output file name, but different build_subdir settings. In this case, the output files are not being overwritten because they are being created in different subdirectories.

To Reproduce
meson.build:

project('test', meson_version: '>=1.10')

foreach arg : ['hello', 'world']
    configure_file(
        build_subdir: arg,
        output: 'file',
        configuration: {'key': 'value'},
    )
endforeach

Expected behavior
No such warning to be emitted.

system parameters

  • Is this a cross build or just a plain native build (for the same computer)? Both
  • what operating system (e.g. MacOS Catalina, Windows 10, CentOS 8.0, Ubuntu 18.04, etc.): WSL Ubuntu 24.04.3 LTS
  • what Python version are you using e.g. 3.8.0: 3.12.3
  • what meson --version: 1.10.1
  • what ninja --version if it's a Ninja build: 1.11.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions