1 |
François, |
2 |
|
3 |
Singular -- good. I do get -fPIC compile issues here on my amd64: |
4 |
|
5 |
g++ -shared -o libsingular.so \ |
6 |
libsingular-tesths.o iparith.o mpsr_Tok.o claptmpl.o \ |
7 |
grammar.o scanner.o attrib.o eigenval_ip.o extra.o fehelp.o |
8 |
feOpt.o ipassign.o ipconv.o ipid.o iplib.o ipprint.o ipshell.o lists.o |
9 |
sdb.o fglm.o interpolation.o silink.o subexpr.o janet.o wrapper.o |
10 |
libparse.o sing_win.o gms.o pcv.o maps_ip.o walk.o walk_ip.o cntrlc.o |
11 |
misc.o calcSVD.o slInit_Dynamic.o -lkernel -L../kernel -L../factory |
12 |
-L../libfac |
13 |
-L/var/tmp/portage/sci-mathematics/sage-singular-3.1.0.4.20100214/work/singular-3-1-0-4-20100214/src/build/opt/sage/local/lib64 |
14 |
-lsingfac -lsingcf -lntl -lreadline -lgmp -lomalloc |
15 |
/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: |
16 |
libsingular-tesths.o: relocation R_X86_64_32 against `a local symbol' |
17 |
can not be used when making a shared object; recompile with -fPIC |
18 |
|
19 |
I've tinkered with this in the past and the following allowed building |
20 |
to proceed. |
21 |
|
22 |
sed -e "s:@CFLAGS@:@CFLAGS@ -fPIC:" -e |
23 |
"s:@CXXFLAGS@:@CXXFLAGS@ -fPIC:" \ |
24 |
-i */Makefile.in || die "failed to fix CFLAGS in |
25 |
Makefile.in files" |
26 |
sed -e "s:@CFLAGS@:@CFLAGS@ -fPIC:" -e |
27 |
"s:@CXXFLAGS@:@CXXFLAGS@ -fPIC:" \ |
28 |
-i factory/GNUmakefile.in || die "failed to fix CFLAGS |
29 |
in GNUmakefile.in" |
30 |
sed -e "s:{libdir} \${LIBSINGULAR_LIBS}:{libdir} -Wl,-soname |
31 |
\${LIBSINGULAR_LIBS}:" \ |
32 |
-i Singular/Makefile.in || die "failed to fix LDFLAGS |
33 |
in Makefile.in" |
34 |
|
35 |
but this may not be the best way to fix things. I did notice that Sage |
36 |
builds Singular with -fPIC for all architectures. |
37 |
|
38 |
Steve |