mailRe: [Relax-users] relax1.2.3 build failure


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by Chris MacRaild on March 13, 2006 - 11:31:
I get a segfault at the grid search in your test script whenever -fPIC
is used in the compile, using any of the permutations you suggested. eg:

bin/relax1.2.3> gcc -fPIC -I/usr/include/python2.4 -c -o
maths_fns/c_chi2.os maths_fns/c_chi2.c
maths_fns/c_chi2.c: In function ‘chi2’:
maths_fns/c_chi2.c:54: warning: cast from pointer to integer of
different size
bin/relax1.2.3> gcc -fPIC -I/usr/include/python2.4 -c -o
maths_fns/exponential.os maths_fns/exponential.c
maths_fns/exponential.c: In function ‘exponential’:
maths_fns/exponential.c:47: warning: cast from pointer to integer of
different size
bin/relax1.2.3> gcc -fPIC -I/usr/include/python2.4 -c -o
maths_fns/relax_fit.os maths_fns/relax_fit.c
maths_fns/relax_fit.c: In function ‘back_calc_I’:
maths_fns/relax_fit.c:158: warning: cast from pointer to integer of
different size
maths_fns/relax_fit.c:162: warning: cast from pointer to integer of
different size
bin/relax1.2.3> gcc -shared -o maths_fns/relax_fit.so
maths_fns/c_chi2.os maths_fns/exponential.os maths_fns/relax_fit.os

compiles ok but segfaults



Manual compile without -fPIC fails on the final gcc -shared command:

bin/relax1.2.3> gcc -shared -o maths_fns/relax_fit.so
maths_fns/c_chi2.os maths_fns/exponential.os maths_fns/relax_fit.os
/usr/lib64/gcc/x86_64-suse-linux/4.0.2/../../../../x86_64-suse-linux/bin/ld: 
maths_fns/c_chi2.os: relocation R_X86_64_32S against `back_calc' can not be 
used when making a shared object; recompile with -fPIC
maths_fns/c_chi2.os: could not read symbols: Bad value
collect2: ld returned 1 exit status



On Sun, 2006-03-12 at 18:42 +1100, Edward d'Auvergne wrote:
Actually as the chip architecture is different, maybe the commands

$ gcc -fPIC -I/usr/include/python2.4 -c -o maths_fns/c_chi2.os
maths_fns/c_chi2.c
$ gcc -fPIC -I/usr/include/python2.4 -c -o maths_fns/exponential.os
maths_fns/exponential.c
$ gcc -fPIC -I/usr/include/python2.4 -c -o maths_fns/relax_fit.os
maths_fns/relax_fit.c
$ gcc -shared -o maths_fns/relax_fit.so maths_fns/c_chi2.os
maths_fns/exponential.os maths_fns/relax_fit.os

will produce functional modules.  I forgot to mention that the bug
report is called 'bug #5473'.

Thanks,

Edward





Related Messages


Powered by MHonArc, Updated Tue Mar 14 05:40:25 2006