Compile MySQL source code using Eclipse-cpp in Ubuntu

Source: Internet
Author: User

Compile MySQL source code using Eclipse-cpp in Ubuntu

1. Download The eclipse-cpp-mars-2-linux-gtk-x86_64.tar.gz package, decompress it in Ubuntu, and run it.

Jdk errors may occur because jdk is not installed or the jdk version is too low. Jdk1.8 is required to be the lowest version. Eclipse needs.

2. Download the MySQL source code file: mysql-boost-5.7.12.tar.gz. Decompress in Ubuntu

The decompressed MySQL source code file is stored in the/opt/source/folder.

3. Generate the make File

Run: path = 'dirname $0'

Cmake $ path /.. -DCMAKE_CXX_FLAGS =-m64-DCMAKE_C_FLAGS =-m64-DWITH_DEBUG = 1-DWITH_NDBCLUSTER = 0 $ @-DDOWNLOAD_BOOST = 1-DWITH_BOOST =/opt/source/mysql-5.7.12/boost/clusters/

Note that the following path is your source code placement path. This step follows the instructions in mysql-InnoDB Storage engine.

4. Create an empty C ++ project: Name the project mysql5.7.12.

5. Right-click the project mysql5.7.12. select new folder and import/opt/source/mysql5.7.12 to the project.

6. After importing the folder, select Build directory as the path of the source code, for example:

7. After the above compilation configuration is complete, the program will automatically start to execute the compilation, as shown in:

Related Article

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.