Commit Graph
100 Commits
Author SHA1 Message Date
Martin Storsjö 5d33931b6a run-lldb-tests: Convert a missed direct use of objcopy.exe to $OBJCOPY
This was missed in 299f03fd45.
2023-06-13 12:52:07 +03:00
Martin Storsjö 4fbff5e912 github: Rename the upload-artifacts.yml workflow
It can make the whole release, not only upload artifacts.
2023-06-03 19:53:04 +03:00
Martin Storsjö 7e8bcdc43c build-llvm: Bump to LLVM 16.0.5 2023-06-02 17:42:49 +03:00
Martin Storsjö ed1d727ed7 build-mingw-w64: Bump to the current version as of June 2nd 2023-06-02 17:42:00 +03:00
Martin Storsjö 5d63c28d85 docker: Upgrade to Ubuntu 20.04
Ubuntu 20.04 comes with CMake 3.16, so there's no need to install
a custom version of CMake for now (for LLVM 16.x; LLVM 17 will have
the requirement raised to CMake 3.20 though).

Also drop the workaround for git issues in the old version in
Ubuntu 18.04.

The latest releases that are built on GitHub Actions without
docker are based on Ubuntu 20.04 anyway, so there's less demand
for building this with an older version for the sake of
compatibility of the built binaries. For users using the built
docker image as such, having it based on a newer base distribution
is beneficial.
2023-06-01 19:54:57 +03:00
Martin Storsjö 64b27a1c56 github: Add a manual workflow for building and pushing docker images 2023-06-01 19:54:57 +03:00
Martin Storsjö bf58d32dc4 docker: Make the CMake download and extraction less verbose
The wget command can easily print 800 lines to the docker output
log, and the tar unpacking prints over 6000 lines.
2023-06-01 19:54:57 +03:00
Martin Storsjö 1d7cf51b96 github: Add a manual workflow for building extra msvcrt binaries
They can optionally be uploaded to a release.
2023-06-01 19:54:57 +03:00
Martin Storsjö 41c45dafd8 github: Generalize the linux-cross-windows job for other CRTs 2023-06-01 19:54:57 +03:00
Martin Storsjö 5cc5132bff github: Name the windows artifacts windows-ucrt-<arch>-toolchain 2023-06-01 19:54:57 +03:00
Martin Storsjö 1b9fb522f5 github: Rename the macos-toolchain artifact to macos-ucrt-toolchain 2023-06-01 19:54:00 +03:00
Martin Storsjö 1e982132d5 github: Rename the linux-aarch64-toolchain artifact to linux-ucrt-aarch64-toolchain 2023-06-01 11:25:03 +03:00
Martin Storsjö 6a296622e0 github: Rename the linux-toolchain artifact to linux-ucrt-x86_64-toolchain 2023-06-01 11:25:03 +03:00
Martin Storsjö 2f2114eed8 build-all: Add options for rebuilding runtimes only
This allows rebuilding runtimes with e.g. a different default CRT.
2023-06-01 11:25:03 +03:00
Martin Storsjö a7ff217a5b github: Allow creating a tag and release programmatically
This verifies that the chosen tag name matches what was set as
TAG in the workflow that artifacts are pulled from.
2023-06-01 11:24:37 +03:00
Martin Storsjö 87ab2cb43d github: Expose the job properties (TAG and versions) in an artifact too
While we use the job outputs since 18bd3665ac,
having the info available in an artifact makes it easier to
fetch this in later separate workflows.
2023-06-01 11:23:41 +03:00
Martin Storsjö bf2e255b5f github: Allow specifying either a commit or a branch for fetching artifacts 2023-06-01 11:23:04 +03:00
Martin Storsjö f03d94dbdc github: Update a comment 2023-06-01 11:20:55 +03:00
Martin Storsjö 37ec895756 github: Distinguish between push and scheduled pipelines when fetching artifacts 2023-05-31 11:11:38 +03:00
Martin Storsjö 3184cb2060 wrappers: Don't rely on "readlink -f"
Older macOS versions (macOS 12.2 at least) don't support this
option, while newer macOS versions do support it (macOS 12.6).

