[flang] Disable LTO when building the flang runtime
authorDavid Truby <david.truby@arm.com>
Fri, 18 Nov 2022 16:55:56 +0000 (16:55 +0000)
committerDavid Truby <david.truby@arm.com>
Mon, 9 Jan 2023 14:35:01 +0000 (14:35 +0000)
commit15e734fe6c6ee96a24574773f0c7492fd4bbb889
tree544e153acaa9cb760d5d3d88d87fcf28445d9023
parent22cafc73815852d9f92d4efd8a56c6abdfcc66de
[flang] Disable LTO when building the flang runtime

When building the flang runtime if LTO is enabled the archive file
contains LLVM IR rather than object code. Currently flang is not
LTO aware so cannot link this file to compiled Fortran code.

This patch disables LTO when building the flang runtime to avoid
this issue.

Differential Revision: https://reviews.llvm.org/D140016
flang/lib/Decimal/CMakeLists.txt
flang/runtime/CMakeLists.txt