Codeblocks is a cross-platform C/C ++ IDE, but it is not installed on CentOS. We need to install it manually:1. Download wxWidgets (wxGTK) and CodeBlocks
Download the latest release: wxGTK-2.8.12.tar.gz at http://www.wxwidgets.org/downloads/
Download the latest: codeblocks_13.12-1.tar.gz at http://www.codeblocks.org/downloads /.
Since CodeBlocks is developed based on wxWidgets, you must install wxWidgets before installing CodeBlocks.
2. install necessary gcc files
Need to install gcc, need c and c ++ two local, the silent device, CentOS does not install the compiler, in the terminal output the following command can be
Yum install gcc
Yum install gcc-c ++
Then, the device gtk2-devel, because of the tacit acceptance of the formal product needs to support the database, but no device to open up the required documents.
Yum install gtk2 *
3. Next, compress wxGTK and execute the following commands in the Undo directory (the command must be executed in the tomb below)
- Tar-xzvfwxGTK-2.8.12.tar.gz
- Cd wxGTK-2.8.12
- ./Configure -- prefix =/usr -- enable-xrc -- enable-monolithic -- enable-unicode
- Make
- Make install
4. Install CodeBlocks
- Tar -xzvfcodeblocks_13.12-1.tar.gz
- Cdcodeblocks_13.12-1
- Export ACLOCAL_FLAGS = "-I 'wx-config -- prefix'/share/aclocal"
- ./Bootstrap
- . /Configure -- with-contrib-plugins = all an error may be reported here, configure: error: Package requirements (hunspell) were not met: this error, run the command yum install hunspell-devel. Similarly, there are gamin and boost. Run the command above and install the command if it is missing.
- Make
- Make install
5. If a Checking for existence error occurs during compilation, for example, it should be caused by a display terminal configuration error. We can change it to something we have. Open Settings --> Enviroment... and then execute the run Command!