Re: [PATCH v2] meson: fix Windows build

2025-06-03 Thread Oleg Tolmatcev
Am Di., 3. Juni 2025 um 19:56 Uhr schrieb Stefan Hajnoczi : > > On Tue, Jun 3, 2025 at 1:00 PM Oleg Tolmatcev > wrote: > > > > Am Mo., 2. Juni 2025 um 20:45 Uhr schrieb Stefan Hajnoczi > > : > > > > > > > +try: > > > > +event_filename = os.path.relpath(event.filename) > > > > +ex

Re: [PATCH v2] meson: fix Windows build

2025-06-03 Thread Stefan Hajnoczi
On Tue, Jun 3, 2025 at 1:00 PM Oleg Tolmatcev wrote: > > Am Mo., 2. Juni 2025 um 20:45 Uhr schrieb Stefan Hajnoczi > : > > > > > +try: > > > +event_filename = os.path.relpath(event.filename) > > > +except ValueError: > > > +event_filename = event.filename > > > +event_

Re: [PATCH v2] meson: fix Windows build

2025-06-03 Thread Oleg Tolmatcev
Am Mo., 2. Juni 2025 um 20:45 Uhr schrieb Stefan Hajnoczi : > > > +try: > > +event_filename = os.path.relpath(event.filename) > > +except ValueError: > > +event_filename = event.filename > > +event_filename = PurePath(event_filename).as_posix() > > Please do this in one

Re: [PATCH v2] meson: fix Windows build

2025-06-02 Thread Stefan Hajnoczi
On Thu, May 29, 2025 at 4:55 AM oltolm wrote: > > The build failed when run on Windows. I replaced calls to Unix programs > like ´cat´ and ´true´ with calls to ´python´. I wrapped calls to > ´os.path.relpath´ in try-except because it can fail when the two paths > are on different drives. I made su

Re: [PATCH v2] meson: fix Windows build

2025-06-02 Thread Philippe Mathieu-Daudé
(Cc'ing maintainers) On 29/5/25 10:54, oltolm wrote: The build failed when run on Windows. I replaced calls to Unix programs like ´cat´ and ´true´ with calls to ´python´. I wrapped calls to ´os.path.relpath´ in try-except because it can fail when the two paths are on different drives. I made sur

[PATCH v2] meson: fix Windows build

2025-05-29 Thread oltolm
The build failed when run on Windows. I replaced calls to Unix programs like ´cat´ and ´true´ with calls to ´python´. I wrapped calls to ´os.path.relpath´ in try-except because it can fail when the two paths are on different drives. I made sure to convert the Windows paths to Unix paths to prevent