classification
Title: Python Compile Error on Mac os X ld: unknown option: -export-dynamic
Type: behavior Stage: resolved
Components: Cross-Build Versions: Python 3.4
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: ned.deily, zhuoyikang
Priority: normal Keywords:

Created on 2014-12-10 16:49 by zhuoyikang, last changed 2014-12-11 14:28 by berker.peksag. This issue is now closed.

Messages (5)
msg232434 - (view) Author: zhuoyikang (zhuoyikang) Date: 2014-12-10 16:49
/Applications/Xcode.app/Contents/Developer/usr/bin/make Parser/pgen
gcc -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes  -L/usr/local/lib -export-dynamic  Parser/acceler.o Parser/grammar1.o Parser/listnode.o Parser/node.o Parser/parser.o Parser/bitset.o Parser/metagrammar.o Parser/firstsets.o Parser/grammar.o Parser/pgen.o Objects/obmalloc.o Python/dynamic_annotations.o Python/mysnprintf.o Python/pyctype.o Parser/tokenizer_pgen.o Parser/printgrammar.o Parser/parsetok_pgen.o Parser/pgenmain.o -ldl  -framework CoreFoundation -o Parser/pgen
ld: unknown option: -export-dynamic
collect2: error: ld returned 1 exit status
make[1]: *** [Parser/pgen] Error 1
make: *** [Include/graminit.h] Error 2
msg232441 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2014-12-10 19:38
The -export-dynamic compile option is not supported nor selected at configure time for normal builds on OS X.  Exactly what configure options did you use?  I see that you have checked Cross-Build for components.  What sort of cross-building are you attempting?
msg232459 - (view) Author: zhuoyikang (zhuoyikang) Date: 2014-12-11 05:17
Sorry, i am not  cross-build , i just building it on my mac os x machine :

i fellow this =>
Build Instructions
------------------

On Unix, Linux, BSD, OSX, and Cygwin:

New text

    ./configure
    make
    make test
    sudo make install

This will install Python as python3.

2014-12-11 3:38 GMT+08:00 Ned Deily <report@bugs.python.org>:

>
> Ned Deily added the comment:
>
> The -export-dynamic compile option is not supported nor selected at
> configure time for normal builds on OS X.  Exactly what configure options
> did you use?  I see that you have checked Cross-Build for components.  What
> sort of cross-building are you attempting?
>
> ----------
> nosy: +ned.deily
>
> _______________________________________
> Python tracker <report@bugs.python.org>
> <http://bugs.python.org/issue23024>
> _______________________________________
>
msg232460 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2014-12-11 06:42
That should work just fine, assuming you are using an unmodified Python 3.4.x source download or the 3.4 branch of a source repo. My best guess as to why you are running into problems is that you may be picking up build tools other than those supplied by Apple.  On recent versions of OS X, make sure you have run 'sudo xcode-select --install' to install the latest version of the command line tools and check your shell $PATH variable.  There may be clues in the config.log file produced by running ./configure.
msg232466 - (view) Author: zhuoyikang (zhuoyikang) Date: 2014-12-11 09:45
thank u very much !  question solved

2014-12-11 14:42 GMT+08:00 Ned Deily <report@bugs.python.org>:

>
> Ned Deily added the comment:
>
> That should work just fine, assuming you are using an unmodified Python
> 3.4.x source download or the 3.4 branch of a source repo. My best guess as
> to why you are running into problems is that you may be picking up build
> tools other than those supplied by Apple.  On recent versions of OS X, make
> sure you have run 'sudo xcode-select --install' to install the latest
> version of the command line tools and check your shell $PATH variable.
> There may be clues in the config.log file produced by running ./configure.
>
> ----------
>
> _______________________________________
> Python tracker <report@bugs.python.org>
> <http://bugs.python.org/issue23024>
> _______________________________________
>
History
Date User Action Args
2014-12-11 14:28:52berker.peksagsetstatus: open -> closed
type: behavior
resolution: not a bug
stage: resolved
2014-12-11 09:45:07zhuoyikangsetmessages: + msg232466
2014-12-11 06:42:09ned.deilysetmessages: + msg232460
2014-12-11 05:17:58zhuoyikangsetmessages: + msg232459
title: Python Compile Error on Mac os X ld: unknown option: -export-dynamic -> Python Compile Error on Mac os X ld: unknown option: -export-dynamic
2014-12-10 19:38:02ned.deilysetnosy: + ned.deily
messages: + msg232441
2014-12-10 16:49:32zhuoyikangcreate