zlib를 arm-elf-gcc로 크로스컴파일 하는 중에 나온 에러의 이유유

bakdorazi의 이미지

zlib를 arm-elf-gcc를 이용해서 크로스 컴파일 하는 중에 아래의 에러가 나왔습니다.
혹시 uClibc 를 설치를 안해서 나온 에러 입니까?
에러가 왜 나왔는지 원인을 모르겠습니다.

[root@localhost zlib-1.2.5]# CC=arm-elf-gcc ./configure --prefix=/home/test/zlib
Checking for shared library support...
Tested arm-elf-gcc -w -c -O3 -fPIC ztest4402.c
Tested arm-elf-gcc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map -O3 -fPIC -o ztest4402.so ztest4402.o
/usr/local/arm-elf/lib/crt0.o(.text+0x10): In function `_start':
: undefined reference to `__uClibc_main'
/usr/local/arm-elf/lib/crt0.o(.text+0x14): In function `_start':
: undefined reference to `abort'
ztest4402.o(.text+0xc): In function `hello':
: undefined reference to `getchar'
collect2: ld returned 1 exit status
No shared library support; try without defining CC and CFLAGS
Building static library libz.a version 1.2.5 with arm-elf-gcc.
Checking for off64_t... Yes.
Checking for fseeko... Yes.
Checking for unistd.h... Yes.
Checking whether to use vs[n]printf() or s[n]printf()... using vs[n]printf().
Checking for vsnprintf() in stdio.h... No.
  WARNING: vsnprintf() not found, falling back to vsprintf(). zlib
  can build but will be open to possible buffer-overflow security
  vulnerabilities.
Checking for return value of vsprintf()... Yes.
Checking for attribute(visibility) support... No.

swirlpotato의 이미지

_start 프로시져(아마도 부트스트랩의 초기 부분 혹은 프로그램 초기화 부분일껍니다.)에서 __uClibc_main와 abort 심볼을 찾는데 (호출을 하는데) 찾지 못해서 나는 에러입니다. uClibc를 써본적은 없지만 에러를 봐서 꼭 필요한 것 같습니다.

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.