Summary: | app-editors/vim-7.3 cross compilation fails due to AC_TRY_RUN(uint32_t is 32 bits) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Maksim 'max_posedon' Melnikau <maxposedon> |
Component: | New packages | Assignee: | Vim Maintainers <vim> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | embedded |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | http://code.google.com/p/vim/issues/detail?id=25 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
vim-7.3 config.log
vim-7.3 ebuild patch vim cross uin32_t cross compilation |
Description
Maksim 'max_posedon' Melnikau
2010-08-17 22:18:42 UTC
please post config.log files as attachments whenever configure fails Created attachment 243491 [details]
vim-7.3 config.log
config.log from vim-7.3/work/vim73/src/auto/
config.log attached, problem still exists Looks like problem in new uint32_t test in vim-7.3/work/vim73/src/configure.in: dnl Make sure that uint32_t is really 32 bits unsigned. AC_MSG_CHECKING([uint32_t is 32 bits]) AC_TRY_RUN([ #ifdef HAVE_STDINT_H # include <stdint.h> #endif #ifdef HAVE_INTTYPES_H # include <inttypes.h> #endif main() { uint32_t nr1 = (uint32_t)-1; uint32_t nr2 = (uint32_t)0xffffffffUL; if (sizeof(uint32_t) != 4 || nr1 != 0xffffffffUL || nr2 + 1 != 0) exit(1); exit(0); }], AC_MSG_RESULT(ok), AC_MSG_ERROR([WRONG! uint32_t not defined correctly.]), AC_MSG_ERROR([could not compile program using uint32_t.])) yep, that logic is broken. it needs a fallback case for cross-compiling where it just assumes the compiled answer is OK. This issue is being discussed on upstream mailing list: http://groups.google.com/group/vim_dev/msg/0c56183728029243 But no patch has appeared yet. Does anyone have time to come up with a quick "Don't do this test if cross-compiling" patch to configure.in? simply change the error to a warning: -AC_MSG_ERROR([could not compile program using uint32_t.])) +AC_MSG_WARNING([could not check when cross-compiling])) Created attachment 243613 [details, diff]
vim-7.3 ebuild patch
simple ebuild patch, which adds uint32_t patch
Created attachment 243615 [details, diff]
vim cross uin32_t cross compilation
simple patch, based on vapier's idea, during cross compilation uin32_t just warn, not stop compilation
I confirm that vim-7.3 cross compiles for arm and mips, and runs successfully on mips (can't test on arm now), Ben Nanonote. [ebuild R ] app-editors/vim-7.3 to /usr/armv4tl-softfloat-linux-gnueabi/ USE="X minimal nls -acl -bash-completion -cscope -debug -gpm -perl -python -ruby -vim-pager" 0 kB [1] [ebuild R ] app-editors/vim-7.3 to /usr/mipsel-gentoo-linux-gnu/ USE="minimal nls -X (-acl) -bash-completion -cscope -debug -gpm -perl -python -ruby -vim-pager" 0 kB [1] I have no name!@BenNanoNote / # uname -a Linux BenNanoNote 2.6.32.10 #1 PREEMPT Tue Jun 15 17:53:33 CEST 2010 mips GNU/Linux I have no name!@BenNanoNote / # vim --version VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Aug 19 2010 23:37:44) any news? Comment on attachment 243613 [details, diff]
vim-7.3 ebuild patch
this patch is missing a call to eautoreconf
Shouldn't be an issue with current versions as something similar to the patch has been applied upstream a while ago. |