EddyRivasLab / easel

Sequence analysis library used by Eddy/Rivas lab code
Other
46 stars 26 forks source link

Enable position independent code compilation, via --enable-pic configure option #43

Closed nawrockie closed 4 years ago

nawrockie commented 4 years ago

Brings back code from aclocal.m4 of 0.43 release (bdfb76a) and puts it in m4/esl_pic_flags.m4 for detecting --enable-pic option to configure and calling ESL_PIC_FLAGS function that sets PIC_CFLAGS variable based on compiler. I didn't try too hard to match other conventions for m4 files in esl_pic_flags.m4, for fear that I would break something in the original 0.43 code, and because it wasn't entirely clear what those conventions were or how much you care about them.

Motivation for this is the Bio-Easel perl library, which requires position independent code to use easel as a library and call easel functions via Inline perl.

I tested configure with and without --enable-pic on: 1) gcc 7.3.0 (at NCBI) 2) Apple LLVM version 10.0.1 (clang-1001.0.46.4) (on my iMac) 3) gcc 4.8.5 20150623 (Red Hat 4.8.5-11) (at EBI)

Everything passed and looks good to me related to my changes, but unit test 4 failed on both gccs:

exercise 4 [ avx-utest] ... FAILED [crash!]

I verified this unit test also fails on the current revision in 'develop' branch (commit 6802644) Let me know if you want more info.