View Issue Details

IDProjectCategoryView StatusLast Update
0002372XdebugInstallationpublic2025-12-04 14:51
Reporternono303 Assigned To 
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Version3.5.0alpha2 
Fixed in Version3.5.0 
Summary0002372: Build failed on MSVC
Description

Hi,
Trying to compile 3.5.0alpha2 with php-8.5-dev (branch head) on Windows MSCV vs18 x64

  1. I have this error:
    ..\pecl\xdebug\src\lib\maps\maps.c(29): fatal error C1083: Impossible d'ouvrir le fichier include : 'win32/glob.h' : No such file or directory

Applied this

diff --git a/src/lib/maps/maps.c b/src/lib/maps/maps.c
index 560dff7e..59081221 100644
--- a/src/lib/maps/maps.c
+++ b/src/lib/maps/maps.c
@@ -16,6 +16,7 @@
 #include <stddef.h>
 #include <stdlib.h>

+#include "main/php_version.h"
 #if PHP_VERSION_ID >= 80500
 # include "php_glob.h"
 # define xdebug_glob php_glob
  1. Then I had this second error
    ..\pecl\xdebug\src\lib\maps\maps.c(89): error C2065: 'GLOB_NOMATCH' : identificateur non declare

    Applied this

diff --git a/src/lib/maps/maps.c b/src/lib/maps/maps.c
index 560dff7e..59081221 100644
--- a/src/lib/maps/maps.c
+++ b/src/lib/maps/maps.c
@@ -85,7 +86,7 @@ static void scan_directory(const char *dir)
        case 0: /* No error */
            break;

-       case GLOB_NOMATCH:
+       case PHP_GLOB_NOMATCH:
            xdebug_log_ex(XLOG_CHAN_PATHMAP, XLOG_DEBUG, "NOMATCH", "No map files found with pattern '%s'", scan_dir);
            xdfree(scan_dir);

So, with these two changes, it’s compile and seems to work well but it might need a review on how is included / managed PHP_GLOB for Windows build (like a #define GLOB_NOMATCH PHP_GLOB_NOMATCH...)

Tagscompilation, windows
Operating SystemWindows 11 x64
PHP Version8.5-dev

Activities

derick

2025-10-08 16:21

administrator   ~0007359

This makes no sense to me, as I've compiled dlls for Windows in CI for this release.

nono303

2025-10-08 16:54

reporter   ~0007360

As it’s seemed not possible to edit my own issue, here are some complements
Xdebug 3.5.0-alpha2 only failed at build time with php-8.5. it’s works with php-8.4 with same configure and make options (see log attached)
Ps: 8.5-dev is not available in "PHP Version"

derick

2025-10-22 09:08

administrator   ~0007364

Hmm, I thought my Ci was already building for PHP 8.5, but it seems it wasn't yet. I'll have a look.

(I've also added 8.5-dev to the version list)

derick

2025-10-22 09:12

administrator   ~0007365

Indeed: https://github.com/xdebug/xdebug/actions/runs/18711254605/job/53360072327#step:3:261

derick

2025-10-22 14:25

administrator   ~0007366

I have a PR at https://github.com/xdebug/xdebug/pull/1040 — it was a bit harder to do (right) then your initial patches.

However, I still get test failures and I can't figure out what is causing them: https://github.com/xdebug/xdebug/actions/runs/18719433952/job/53387513527

Something might have changed in how PHP handles (some) environment variables, or perhaps something is crashing. I don't have Windows locally, so I can't really investigate why they fail. If you could help with that, I would appreciate it.

nono303

2025-10-22 16:41

reporter   ~0007367

https://patch-diff.githubusercontent.com/raw/xdebug/xdebug/pull/1040.patch compile without errors (cf. build log)
\phpmaster\vs18\x64\php-src>nmake test TESTS=../pecl/xdebug/tests/debugger/ give same errors on my side
You can give me a php script to execute with all the check, debug & co. you want to do on my Windows build

derick

2025-11-12 15:23

administrator   ~0007411

After a rebase, the tests started working just fine. So I have now merged this. I'll make alpha3 in a moment.

nono303

2025-11-13 07:11

reporter   ~0007412

I confirm that alpha3 compile fine and tests are OK for me on my buildchain.
Thx