The solution is based on https://stackoverflow.com/a/1116890/3115956,
but simplified for this usecase.
2023-05-23 11:23:27 +03:00
Martin Storsjö fc5d2c9b21 github: Run on pull requests too 2023-05-23 11:22:57 +03:00
Martin Storsjö 274a30cff5 build-llvm: Bump to LLVM 16.0.4 2023-05-17 09:02:02 +03:00
Martin Storsjö 99701ab202 build-mingw-w64: Bump to the latest version as of May 17th 2023-05-17 09:01:43 +03:00
Martin Storsjö 995d3ac516 github: Run all the compiler-rt tests, on both i686 and x86_64
These tests should now all pass on both architectures; the
check-asan tests for the static CRT are skipped automatically,
the failures in check-interception have been fixed by compiling
the tests with the --large-address-aware flag, and the
check-asan-dynamic tests on i686 have been fixed - all by
Alvin Wong.
2023-05-05 08:27:15 +03:00
Martin Storsjö 001c3a2bcf build-llvm: Bump to LLVM 16.0.3 2023-05-03 22:49:42 +03:00
Martin Storsjö 4ad11c7bec build-mingw-w64: Bump to the current version as of May 3rd 2023-05-03 22:49:40 +03:00
Martin Storsjö 0b185b62d1 build-compiler-rt: Make the CMAKE_C_COMPILER_TARGET vendor field consistent
Currently, there's no practical difference if the spelling of this
triple is inconsistent, but if we'd enable e.g. the per-target
runtime directories, the exact spelling does make a difference.

For consistency, pass CMAKE_C_COMPILER_TARGET with the exact right
spelling everywhere.
2023-04-29 22:30:41 +03:00
Martin Storsjö 06ff1fdd4f Revert "build-compiler-rt: Stop setting CMAKE_*_COMPILER_WORKS"
This reverts commit 056cb22fb5.

The fix for avoiding needing to set CMAKE_*_COMPILER_WORKS,
which means setting CMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY
when intiailizing the CMake project setup, was only possible to
apply on compiler-rt/lib/builtins, not other similar projects
like libunwind/libcxxabi/libcxx - so it's expected to keep needing
to set the CMAKE_*_COMPILER_WORKS flags.

Therefore it's also possible that the code in compiler-rt/lib/builtins
could be reverted, as it does have some other minor inconveniences
(it causes some other feature detections to fail, even if they're
harmless within the builtins).

Thus keep setting CMAKE_*_COMPILER_WORKS everywhere consistently.
2023-04-29 22:26:35 +03:00
Martin Storsjö a8629002bf github: Do rudimentary testing of the cross-built aarch64 toolchain with qemu
Verify that it can compile the tests in llvm-mingw's testsuite;
this should serve as a smoke test to see that the toolchain is
correctly assembled.
2023-04-28 10:04:39 +03:00
Martin Storsjö 0e13ea4e5a build-llvm: Bump to LLVM 16.0.2
A couple relevant changes since 16.0.0:
- Fix compilation for ARM (failures in generating SEH unwind info)
  for very specific cases
- Link the ASAN DLL before other libs and objects, to make sure it gets
  initialized as early as possible
- Allow double backslashes in the PATH in ASAN
- Allow llvm-rc to look for a clang executable named "clang-16", if the
  other alternatives aren't available
