Fix bcc.lua build issue in Ubuntu 17.04
authorYonghong Song <yhs@fb.com>
Fri, 30 Jun 2017 05:46:29 +0000 (22:46 -0700)
committerYonghong Song <yhs@fb.com>
Fri, 30 Jun 2017 05:46:29 +0000 (22:46 -0700)
commit08c825359232777efcf1262e6765ed26f7495e8d
treeba179fd6e2510aad0b0b78ff659d9434f01ffaab
parent96c1b8e045e2f3df49d6c44c9d8930a86623f12f
Fix bcc.lua build issue in Ubuntu 17.04

In fc25 box, gcc6.3.1 is configured with pie default off.
Here, pie stands for position independent execution.

In ubuntu 17.04, gcc6.3.0, however, is configured with
pie default on. The gcc driver automatically adds -pie
to the linker options.

Since bcc.lua build needs pie off, previously, -fno-pie
is passed to the compiler. -fno-pie is a gcc option
impacting the code generation and it didn't
negate the -pie option in the linker. The correct way
seems to use gcc linker option -no-pie which can
successfully cancel the default -pie in the linker.

Signed-off-by: Yonghong Song <yhs@fb.com>
src/lua/CMakeLists.txt