在 2026-1-20 00:24, Markus Muetzel 写道:
Am 19.01.2026 um 15:17 schrieb Markus Muetzel:
I inserted an additional patch after the first one that should make sure that the configure script is re-run if necessary on incremental `make`.


There is no need to run `autoconf` when any of the input files for the files that are generated by the `configure` scripts changed. Running `configure` on an incremental `make` is sufficient in that case.

Addressing that is the only change with respect to the patch series I sent 
earlier.

There are quite a few issues in these patches:


diff --git a/mingw-w64-headers/Makefile.am b/mingw-w64-headers/Makefile.am
index 6ebeda477..af260e795 100644
--- a/mingw-w64-headers/Makefile.am
+++ b/mingw-w64-headers/Makefile.am
@@ -21,7 +21,6 @@ gdiplushead_HEADERS = @GDIPLUSHEAD_LIST@
 wrlhead_HEADERS = @WRLHEAD_LIST@
 wrlwrappershead_HEADERS = @WRLWRAPPERSHEAD_LIST@
 mingwhelperhead_HEADERS = @MINGWHELPERHEAD_LIST@
-nodist_sdkshead_HEADERS = _mingw_ddk.h
 noinst_HEADERS = crt/sdks/_mingw_ddk.h.in

Removal of `nodist_sdkshead_HEADERS` causes it to be no longer installed. `noinst_HEADERS` is self-contradiction and doesn't do anything. So these two lines can just be

-nodist_sdkshead_HEADERS = _mingw_ddk.h
-noinst_HEADERS = crt/sdks/_mingw_ddk.h.in
+sdkshead_HEADERS = crt/sdks/_mingw_ddk.h


From 68045e908d6dea01528f529b7a0f82c2f51618b1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Markus=20M=C3=BCtzel?= <[email protected]>
Date: Mon, 19 Jan 2026 15:05:25 +0100
Subject: [PATCH 2/4] Trigger a re-run of the configure scripts on incremental
 make if needed

I think this is not correct. config.status has automatic dependencies on input files of `AC_CONFIG_FILES`, so you don't do `CONFIG_STATUS_DEPENDENCIES = Makefile.in` which is just tautology.

I don't know whether running config.status from top-level builddir would update a config file in subdirectories. I decide to drop this patch for now.


+AM_CFLAGS=$(sysincludes) @ADD_C_CXX_WARNING_FLAGS@ @ADD_C_ONLY_WARNING_FLAGS@ 
$(TEST_CFLAGS) -Wno-missing-prototypes
+AM_CXXFLAGS=$(sysincludes) @ADD_C_CXX_WARNING_FLAGS@ 
@ADD_CXX_ONLY_WARNING_FLAGS@ $(TEST_CFLAGS)
+if LIB64
+AM_LDFLAGS=-L$(top_builddir)/lib64
+else
+if LIB32
+AM_LDFLAGS=-L$(top_builddir)/lib32
+else
+if LIBARM64
+AM_LDFLAGS=-L$(top_builddir)/libarm64
+else
+if LIBARM32
+AM_LDFLAGS=-L$(top_builddir)/libarm32
+endif
+endif
+endif
+endif

Why so many `endif`s? Isn't this just

+if LIB64
+AM_LDFLAGS = -L$(top_builddir)/lib64
+endif
+if LIB32
+AM_LDFLAGS = -L$(top_builddir)/lib32
+endif
+if LIBARM64
+AM_LDFLAGS = -L$(top_builddir)/libarm64
+endif
+if LIBARM32
+AM_LDFLAGS = -L$(top_builddir)/libarm32
+endif


And finally, I have tried this locally in MSYS2. It's a very weird setup: Because the CRT configure checks for a working compiler, it's necessary to configure everything with headers installed; then in order to test these patches, I uninstall headers and run `make -j32` from top-level build directory. This seems working, with either `--enable-sdk=all` or `--enable-sdk=no`.

So the combined changes are: https://github.com/lhmouse/mingw-w64/compare/0c21179312f87e4674ecbaf1b3e7562cbb625c44...670126daab0f46f1fd5d7844290e838eddee68d5

But this does not work quite well on our CI: https://github.com/lhmouse/mingw-w64/actions/runs/21158997374/job/60849719833#step:5:226





--
Best regards,
LIU Hao

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to