- Improve the performance of buffered raw_ostream within LLVM
2023-04-27 10:50:36 +03:00
Martin Storsjö cc197e4ae6 build-mingw-w64: Bump to the current version from April 24th 2023-04-27 10:50:36 +03:00
Martin Storsjö 46215b2510 build-python: Bump to Python 3.10.11 2023-04-27 10:50:36 +03:00
Martin Storsjö 4855077598 build-lldb-mi: Bump to the latest current version 2023-04-27 10:50:36 +03:00
Martin Storsjö 1fb5681e58 github: Add a job for cross compiling the toolchain for linux on aarch64 2023-04-27 10:47:51 +03:00
Martin Storsjö 1ab52ba4a3 github: Generalize the patterns for moving artifacts that are to be uploaded
Exclude the artifacts from the asserts build, if available.
2023-04-27 10:47:15 +03:00
Martin Storsjö 525489a018 github: Rename the linux-cross job to linux-cross-windows 2023-04-26 19:18:24 +03:00
Martin Storsjö 75c4092b8f Add a script for preparing a cross-built toolchain for the unix layout 2023-04-26 19:18:24 +03:00
Martin Storsjö 8f3c096ef5 build-all: Allow passing --host for cross compiling the tools 2023-04-26 19:18:24 +03:00
Martin Storsjö 06f44cda62 Support cross compilation to non-windows targets
Don't have --host/$HOST imply targeting Windows, but actually inspect
the target triple where necessary.
2023-04-26 19:18:24 +03:00
Martin Storsjö c49af4399a github: Skip dependencies (libxml2, terminfo) in linux builds that have little value in our context
The fewer dynamic library dependencies we have, the easier it is
to run the binaries on other linux distributions than the one it
was built on.

In the docker based releases, these libraries haven't been installed
and thus haven't been used so far.

The docker based releases haven't linked against zlib though, but
keep linking against that, since that should have a quite stable
ABI and not cause much binary compatibility issues.
2023-04-26 10:01:42 +03:00
Martin Storsjö af99275e2e Remove unnecessary empty cases in shell scripts 2023-04-26 10:01:21 +03:00
Martin Storsjö 21da44ac93 build-lldb-mi: Sync cross compilation logic improvements from build-llvm.sh 2023-04-26 10:01:21 +03:00
Martin Storsjö fbb0af91b3 readme: Mention and link to the nightly builds 2023-04-25 13:29:20 +03:00
Martin Storsjö 12434469b9 github: Add a separate manual workflow for uploading artifacts to a release 2023-04-25 09:59:28 +03:00
Martin Storsjö 586a9acf02 github: Upload all artifacts from scheduled builds to the "nightly" release 2023-04-25 09:59:28 +03:00
Martin Storsjö 48276b7f42 github: Remove the unnecessary arch suffix on the intermediate install directory in the linux-cross jobs
The packaged directory gets renamed to include a suffix in the end
anyway.
2023-04-25 09:59:28 +03:00
Martin Storsjö 7a5dfaf469 github: Run the non-asserts linux build on 20.04
This should make the produced artifact more widely compatible.

Releases built with release.sh with the dockerfile are currently
based on Ubuntu 18.04 though, and are more shielded from potential
extra libraries that are found during the build.
2023-04-25 09:59:28 +03:00
Martin Storsjö 8abf794331 github: Produce artifacts with names that match the actual releases 2023-04-25 09:59:28 +03:00
Martin Storsjö 085653b6c8 github: Rename the "get-versions" step to "prepare" 2023-04-25 09:59:28 +03:00
Martin Storsjö 8d1d6f9947 github: Set the versions to build in scheduled builds via the GHA "env" field
For non scheduled builds, those env variables are just left empty.

This is much neater than using the "versions" file, and uses much
fewer lines of code.

We still probably want to bundle a file labelling what versions
it contains in the built packages though; give that file a
.txt suffix.
2023-04-25 09:58:25 +03:00
Martin Storsjö 18bd3665ac github: Use job outputs instead of a "versions" artifact/file
This is more idiomatic, requires fewer lines of code and doesn't
require passing an actual file along (unless we want to).
2023-04-24 11:36:22 +03:00
Martin Storsjö f0b14f9e20 github: Sync the cpython-mingw branch used with build-python.sh 2023-04-22 23:18:55 +03:00
Martin Storsjö afedda2cbd github: Remove a redundant "update: false" for setup-msys2
"update: false" is the default, and we don't specify it elsewhere.
2023-04-22 01:28:26 +03:00
Martin Storsjö 240fb4205b release-macos: Remove the explicit call to strip-llvm.sh
Since e56fb975e9, strip-llvm.sh
has been called as part of build-all.sh.

