2013-04-29 57 views
0

我試圖在buildroot env下編譯open-vm-toos包(9.0.0-782409),它在一個文件中失敗。以下是錯誤的日誌。我縮小了與locale包含的某些關係。試圖脫離標準的語言環境包括那些在buildroot env下可用的,並且沒有區別。其中包括我錯過了(可能是明確傳遞給CFLAGS來配置open-vm-tools的腳本)?打開虛擬機工具的buildroot編譯

/bin/sh ../../libtool --tag=CC --mode=compile /myRepository/repo/cai/buildroot/output/staging/usr/bin/i686-unknown-linux-uclibc-gcc -Os -pipe -Os -mtune=i686 -march=i686 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -I/myRepository/repo/cai/buildroot/output/staging/usr/include -I/myRepository/repo/cai/buildroot/output/staging/include --sysroot=/myRepository/repo/cai/buildroot/output/staging/ -isysroot /myRepository/repo/cai/buildroot/output/staging -DPACKAGE_NAME=\"open-vm-tools\" -DPACKAGE_TARNAME=\"open-vm-tools\" -DPACKAGE_VERSION=\"8.4.2\" -DPACKAGE_STRING=\"open-vm-tools\ 8.4.2\" -DPACKAGE_BUGREPORT=\"[email protected]\" -DPACKAGE_URL=\"\" -DPACKAGE=\"open-vm-tools\" -DVERSION=\"8.4.2\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DX_DISPLAY_MISSING=1 -DNO_PROCPS=1 -DNO_DNET=1 -DHAVE_CRYPT_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_WCHAR_H=1 -DHAVE_SYS_IO_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_SYS_SYSINFO_H=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_USER_H=1 -DHAVE_SYS_VFS_H=1 -DHAVE_UNWIND_H=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DHAVE_STRUCT_STAT_ST_RDEV=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_LSEEK=1 -DNO_MULTIMON=1 -I. -I/myRepository/repo/cai/buildroot/output/build/open-vm-tools-8.4.2-261024/lib/include -I/myRepository/repo/cai/buildroot/output/build/open-vm-tools-8.4.2-261024/lib/include -DUSING_AUTOCONF=1 -DOPEN_VM_TOOLS -DVMX86_TOOLS -DNO_CORE_ICU -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_SVID_SOURCE -DGLIBC_VERSION_21 -DGLIBC_VERSION_22 -I/myRepository/repo/cai/buildroot/output/staging/usr/include -I/myRepository/repo/cai/buildroot/output/build/usr/include -liconv -DNO_FLOATING_POINT -Wall -Werror -Wno-pointer-sign -Wno-unused-value -fno-strict-aliasing -Wno-unknown-pragmas -Wno-uninitialized -MT codesetOld.lo -MD -MP -MF .deps/codesetOld.Tpo -c -o codesetOld.lo codesetOld.c 

....

codesetOld.c: In function 'CodeSetOldGetCodeSetFromLocale': 
codesetOld.c:728: error: '__locale_t' undeclared (first use in this function) 
codesetOld.c:728: error: (Each undeclared identifier is reported only once 
codesetOld.c:728: error: for each function it appears in.) 
codesetOld.c:728: error: expected ';' before 'new' 
codesetOld.c:729: error: 'new' undeclared (first use in this function) 
cc1: warnings being treated as errors 
codesetOld.c:736: error: implicit declaration of function '__newlocale' 
codesetOld.c:739: error: implicit declaration of function '__nl_langinfo_l' 
codesetOld.c:739: error: passing argument 2 of 'Util_SafeInternalStrdup' makes pointer from integer without a cast 
codesetOld.c:740: error: implicit declaration of function '__freelocale' 
make[5]: *** [codesetOld.lo] Error 1 
make[4]: *** [all-recursive] Error 1 
make[3]: *** [all-recursive] Error 1 

這裏的下錯誤文件的代碼片段:

721 static char * 
722 CodeSetOldGetCodeSetFromLocale(void) 
723 { 
724 char *codeset; 
725 
726 #if defined(__linux__) 
727 
728 locale_t new = newlocale(LC_CTYPE_MASK, "", NULL); 
729 if (!new) { 
730  /* 
731  * If the machine is configured incorrectly (no current locale), 
732  * newlocale() could return NULL. Try to fall back on the "C" 
733  * locale. 
734  */ 
735 
736  new = newlocale(LC_CTYPE_MASK, "C", NULL); 
737  ASSERT(new); 
738 } 
739 codeset = Util_SafeStrdup(nl_langinfo_l(CODESET, new)); 
740 freelocale(new); 
741 
742 #elif defined(sun) 
743 
744 char *locale = setlocale(LC_CTYPE, NULL); 
745 if (!setlocale(LC_CTYPE, "")) { 

回答

0

啓用工具鏈的本地化支持,然後做一個make clean; make all週期。

+0

實際上,語言環境支持已經在buildroot配置中啓用。但後來我意識到一個錯誤,GLIB12以及GLIB2目標在buildroot配置中啓用,並導致此文件包含問題。所以我糾正了這種情況,只保留了GLIB2目標,並做了「全部清理」,但現在它在連接過程中在開放虛擬機工具的某個不同位置失敗。現在它試圖鏈接到系統的glib-2.so(/usr/lib/glib-2.so)而不是從buildroot env。我該如何糾正這個LD_LIBRARY_PATH問題? – 2013-05-01 13:07:58

+0

你正在使用什麼Buildroot版本?自從looooooooooo的時候,glib 1.2已被刪除。請使用最後一個Buildroot版本,並使用郵件列表來解決這些問題。 – 2013-05-26 15:42:14