The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxc/pull/3536

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
https://llvm.org/docs/LinkTimeOptimization.html

Signed-off-by: Christian Brauner <christian.brau...@ubuntu.com>
From 54ee77b5045101dfca2ae11993a6c08c3e362ff2 Mon Sep 17 00:00:00 2001
From: Christian Brauner <christian.brau...@ubuntu.com>
Date: Fri, 4 Sep 2020 17:53:53 +0200
Subject: [PATCH] configure: enable flto

https://llvm.org/docs/LinkTimeOptimization.html

Signed-off-by: Christian Brauner <christian.brau...@ubuntu.com>
---
 configure.ac | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/configure.ac b/configure.ac
index f58487f5d0..a85790fd6c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -765,9 +765,11 @@ AX_CHECK_COMPILE_FLAG([-Warray-bounds], [CFLAGS="$CFLAGS 
-Warray-bounds"],,[-Wer
 AX_CHECK_COMPILE_FLAG([-Wrestrict], [CFLAGS="$CFLAGS -Wrestrict"],,[-Werror])
 AX_CHECK_COMPILE_FLAG([-Wreturn-local-addr], [CFLAGS="$CFLAGS 
-Wreturn-local-addr"],,[-Werror])
 AX_CHECK_COMPILE_FLAG([-Wstringop-overflow], [CFLAGS="$CFLAGS 
-Wstringop-overflow"],,[-Werror])
+AX_CHECK_COMPILE_FLAG([-flto], [CFLAGS="$CFLAGS -flto"],,[-Werror])
 
 AX_CHECK_LINK_FLAG([-z relro], [LDFLAGS="$LDFLAGS -z relro"],,[])
 AX_CHECK_LINK_FLAG([-z now], [LDFLAGS="$LDFLAGS -z now"],,[])
+AX_CHECK_LINK_FLAG([-flto], [LDFLAGS="$LDFLAGS -flto"],,[])
 
 CFLAGS="$CFLAGS -Wvla -std=gnu11 -fms-extensions"
 if test "x$enable_werror" = "xyes"; then
_______________________________________________
lxc-devel mailing list
lxc-devel@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to