This avoid stripping out files that have been installed into the
share directory by later stages in build-all.sh. (strip-llvm.sh
currently flat out removes the share directory.)
2023-04-20 14:00:24 +03:00
Martin Storsjö dd24bdd749 strip-llvm: Don't strip out clang-target-wrapper
This avoids losing files if running strip-llvm after build-all.sh
instead of as part of it.
2023-04-20 14:00:24 +03:00
Martin Storsjö aa173210ff strip-llvm: Don't wipe out the whole share directory
Keep removing the same items installed by LLVM as before (although
that could be revisited too).

This avoids removing unintended files if running strip-llvm after
the installation of other components.
2023-04-20 14:00:24 +03:00
Martin Storsjö 3f72fcbabf strip-llvm: Strip out some darwin specific files 2023-04-20 14:00:24 +03:00
Martin Storsjö 0b3fc13a42 github: Add a job for running compiler-rt tests 2023-04-20 10:40:35 +03:00
Martin Storsjö 5d778657c2 github: Include libcxxabi and libunwind tests in the test-libcxx job too
These test suites now pass in the latest git main.

This target isn't run automatically anywhere, but in case the
target is enabled to run the tests, include the libcxxabi and libunwind
test suites too.
2023-04-20 10:36:19 +03:00
Martin Storsjö 0ab70b67d8 github: Remove ignores for failing ffmpeg tests
These no longer fail; they were fixed in ffmpeg in commit
76b33704b628248d77ed61cbef9ecd9430a4b6c5 in July 2022; we currently
test a pinned 6.0 release, where this fix is included.
2023-04-19 23:18:17 +03:00
Martin Storsjö b495c39a6d github: Use less specific filenames in the ffmpeg test jobs
This reduces the differences if using a proper release tarball
instead of an artifact from an earlier step (if testing parts of
the workflow by modifying it).
2023-04-19 23:18:17 +03:00
Martin Storsjö 5264f99ade github: Stop setting PYTHON_EXECUTABLE in the openmp test job
This shouldn't be necessary any longer since commit
40079637569f999015eaf3f7e137a63b2c8ade92 in llvm-project (in
December 2022).
2023-04-11 11:06:43 +03:00
Martin Storsjö 8189893403 github: Update a comment about the openmp test job
We're now on 16.x, and the tests do pass, but we still skip running
these tests on regular pushes - we only do them for the scheduled
nightly builds.
2023-04-11 11:06:43 +03:00
Martin Storsjö c1d6c39d33 Revert "github: Disable building lldb-mi in the scheduled cross builds"
This reverts commit 1b216b6fdf.

It's now compatible with current llvm versions.
2023-04-11 00:08:38 +03:00
Martin Storsjö d347b2022c Revert "build-lldb-mi: Skip building lldb-mi, as it's incompatible with current llvm versions"
This reverts commit 49950ae6be.

It's now compatible with current llvm versions.
2023-04-11 00:08:27 +03:00
Martin Storsjö dc2c2e0727 build-lldb-mi: Bump to a version that builds in C++17 mode
This is compatible with LLVM 16 and git main.
2023-04-10 11:57:08 +03:00
Martin Storsjö 0b68b891e0 build-all: Remove stray/leftover help for an unsupported option
This was added in 050b4ef701, but this
option was never supported to be passed on to build-llvm.sh from
here.

