How to compile vivi and kernel in Cygwin

Source: Internet
Author: User
Article Title: full introduction to vivi and kernel compilation in Cygwin. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.

I recently planned to design a new product. I bought a Matrix5 system at Friendly Arm to study it. It seems wise to use arm-Linux for development! But I am used to Windows, and I am not familiar with Linux, and it is very troublesome to reinstall RH9. Use Win2000 first, and be familiar with Linux!

I saw a Cygwin on the version. I could create a Linux-like system under Windows. I tried it for a while. It seems pretty good, but unfortunately there is no graphic interface! According to Boss Yang, vivi and kernel of Matrix5 can be compiled in Cygwin. Let's get familiar with Linux first! It took about a week to complete the compilation of vivi and kernel in Cygwin.

Now we can post the compilation process for the reference of those who share the same feelings:

(Since all operations in Cygwin use the line command input method, it is best to familiarize yourself with common Linux commands first)

  1. Install Cygwin:

The installation process is not mentioned much. The development center provides reference. But there are two points to note: it is best to install the SDK when the system is relatively clean. We recommend that you install the SDK after the system is started. Otherwise, installation may fail. In addition, you must install the gcc and ncurse libraries during installation, otherwise, menuconfig won't work. If you cannot figure it out, install it all!

After Cygwin is installed, a shortcut is provided to run it to enter the Cygwin system. The first time you enter the Cygwin system, there will be some initialization process. After the initialization, the command enters the command input status and the prompt is "@". Arm

The Linux file system starts from/. The Cygwin system/is the installation path (X: \ Cygwin) selected when cygwin is installed in Windows ). If you want to access all Windows logical disks in Cygwin, go to/cygdrive. For example, C in Windows is/cygdrive/c in Cygwin. In this way, files can be cross-accessed in Windows and Cygwin, which is convenient for those who are familiar with Windows operations.

In addition, it is important to note that Linux is case-sensitive, that is, "file" and "FILE" are not the same name. In particular, some file or directory names contain both uppercase and lowercase letters. Do not make mistakes!

  2. Install arm-linux-gcc:

This is also available in the installation and Development Center. You can download it and solve it. Even if the installation is complete, you need to solve it under the/opt directory (X: \ cygwin \ opt in Windows.

Modify the PATH environment variable in the startup script/etc/profile file (you can use a text editor in Windows to modify the PATH environment variable in X: \ cygwin \ etc \ profile)

PATH =/usr/local/bin:/usr/X11R6/bin:/opt/FriendlyARM/crosstool/arm-linux/gcc-2.95.3-glibc-2.2.3/binPATH

Gdbserver can be used only when Debug is used. At least I didn't use it during compilation.

Enter "arm-linux-gcc-v" and test it by yourself.

  3. Compile VIVI:

There are more specific descriptions in the Development Center. Be sure to download the version "vivi_cygwin.tgz", do not use the disk. The pre-configuration file (config. friendlyarm) already exists in the package, so you do not need to download it again. String 5

Because VIVI needs some header files of kernel, so the source code of kernel, in the disc "SBC-2410X/SBC-2410X-Linux/matrix5-kernel-v5.5.tgz ". Remove both vivi and kernel to/friendly-arm, that is,/friendly-arm/vivi and/friendly-arm/kernel. Then you need to modify some variable settings in/friendly-arm/vivi/Makefile:

LINUX_INCLUDE_DIR =/friendly-arm/kernel/include/

CROSS_COMPILE = arm-linux-

ARM_GCC_LIBS =/opt/FriendlyARM/crosstool/arm-linux/gcc-2.95.3-glibc-2.2.3/lib/gcc-lib/arm-linux/2.95.3

The three variables are in different locations. Find them by yourself. The first two variables Yang boss has been changed, check it can be; pay attention to the third variable in the center of Friendlyarm no minus sign, gcc-2.95.3-glibc-2.2.3 in g is lower case.

[1] [2] Next page

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.