1. 목적(purpose)

ㄱ. 타이젠 관련 실행파일의 빌드를 위해 ARM 크로스 컴파일러를 설치한다.

(ARM toolchain install to cross compile for build of Tizen)

ㄴ. 설치한 크로스 컴파일러의 설정을 한다.

(Configuration ARM cross complie toolchain)

※ 추후 u-boot를 빌드에 64비트 실행이 존재하므로 이전 우분투를 설치할 때 64BIT 운영체제를 설치하도록 한다. (You must install 64bit OS to build u-boot. U-boot builder have 64bit execute file)


2.내용(body)

ㄱ. 툴체인 다운로드 (Toolchain Download)

a. 먼저 http://www.mentor.com/에서 IA32용 GNU/Linux ARM EABI를 받아야함.

(First, you have to download 'GNU/Linux EABI for IA32' in http://www.mentor.com/)

https://sourcery.mentor.com/GNUToolchain/release1294?lite=arm 접속(enter the link)


위와 같은 화면이 보이면 'Download Lite Edition' 클릭한다.('Download Lite Edition' click)


각 양식들을 체우고 'Get Lite!' 버튼을 클릭한다. (Fill in all of form.)


그 후 메일을 확인하면 ARM EABI를 받을 수 있는 메일이 수신되어있다. 메일을 열면 아래와 같은 주소가 담긴 메일이 보인다.(Then, you can receive a mail to download ARM EABI)


주소가 담긴 메일에서 빨간 네모박스 위치의 주소를 클릭하면 ARM의 EABI를 다운받는다.

(Click the link inside of red box to download ARM EABI)

※ 여기서 EABI란(임베디드 응용 프로그램 이진 인터페이스, embedded-application binary interface)는 임베디드 소프트웨어 프로그램을 수행하는 파일 형식, 자료형, 레지스터 사용, 스택 프레임 조직, 명령 변수를 위한 표준 변환을 정의하고 있다.

EABI를 지원하는 컴파일러는 이와 같은 또다른 컴파일러가 만든 코드와 호환되는 목적 코드를 만드므로 개발자들이 다른 컴파일러가 만들어 낸 목적 코드와 한 컴파일러로 만든 라이브러리를 연결할 수 있게 한다. 자체적인 어셈블리어 코드를 작성하는 개발자들은 EABI를 사용하여 호환 컴파일러가 만들어낸 어셈블리 코드와 상호 작용하게 할 수 있다.

일반 목적의 운영 체제에서 ABI와 EABI의 주된 차이점은 권한 명령이 응용 프로그램 코드 내에서 실행되는 점, 동적 링크가 요구되지 않는다는 점(심지어는 아예 동적 링크를 허용하지 않는 경우도 있음), 메모리 저장을 위해 더 작아진 스택 프레임 조직을 갖춘다는 점이 있다.

(An embedded-application binary interface (EABI) specifies standard conventions for file formats, data types, register usage, stack frame organization, and function parameter passing of an embedded software program.

Compilers that support the EABI create object code that is compatible with code generated by other such compilers, thus allowing developers to link libraries generated with one compiler with object code generated with a different compiler. Developers writing their own assembly language code may also use the EABI to interface with assembly generated by a compliant compiler.

The main differences of an EABI with respect to an ABI for general purpose operating systems are that privileged instructions are allowed in application code, dynamic linking is not required (sometimes it is completely disallowed), and a more compact stack frame organization is used to save memory.[4] The choice of EABI can affect performance.)


빨간 네모박스의 IA32 GNU/Linux TAR 파일을 받는다. (Download IA32 GNU/Linux TAR file inside of redbox)


다운 파일이 Downloads 폴더 안에 생성된것을 볼 수 있다.(arm-2010q1-188-arm-none-eabi-i686-pc-linux-gnu-tar.bz2)

(You can see tar file in Downloads folder. File name is arm-2010q1-188-arm-none-eabi-i686-pc-linux-gnu-tar.bz2.)


위와 같은 tar -xvf 명령어를 통해 압축을 푼다.(Extract tar file by tar -xvf command)


압축을 풀면 arm-2010q1 이라는 폴더가 생성됨을 볼 수 있다.(You can see arm-2010q1 folder after extract.)


위와 같은 cp 명령어를 통해 사용자가 원하는 폴더로 ARM EABI 폴더를 이동시킨다.(move arm-2010q1 folder to every dir where you want by cp.)


폴더가 이동되었다면 자신의 HOME 폴더의 .bashrc 파일을 수정한다. .bashrc 파일은 bash shell이 시작될 때 초기화되는 sell script들을 모아놓은 파일이다.(If folder is moved successfully, you have to edit .bashrc in your HOME folder.)


위와 같이 .bashrc에 자신의 ARM EABI 위치에 대한 경로를 추가해 준다.(Specify your ARM EABI folder PATH end of the .bashrc file.)

export ARCH=arm 

export CROSS_COMPILE=arm-none-eabi-

PATH=$PATH:(Your ARM BAEI folder path)/bin;

:wq 명령어를 통해 저장하고 복귀한다.(Return to shell bu :wq command.)


ㄴ. 위와 같은 툴체인 설치가 완료되었다면 32bit 라이브러리를 설치한다.(Install 32bit libs)

'sudo apt-get install ia32-libs' 명령어를 통해 설치하게 된다.


3.결론(conclusion)

ㄱ. 지금까지 ARM 크로스 컴파일을 위한 ARM EABI 설치를 진행해 보았다.(We installed ARM EABI for ARM cross complie)

ㄴ. 다음은 타이젠의 u-boot 소스를 받고 엑시노스 4412의 콘피규어 파일을 포팅하고 빌드해 보도록 하겠다.(We will download u-boot of Tizen and porting Exsynos4412 config file to Tizen u-boot next time)

Posted by 시크한공돌이
,