Additionally, this option was removed entirely from build-llvm.sh
in bd190c04c3.
2023-03-28 11:38:53 +03:00
Martin Storsjö 51abc9117f build-llvm: Enable LLD_DEFAULT_LD_LLD_IS_MINGW for builds on Windows
This makes sure we get the right behaviour (and output from "--help")
if ld.lld.exe is called directly without a wrapper setting the -m
parameter.
2023-03-22 23:32:53 +02:00
Martin Storsjö 8ee28e2938 build-llvm: Enable the custom defaults for Clang when building natively on MSYS2
Normally our releases are cross-built from Linux, but we also
support building the toolchain in MSYS2. Enable the custom defaults
when building the toolchain in MSYS2 too.
2023-03-22 23:32:53 +02:00
Martin Storsjö 4a579e1562 build-llvm: Remove an unused variable
This became unused in 8536b740e3.
2023-03-22 23:32:53 +02:00
Martin Storsjö d5c9fb3e04 build-mingw-w64: Pass --disable-dependency-tracking when configuring mingw-w64-crt on MSYS2
Configuring the mingw-w64-crt build takes a really long time on MSYS2;
the generating Makefile phase takes easily 4-5 minutes, when the rest
of configure runs in a matter of seconds. By passing
--disable-dependency-tracking, the whole configure for mingw-w64-crt
takes 11-14 seconds where it previously took many mnutes.

This comes with the drawback that these build directories aren't
suitable for incremental development (unless manual care is taken
to rebuild all necessary files), but these builds are mostly done
for non-interactive building.

Thanks to Jeremy Drake for realizing this optimization opportunity,
and LIU Hao for making me aware of it.
2023-03-21 12:07:02 +02:00
Martin Storsjö 1ca5ecf22f build-llvm: Update to the final 16.0.0 release
Notable changes for mingw users are:
- Support demangling C++ symbols on i386 in LLVM backtraces
- Don't report fatal errors when the output pipe is closed on Windows
- Ignore file access times on Windows when comparing whether files are
  equivalent
2023-03-20 12:23:47 +02:00
Martin Storsjö 2994becbbe build-mingw-w64: Bump to the current version fron March 20th
Notable changes:
- Support for _FORTIFY_SOURCE=3
- Fortification of [v]s[n]printf for UCRT
- Add the __gets_chk function, for fortification of the (highly
  deprecated) gets function
- Fixed the inconsistent signature of the wcstok function on UCRT
  in string.h
- Allow opting out from SEH based setjmp/longjmp by defining
  __USE_MINGW_SETJMP_NON_SEH before including setjmp.h

And as usual, lots of other minor updates.
2023-03-20 12:23:47 +02:00
Martin Storsjö 1022231482 wrappers: Try to resolve short form 8.3 file names into long form
This allows the wrappers to invoke the right tool with the right
options, even when the wrapper was invoked with an obfuscated
short form file name.

This happens e.g. when CMake/Ninja invokes the tools from a path
that contains spaces.
2023-03-12 00:08:13 +02:00
Martin Storsjö b592dd734e tests: Consistently use <triple>-gcc instead of <triple>-clang for cross compilation
While <triple>-clang is more specific, using <triple>-gcc allows
testing GCC based toolchains (somewhat) with the same scripts/makefiles
too.
2023-03-11 23:59:19 +02:00
Martin Storsjö 3844ad9a95 build-python: Use $HOST-gcc instead of $HOST-clang for cross compilation
While $HOST-clang is more specific for the use in llvm-mingw,
using the form $HOST-gcc would allow using the same script in
GCC based environments too.
2023-03-11 23:53:10 +02:00
Martin Storsjö 75dc6fd314 strip-llvm: Strip out the new amdgpu-arch and nvptx-arch executables
These weren't present in LLVM 15.x.
2023-03-11 23:29:12 +02:00
Martin Storsjö 9e612d76f9 github: Stop setting LIBCXX_TARGET_INFO for the libcxx test setup
This variable is no longer needed/used.
2023-03-10 20:05:47 +02:00
Martin Storsjö 04ec21bea7 github: Run tests with the ffmpeg 6.0 release instead of 5.1.2 2023-03-09 13:54:10 +02:00
Martin Storsjö 22790a89f4 github: Don't run builds for tags, only pushes to branches
There's no need to rerun all the builds when pushing a tag.
2023-02-10 23:56:30 +02:00
Martin Storsjö 8536b740e3 build-llvm: Use the new LLVM_NATIVE_TOOL_DIR option for pointing out preexisting native tools
This allows setting one variable pointing at all tools, instead
of setting multiple individual options for all tools.
2023-01-29 01:13:48 +02:00
Martin Storsjö c49460aa86 github: Add setup for running libcxx's tests on the built toolchain
Keep this disabled by default (since it takes a fair amount of time
and has good test coverage upstream), but including it in disabled
form so that it's easy to enable temporarily for testing occasionally.

