From aea7042aa10eb295ead6dd72a335e6ff17a0374b Mon Sep 17 00:00:00 2001 From: Bruno Lopes Date: Sat, 4 Oct 2025 16:03:01 -0300 Subject: [PATCH] meson: Support Windows native paths (aka backslashes) on -Dprefix Closes: #12284 --- .gitlab-ci.yml | 2 +- build/windows/2_build-gimp-msys2.ps1 | 2 +- meson.build | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index cf9926b4da..1adee669eb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -542,7 +542,7 @@ gimp-snap: before_script: - if (-not $env:MSYSTEM_PREFIX) { $env:MSYSTEM_PREFIX = if ((Get-WmiObject Win32_ComputerSystem).SystemType -like 'ARM64*') { 'clangarm64' } else { 'clang64' }} # FIXME:'gimpenv' have buggy code about Windows paths. See: https://gitlab.gnome.org/GNOME/gimp/-/issues/12284 - - $GIMP_PREFIX = "$PWD\_install-$env:MSYSTEM_PREFIX".Replace('\', '/') + - $GIMP_PREFIX = "$PWD\_install-$env:MSYSTEM_PREFIX" timeout: 30m .win_environ: &WIN_ENVIRON diff --git a/build/windows/2_build-gimp-msys2.ps1 b/build/windows/2_build-gimp-msys2.ps1 index 4925bc8dc8..6a39dc363d 100644 --- a/build/windows/2_build-gimp-msys2.ps1 +++ b/build/windows/2_build-gimp-msys2.ps1 @@ -33,7 +33,7 @@ if ($GITLAB_CI) if (-not $GIMP_PREFIX) { #FIXME:'gimpenv' have buggy code about Windows paths. See: https://gitlab.gnome.org/GNOME/gimp/-/issues/12284 - $GIMP_PREFIX = "$PWD\..\_install".Replace('\', '/') + $GIMP_PREFIX = "$PWD\..\_install" } Invoke-Expression ((Get-Content .gitlab-ci.yml | Select-String 'win_environ\[' -Context 0,7) -replace '> ','' -replace '- ','') diff --git a/meson.build b/meson.build index 0196279053..1ea94b5374 100644 --- a/meson.build +++ b/meson.build @@ -128,7 +128,7 @@ fs = import('fs') cc = meson.get_compiler('c') cxx = meson.get_compiler('cpp') -prefix = get_option('prefix') +prefix = get_option('prefix').replace('\\', '/') buildtype = get_option('buildtype') exec_ver = '-' + gimp_app_version