This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
标题: cross compile and mingw support
类型: Stage:
Components: None Versions:
process
状态: closed Resolution: out of date
Dependencies: 后续: Cross compiling patches for MINGW
View: 1597850
分配给: 抄送列表: hanwen, janneke-sf, rmt38
优先级: normal 关键字: patch

Created on 2005-10-27 16:18 by janneke-sf, last changed 2022-04-11 14:56 by admin. This issue is now closed.

文件
文件名 上传时间 Description 编辑
context-cross.patch janneke-sf, 2005-10-27 16:18 cross compile context diff
context-mingw.patch janneke-sf, 2005-10-27 16:19 mingw context diff
context-mingw-2.patch janneke-sf, 2005-11-04 13:59 mingw context diff v2
Messages (8)
msg48920 - (view) Author: Jan Nieuwenhuizen (janneke-sf) * 日期: 2005-10-27 16:18
The cross compile patch is similar to what I did for
Guile and has
still some bits from Daniel Goertzen's

   
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1006238&group_id=5470

The mingw patch is based on Matthias Kramm's

   
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1053879&group_id=5470

but adds autoconf tests and does have his C modifications.

-- 
Jan Nieuwenhuizen <janneke@gnu.org> | GNU LilyPond -
The music typesetter
http://www.xs4all.nl/~jantien       |
http://www.lilypond.org
msg48921 - (view) Author: Jan Nieuwenhuizen (janneke-sf) * 日期: 2005-10-27 16:20
Logged In: YES 
user_id=1368960

.... and does NOT have his C modifications
 
msg48922 - (view) Author: Jan Nieuwenhuizen (janneke-sf) * 日期: 2005-11-04 13:59
Logged In: YES 
user_id=1368960

The second mingw patch actually produces a working python,
fixing
   * loadable dll modules
   * argv0 relocation
   * posixflavour nt

-- Jan.
msg48923 - (view) Author: Richard Tew (rmt38) * (Python committer) 日期: 2006-01-05 21:20
Logged In: YES 
user_id=1417949

Hi, I patched Python 2.4.2 source code download with this 
(can't get CVS as bandwidth is limited).

context-cross.patch fails on one chunk of Makefile.pre.in, 
although hand application fixed it.  Otherwise, context-
mingw-2.patch applied cleanly.

With both applied, I did the following:

export BASECFLAGS="-mcpu=arm9tdmi -mcpu=arm9tdmi -ffast-
math -mthumb -mthumb-interwork -DARM9 -D__NDS__"
export CFLAGS="-mcpu=arm9tdmi -mcpu=arm9tdmi -ffast-math -
mthumb -mthumb-interwork -DARM9  -D__NDS__"
export LDFLAGS="-specs=ds_arm9.specs -g -mthumb -mthumb-
interwork -Wl,-Map,libpython2.4.map"

sh configure --host=arm-elf

This is what eventually happened:

PATH=/usr/bin:.:/usr/local/bin:/mingw/bin:/bin:/c/WINDOWS/s
ystem32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/Program 
Files/ATI Technologies/ATI Control 
Panel:/c/PROGRA~1/COMMON~1/SONICS~1/:/c/Program 
Files/Common 
Files/Adobe/AGL:/usr/bin:/c/devkitpro/devkitarm/bin:. cc -
c -I -I./Include  -o Parser/acceler.x Parser/acceler.c
/bin/sh: Files/ATI: No such file or directory
make: *** [Parser/acceler.x] Error 127

Looks like the patch needs to handle paths with spaces in, 
in the PATH.
msg48924 - (view) Author: Jan Nieuwenhuizen (janneke-sf) * 日期: 2006-01-06 00:31
Logged In: YES 
user_id=1368960

> Looks like the patch needs to handle paths with spaces in, 
> in the PATH.

Why do you think that?  You will find that no autotooled
package will build or install in directories with spaces.

If this would be possible at all, it would be a separate
feature.  I do not see a dependency with cross compilation
or mingw building.
msg48925 - (view) Author: Richard Tew (rmt38) * (Python committer) 日期: 2006-01-06 05:46
Logged In: YES 
user_id=1417949

> Why do you think that?  You will find that no autotooled
> package will build or install in directories with spaces

Perhaps I was not clear enough.  The problem is not that I 
am building in those directories, it is that the patch 
sets the PATH environment variable as a prefix to the 
compilation command (in the same line).  And on Windows, 
it is not uncommon for directories in Program Files and 
other directories with spaces in their names to be in the 
path.  This breaks the correctness of the command line and 
the execution of it.

Take another look at the erroneous command:

PATH=/usr/bin:.:/usr/local/bin:/mingw/bin:/bin:/c/WINDOWS/s
ystem32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/Program 
Files/ATI Technologies/ATI Control 
Panel:/c/PROGRA~1/COMMON~1/SONICS~1/:/c/Program 
Files/Common 
Files/Adobe/AGL:/usr/bin:/c/devkitpro/devkitarm/bin:. cc -
c -I -I./Include  -o Parser/acceler.x Parser/acceler.c

And the error:

/bin/sh: Files/ATI: No such file or directory
make: *** [Parser/acceler.x] Error 127

Hope this helps.
msg48926 - (view) Author: Han-Wen Nienhuys (hanwen) * 日期: 2006-12-05 23:51
superseded by #1597850
msg48927 - (view) Author: Han-Wen Nienhuys (hanwen) * 日期: 2006-12-05 23:52
superseded by #1597850
历史
日期 用户 动作 参数
2022-04-11 14:56:13admin修改github: 42529
2008-01-05 19:59:41christian.heimes修改状态: open -> closed
resolution: out of date
后续: Cross compiling patches for MINGW
2005-10-27 16:18:31janneke-sf创建