Libcxx does test the mingw configuration in their own CI (with an older
pinned release of the compiler), so this is mostly redundant, and
primarily relevant for testing that the very latest compiler (and
python setup) works for the tests.
2023-01-29 01:13:39 +02:00
Martin Storsjö dfd4c31f2e test: Simplify handling of OpenMP
It is available on all architectures by default now. Keep the
HAVE_OPENMP conditional within the test makefile to allow custom
testing without having it available.
2023-01-29 01:09:17 +02:00
Martin Storsjö 6b8725333a build-openmp: Build the OpenMP library on all architectures
Since a356782426f5bf54a00570e1f925345e5fda7b2e in llvm-project,
OpenMP can be built for mingw/aarch64, since
fb947c358661b3bd3d5e1fa776ec74cc0f308854 it should work correctly
in all currently tested cases, and since
97958c9bb83cec44b6ce13e732b53de0171a5d43 it can be built for
mingw/armv7.
2023-01-29 01:09:17 +02:00
Martin Storsjö c31664aba4 Dockerfile.dev: Merge the ssp tests up with an earlier block 2023-01-29 01:09:17 +02:00
Martin Storsjö fb67e16120 build-all: Stop requiring curl to be available
Curl (or wget) isn't required for fetching libssp any longer,
so don't require it while running build-all.sh.

(It's still required by build-cross-tools.sh, for build-make.sh
though.)
2023-01-29 01:09:17 +02:00
Martin Storsjö 4ba7adbb90 run-tests: Check for the error messages from ssp routines
Since using the ssp routines from mingw-w64 instead of those from
GCC's libssp, these messages are included in the piped output of
the process, so we can check for the right messages.
2023-01-29 01:09:17 +02:00
Martin Storsjö abc36e1f7c run-tests: Stop trying to copy libssp-0.dll
We no longer build that DLL.
2023-01-29 01:09:17 +02:00
Martin Storsjö 4ee7cc97de build-libssp: Stop building the real libssp from GCC
As mingw-w64 now provides these routines, we no longer need to build
the original library from GCC.

As building with -fstack-protector-strong still links with -lssp
(and -lssp_nonshared), we still need to provide libraries with these
names, but they can be empty dummy libraries.
2023-01-29 01:09:17 +02:00
Martin Storsjö ef9806fc0a run-tests: Stop explicitly linking against -lssp for the fortification test
Since libmingwex.a provides these routines now, we don't need to
specify -lssp manually.
2023-01-29 01:09:17 +02:00
Martin Storsjö 36f8c1359e Switch the default to enabling CFGuard in all individual build-* scripts 2023-01-29 01:09:17 +02:00
Martin Storsjö d07bb8889b build-python: Bump to Python 3.10.9 2023-01-29 01:09:17 +02:00
Martin Storsjö 26ae975a6a build-mingw-w64: Bump to the current version from January 28th
Notable changes:
- Support for CFGuard
- SSP routines are bundled as part of libmingwex, rendering the separate
  libssp from GCC unnecessary

Plus lots and lots of various other minor fixes and improvements.
2023-01-29 01:09:17 +02:00
Martin Storsjö e06702461f build-llvm: Update to llvm 16.0.0 RC1
Notable changes are:
- Emit -exclude-symbols: directives for hidden symbol visibility (supported
  by LLD 15 and binutils ld 2.40). This allows reducing the number of
  exported symbols in e.g. libLLVM-*.dll.
- Support for CFGuard on mingw, thanks to Alvin Wong!
- LLD now picks up libraries named <name>.lib when linking with -l<name>,
  even if -static was specified
- Fixed SEH unwind info on AArch64 if using the AArch64 feature
  PAC (Pointer Authentication Code) - previously, unwinding would fail if
  running on a system that actually does use the feature. (The consistency
  of AArch64 SEH unwind info was also improved for other cases.)
