You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "James Peach (JIRA)" <ji...@apache.org> on 2014/06/12 00:31:07 UTC

[jira] [Comment Edited] (TS-2885) luajit build ignores compiler flags

    [ https://issues.apache.org/jira/browse/TS-2885?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14028497#comment-14028497 ] 

James Peach edited comment on TS-2885 at 6/11/14 10:30 PM:
-----------------------------------------------------------

It would be helpful to have a {{--disable-luajit}} option so that users can work around this kind of build problem. Alternatively (or in addition), {{--with-luajit}} to ask the build to use the LuaJIT from the OS rather than the bundled copy.


was (Author: jamespeach):
It would be helpful to have a {{--disable-luajit}} option so that users can work around this kind of build problem.

> luajit build ignores compiler flags
> -----------------------------------
>
>                 Key: TS-2885
>                 URL: https://issues.apache.org/jira/browse/TS-2885
>             Project: Traffic Server
>          Issue Type: Bug
>          Components: Build
>            Reporter: James Peach
>
> The luajit build ignores operator-supplied CFLAGS in certain circumstances, causing the build to break. For example, if you try to build Traffic Server as a position independent executable:
> {code}
> # The Q= is to get luajit to emit the complier line :-/
> $ ./configure CXXFLAGS=-fPIE CFLAGS=-fPIE Q=
> ...
> ==== Building LuaJIT 2.0.3 ====
> make -C src
> make[4]: Entering directory `/home/vagrant/trafficserver.git/lib/luajit/src'
> DYNLINK   libluajit.so
> cc   -shared -fPIC -Wl,-soname,libluajit-5.1.so.2   -o libluajit.so lj_vm_dyn.o lj_gc_dyn.o lj_err_dyn.o lj_char_dyn.o lj_bc_dyn.o lj_obj_dyn.o lj_str_dyn.o lj_tab_dyn.o lj_func_dyn.o lj_udata_dyn.o lj_meta_dyn.o lj_debug_dyn.o lj_state_dyn.o lj_dispatch_dyn.o lj_vmevent_dyn.o lj_vmmath_dyn.o lj_strscan_dyn.o lj_api_dyn.o lj_lex_dyn.o lj_parse_dyn.o lj_bcread_dyn.o lj_bcwrite_dyn.o lj_load_dyn.o lj_ir_dyn.o lj_opt_mem_dyn.o lj_opt_fold_dyn.o lj_opt_narrow_dyn.o lj_opt_dce_dyn.o lj_opt_loop_dyn.o lj_opt_split_dyn.o lj_opt_sink_dyn.o lj_mcode_dyn.o lj_snap_dyn.o lj_record_dyn.o lj_crecord_dyn.o lj_ffrecord_dyn.o lj_asm_dyn.o lj_trace_dyn.o lj_gdbjit_dyn.o lj_ctype_dyn.o lj_cdata_dyn.o lj_cconv_dyn.o lj_ccall_dyn.o lj_ccallback_dyn.o lj_carith_dyn.o lj_clib_dyn.o lj_cparse_dyn.o lj_lib_dyn.o lj_alloc_dyn.o lib_aux_dyn.o lib_base_dyn.o lib_math_dyn.o lib_bit_dyn.o lib_string_dyn.o lib_table_dyn.o lib_io_dyn.o lib_os_dyn.o lib_package_dyn.o lib_debug_dyn.o lib_jit_dyn.o lib_ffi_dyn.o lib_init_dyn.o -lm -ldl
> /usr/bin/ld: lj_err_dyn.o: relocation R_X86_64_TPOFF32 against `static_uex' can not be used when making a shared object; recompile with -fPIC
> lj_err_dyn.o: could not read symbols: Bad value
> collect2: ld returned 1 exit status
> {code}
> Note that it used {{-fPIC}} instead of {{-fPIE}}



--
This message was sent by Atlassian JIRA
(v6.2#6252)