autotools: simplify configuration in tests, examples

- GHA/windows: make a mingw autotools build static only.
- GHA/windows: fix a CI script issue with the build above.
- src: fix to pass `LIBCURL_PC_LIBS_PRIVATE` instead of `LINKFLAGS`.
  This makes the libs propagate to tunits, making the local hack there
  unnecessary. `LINKFLAGS` had this single use in the repo, and it was
  empty in local tests.
- tests: drop passing redundant `LIBCURL_PC_LDFLAGS_PRIVATE`.
- tests: drop redundant target name from config variables.
- examples, tests/client: drop `LIBDIR` temp variables with single uses.
- examples, tests: formatting to sync `Makefile.am` scripts with each
  other.

Closes #17661
This commit is contained in:
Viktor Szakats 2025-06-18 10:33:15 +02:00
parent af309fb17b
commit ea782134e5
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
8 changed files with 19 additions and 39 deletions

View file

@ -110,7 +110,7 @@ if BUILD_UNITTESTS
noinst_LTLIBRARIES = libcurltool.la
libcurltool_la_CPPFLAGS = $(AM_CPPFLAGS) -DCURL_STATICLIB -DUNITTESTS
libcurltool_la_CFLAGS =
libcurltool_la_LDFLAGS = -static $(LINKFLAGS)
libcurltool_la_LDFLAGS = -static $(LIBCURL_PC_LIBS_PRIVATE)
if USE_UNITY
libcurltool_unity.c: $(top_srcdir)/scripts/mk-unity.pl $(CURL_CFILES) $(curl_CURLX)
@PERL@ $(top_srcdir)/scripts/mk-unity.pl --include $(CURL_CFILES) $(curl_CURLX) > libcurltool_unity.c