- Fixed stack alignment on AArch64, for stack frames large enough to
  require stack probing
- Fixed llvm-objcopy corrupting some cases of object files with empty sections
- Improvements to LLDB, where it now uses the regular symbol list of DLLs
  (including non-exported symbols)
- OpenMP now can be built and works on armv7 and aarch64 (in mingw
  configurations)

Notable for simplifying how to cross compile LLVM itself:
- The preexisting build machine tools can be specified with one single option
  LLVM_NATIVE_TOOL_DIR instead of passing a number of variables like
  LLVM_TABLEGEN, CLANG_TABLEGEN etc.
2023-01-29 01:08:43 +02:00
Martin Storsjö 49950ae6be build-lldb-mi: Skip building lldb-mi, as it's incompatible with current llvm versions
Since the switch to building in C++17 mode in llvm 16, lldb-mi is
incompatible, until lldb-mi itself switches to building with C++17 too.

A fix has been suggested upstream in
https://github.com/lldb-tools/lldb-mi/pull/102, but there hasn't
been any action on it so far.
2023-01-29 01:06:10 +02:00
Martin Storsjö 241a1cd148 test: Prepare the test scripts for testing native Windows tools via WSL
Use the TOOLEXT variable in run-tests.sh in the same way as in the
Makefile. The Makefile sets this variable automatically if invoked
by mingw32-make, but if running run-tests.sh in WSL with native
Windows compilers, then we need to set TOOLEXT manually when calling
run-tests.sh.

Allow skipping the cfguard failure tests when run in such a
configuration, since Linux make in WSL can't easily run cmd.exe
like in MSYS2.
2023-01-21 23:48:24 +02:00
Martin Storsjö 9d96e5745f Include the llvm-size tool like other binutils-like tools
This was requested in
https://github.com/mstorsjo/llvm-mingw/issues/320.
2023-01-12 14:11:03 +02:00
Martin Storsjö bd190c04c3 build-llvm: Remove the --symlink-projects option
This option was mostly relevant for making it possible to share
ccache between builds in different directories, due to specific
logic in CMake's Ninja generator, which used relative paths for
sources as long as they were below the main source directory
(llvm-project/llvm). This option wasn't usable on Windows.

Since CMake 3.21.0, this option no longer worked for the intended
purpose - that version of CMake changed the Ninja generator to
always use absolute paths to sources, for consistency with other
generators and to simplify things. (See commit
c564a3e3fff52ef811291c5ba8fb07a5a1b47f97 in CMake's git history.)

It is still possible to achieve ccache sharing across build
directories anyway, by setting the ccache option CCACHE_BASEDIR,
which makes ccache rewrite absolute paths to relative ones within
that tree, and by setting the LLVM CMake option
LLVM_USE_RELATIVE_PATHS_IN_FILES=ON, which adds -ffile-prefix-map
options to the compiler, to remap source paths as they are exposed
in the generated code.

(Strictly speaking, LLVM_USE_RELATIVE_PATHS_IN_FILES is only needed
if debug info is enabled. On its own, without CCACHE_BASEDIR, that
option produces compiler output that is identical across build
directories - but the absolute paths end up in the preprocessor output
in source file/line comments, which makes ccache fail to reuse the cache.)
2023-01-10 12:01:06 +02:00
Martin Storsjö 04c623fe8b crt-test: Improve the check for testing the >64 bit range for strtold
The previous condition failed to identify that macOS on aarch64
also has long double equal to regular double.
2022-12-01 12:13:20 +02:00
Martin Storsjö 21c279aab5 crt-test: Skip the NAN preservation tests on platforms other than mingw
This part of the tests does pass on glibc on x86_64 and on MSVC,
but fails on macOS (for some functions) and on glibc on aarch64
(for one function).

This is a somewhat overly pedantic test, but is useful for checking
the NAN preservation behaviour when modifying implementations.

Also print the sign bit explicitly - not all printf implementations
distinguish between NAN and -NAN when printed.
2022-12-01 12:07:32 +02:00