New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fatal relocation error with Cliquer library on 64-bit Solaris and OpenSolaris #9833
Comments
comment:1
This is a general error in how Cliquer is adapted to/built for Sage. It is intended as a stand-alone program, and therefore contains You must (or should) not build [shared] libraries containing a Instead, use --- cliquer-1.2.p6/src/Makefile 2010-02-16 05:26:57.000000000 +0100
+++ cliquer-1.2.p6/patch/Makefile 2010-02-16 05:26:55.000000000 +0100
@@ -1,14 +1,29 @@
##### Configurable options:
+# Don't need to set any of these compiler variables. They have already been
+# set when running SAGE_ROOT/local/bin/sage-env as part of installing a
+# package.
## Compiler:
-CC=gcc
+# CC=gcc
#CC=cc
## Compiler flags:
# GCC: (also -march=pentium etc, for machine-dependent optimizing)
-CFLAGS=-Wall -O3 -fomit-frame-pointer -funroll-loops
+# Build in 64-bit mode on Mac OS X with an Intel processor.
+
+# Flags for building a dynamically linked shared object.
+# SAGESOFLAGS=""
+# ifeq (`uname`, Linux)
+# SAGESOFLAGS=-shared -Wl,-soname,libcliquer.so
+# endif
+# ifeq (`uname`, Darwin)
+# SAGESOFLAGS=-shared -dynamiclib
+# endif
+# ifeq (`uname`, SunOS)
+# SAGESOFLAGS=-G -Bdynamic
+# endif
# GCC w/ debugging:
#CFLAGS=-Wall -g -DINLINE=
@@ -36,8 +51,7 @@
$(CC) $(LDFLAGS) -o $@ testcases.o cliquer.o graph.o reorder.o
cl: cl.o cliquer.o graph.o reorder.o
- $(CC) $(LDFLAGS) -o $@ cl.o cliquer.o graph.o reorder.o
-
+ $(CC) $(LDFLAGS) $(SAGESOFLAGS) -o libcliquer.so cl.o cliquer.o graph.o reorder.o
cl.o testcases.o cliquer.o graph.o reorder.o: cliquer.h set.h graph.h misc.h reorder.h Makefile cliquerconf.h
Note the changes made to the This package really needs work (but there's - besides others - already a ticket (#9871) for an upstream update as well). The files in |
comment:4
Minh, Leif intended resolving #9870. I'm not sure what the procedure his here, and whether this should be closed now (since it's merged in sage-4.6.alpha1, or wait until it's merged in sage-4.6. I believe the latter is probably more appropriate, as it could potentially be found to be problematic and not get merged in 4.6 at all. Dave |
comment:5
I'm closing this ticket as a "duplicate" of #9871. Please reopen it, if the Cliquer relocation error remains or reappears. |
If a 64-bit version of Sage is built on OpenSolaris, Sage reports an error as soon as it is started.
The problem of fatal relocation errors is discussed on this Sun blog by Rod Evans.
A shared library should show no output from the following command:
But in a 64-bit builds of Sage on both OpenSolaris x64 and Solaris 10 on SPARC, but show output. The following is from an OpenSolaris machine, but similar is seen on a 64-bit SPARC build of Sage.
If this flag is found, then the link-editor thinks this file contains non-pic code.
Looking at the way the shared library is built on Solaris, it is different from other platforms.
Using just
was sufficient to produce a shared library which did not exhibit this problem. When Sage was started, Sage no longer produced the libcliquer error message, though it did fail to run properly.
There are in fact several other libraries in Sage that show show output using the
elfdump
command above.(These were observed on OpenSolaris x64. I've confirmed the same is true of libcliquer.so on 64-bit SPARC using
t2.math
, but I've not verified if all the other libraries show this problem. )I doubt whether these are the only issues preventing Sage running properly on 64-bit Solaris, but these should be resolved.
Since
spkg-check
file - see Cliquer has no spkg-check file, but there is a small test suite with the program #9767it makes sense to update Cliquer and sort out the Solaris and
spkg-check
issues at the same time.Dave
CC: @jhpalmieri @nathanncohen @jasongrout @jaapspies @sagetrac-mvngu @qed777
Component: porting: Solaris
Issue created by migration from https://trac.sagemath.org/ticket/9833
The text was updated successfully, but these errors were encountered: