Skip to content

Commit 9504fcf

Browse files
authored
Move ARG_ENABLE() "macros" out of confutils.js (phpGH-16398)
While these "macros" work perfectly fine in confutils, it is somewhat strange to have these two there, while all others are in config.w32 files. In particular, there is no need for a `MODE_PHPIZE` guard, since there are already config.w32 and config.w32.phpize.in. However, we need to replace the semicolon in the helptext, because the regex which parses ARG_(ENABLE|WITH) calls is restricted, and does not accept semicolons.
1 parent a00c734 commit 9504fcf

File tree

3 files changed

+6
-9
lines changed

3 files changed

+6
-9
lines changed

win32/build/config.w32

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -396,3 +396,7 @@ ARG_ENABLE("native-intrinsics", "Comma separated list of intrinsic optimizations
396396
might not work properly, if the chosen instruction sets are not available on the target \
397397
processor.", "no");
398398
toolset_setup_intrinsic_cflags();
399+
400+
ARG_ENABLE('snapshot-build', 'Build a snapshot: turns on everything it can and ignores build errors', 'no');
401+
402+
ARG_ENABLE('vs-link-compat', 'Allow linking of libraries built with compatible versions of VS toolset', 'yes');

win32/build/config.w32.phpize.in

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,3 +143,5 @@ ARG_ENABLE("native-intrinsics", "Comma separated list of intrinsic optimizations
143143
might not work properly, if the optimizations are not available on the target \
144144
processor.", "no");
145145
toolset_setup_intrinsic_cflags();
146+
147+
ARG_ENABLE('vs-link-compat', 'Allow linking of libraries built with compatible versions of VS toolset', 'yes');

win32/build/confutils.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2898,9 +2898,6 @@ function PHP_INSTALL_HEADERS(dir, headers_list)
28982898
// and you can then build everything, ignoring fatal errors within a module
28992899
// by running "nmake snap"
29002900
PHP_SNAPSHOT_BUILD = "no";
2901-
if (!MODE_PHPIZE) {
2902-
ARG_ENABLE('snapshot-build', 'Build a snapshot; turns on everything it can and ignores build errors', 'no');
2903-
}
29042901

29052902
function toolset_option_handle()
29062903
{
@@ -3766,9 +3763,3 @@ function setup_verbosity()
37663763
CMD_MOD2 = "@";
37673764
}
37683765
}
3769-
3770-
try {
3771-
ARG_ENABLE('vs-link-compat', 'Allow linking of libraries built with compatible versions of VS toolset', 'yes');
3772-
} catch (e) {
3773-
STDOUT.WriteLine("problem: " + e);
3774-
}

0 commit comments

Comments
 (0)