How libpython1.5.so
Michael Hudson
mwh21 at cam.ac.uk
Mon Apr 19 05:32:38 EDT 1999
"A.M. Kuchling" <amk1 at erols.com> writes:
> Nick Belshaw writes:
> > Whilst trying to get Python plugins to work on Gnumeric-0.23 I bumped up
> > against the need for libpython1.5.so.0.0.0
>
> Here's a patch to the top-level Makefile.in which adds a "shared"
> target. Can people please try this and see if it works on your
> favorite Unix variant?
It works on mine (bog standard redhat5.2/i686 glibc2 egcs 1.1.2) and
now gnumeric loads Python extensions! Yippee!
I had to make a small change to the patch, see below.
> It doesn't verify that you've compiled all the
> code with -fPIC or whatever's required; I'm not sure how to check or
> enforce that. (It could do "make clean ; make CCFLAGS=<whatever>",
> but is that too extreme?)
The proper answer is to use libtool I suppose. You need to build with
"make OPT='-g -O2 -fPIC'" rather then CCFLAGS, btw.
> Index: Makefile.in
> ===================================================================
> RCS file: /projects/cvsroot/python/dist/src/Makefile.in,v
> retrieving revision 1.80
> diff -C2 -r1.80 Makefile.in
> *** Makefile.in 1999/02/23 15:43:15 1.80
> --- Makefile.in 1999/04/19 00:53:28
> ***************
> *** 214,217 ****
> --- 214,226 ----
> libtool -o $(LDLIBRARY) -dynamic $(OTHER_LIBTOOL_OPT) $(LIBRARY) -framework System @LIBTOOL_CRUFT@
>
> + # Target to make a shared library containing the interpreter
> +
> + shared: $(LIBRARY)
> + test -d .shared || mkdir .shared ; \
> + (cd .shared;ar x ../$(LIBRARY); $(LDSHARED) -o ../libpython$(VERSION).$(SO) *.o ); \
-----------------------------------------------------------------------------^
This period shouldn't be here.
> + /bin/rm -rf ./.shared
> +
> +
> +
> $(SUBDIRS): Makefiles
>
>
> --
> A.M. Kuchling http://starship.python.net/crew/amk/
> Since I killed my son... the Dreaming has not been the same ... or perhaps I
> was no longer the same. I still had my obligations... But even the freedom of
> the Dreaming can be a cage, of a kind, my sister.
> -- Dream, in SANDMAN #69: "The Kindly Ones:13"
Thanks a lot!
Michael
More information about the Python-list
mailing list