Build Question: How to Add -Wl, --option Before Objects In Setup.py?

Cyd Haselton chaselton at gmail.com
Tue Oct 28 21:40:49 CET 2014


On Tue, Oct 28, 2014 at 3:11 AM, Ned Deily <nad at acm.org> wrote:
> In article
> <CAHu5PrY-T=DT3wOg-Y+Va9WgwBV3w9d7M-tu=_N-CNgWsSzGpg at mail.gmail.com>,
>  Cyd Haselton <chaselton at gmail.com> wrote:
> [...]
>> I'm building python on an Android device in the KBOX
>> environment...which simulates a Unix type filesystem.
>> Python isn't installed; I'm building from sources (2.7.8) with GCC
>> 4.8.0 and make.
>>
>> The problem with the LDFLAGS approach is that some of the libraries
>> that must be linked (-lc -ldl) do not need the --allow-shlib-undefined
>> option...it's only the lpython2.7 that does.  Any way to do this?
>
> Sorry, I have no experience with that environment nor an understanding
> of why you need to specify --allow-shlib-undefined (it seems to be the
> default in some versions of ld).  You could look at and, if necessary,
> modify Lib/distutils, the part of the Python standard library that
> builds extension modules from setup.py.
>
> --
>  Ned Deily,
>  nad at acm.org
>
> --
> https://mail.python.org/mailman/listinfo/python-list

No need to apologize.  Also no need to have an understanding of the
environment; with a few rare exceptions it behaves just like a
Unix/Linux one.

The reason why I need to specify --allow-shlib-undefined is for the
python library; it's throwing undefined references to sincos even
though the symbol is there. Specifying that option is the only fix
I've found.

As mentioned earlier, i'm not familiar with python or its build
system; which file in the distutils dir do I need to modify?



More information about the Python-list mailing list