CentOS is a free, enterprise grade Linux distribution. As a server CentOS is a great choice due to it’s stability and long term support.
However CentOS installer requires a minimum of 378 MB ram for installation. This tutorial aims at such virtual servers which comes with less memory.
The process is pretty simple.
- Install CentOS on source server.
- Prepare Target server.
- Copy all files to target server.
- Modify settings on target server.
- Post-Install Steps.
Many a times we need to execute a command as a different user. We can use
su -c command to run a command as a different user.
In some cases user may not have shell access. Now if we have to do this several times it quickly becomes repetitive. I wrote this script to cut down my typing in such a scenario.
There are several posts in Code::Blocks forum where user faced linking errors due to incorrect use of Microsoft(TM) C/C++ Compiler (MSVC) and corresponding C/C++ runtime. In this post I’ll explain how to use correct compiler and linker flags to avoid such errors.
Let’s start with a simple test project to demonstrate the problem. I have two ‘C’ files –
main.c. First file will be compiled into a static library –
add.lib. A corresponding header file will be
main.c will be linked against this static library.
Code::Blocks 12.11 was released on 6th December 2012.
It comes with a lot of improvements, new features. It can be downloaded from official Code::Blocks mirror at Berlios.de.
However I find official mirror is too slow for many peoples including myself. So I decided to mirror them on my server. All release files and source tarballs can be downloaded from the following link.
Packages have been grouped as per OS. Let me know if there are any issues with the mirror.
Last month Berlios svn repo service was very unstable. Lack of access to repo is really frustrating, especially when we check repo for changes several times every day.
From now on I’ll be hosting a mirror of Code::Blocks repo on my server. This will give read-only access to everyone. I’m also hosting a read-only Git repo. This will give us access to Git repo to everyone who loves Git (including myself).
A nightly build of Code::Blocks for 64 bit Windows is now available. Relevant patches are also available.
Do note that-
1) Code-completion plugin is not stable. Please disable it if Code::Blocks crashes or freezes.
2) Contrib plugins are not included in the package.
The download links do not work anymore. I also do not have a copy of those files. If you need a recent GCC build head over to mingw.org website.
GCC-4.4.0 has been released recently. I have managed to compile it as a MinGW build and I want to share that with others. The package can be downloaded from the following links. Please download both the files and extract them to C:\MinGW folder. Then extract Win32API, MinGW Runtime, pthreads-win (If you want to use OpenMP) package to the same folder. Now you’ll be able to use gcc-4.4 on Windows.
Download Links: Continue reading
To update all I have committed patch in trunk (in revision 5334). It should be available with the next nightly.
To run Code::Blocks portably you can write a batch file, set APPDATA variable to any directory you want and then launch Code::Blocks.
Alternatively you can download the CbLauncher v0.1.1 from my blog to run Code::Blocks portably.
Steps to use Cblauncher: Continue reading
Recently I was irritated by the fact that Code::Blocks is not truly portable on Windows. Usually I keep two versions of Code::Blocks in my PC. One is the last released nightly and the other one is the one that I build from trunk. I use last released nightly to write code. However as Code::Blocks is not truly portable, these two versions of Code::Blocks share same configuration file. Sometimes I run my newly built Code::Blocks from trunk, it crashes and corrupts my customised configuration file. And this irritates me a lot.
Other than this, you really can’t copy your configuration folder in a portable drive and expect entire Code::Blocks installation to behave as a truly portable software. There is one way; using personality feature of Code::Blocks. but that solves only one half of the problem. Yes, this makes your Code::Blocks portable. But your plugins are not! They still read their own settings from the default folder which is %APPDATA%CodeBlocks folder. Continue reading
A nasty bug was discovered by one of our user couple of months ago. The bug was affecting our last stable release as well as our latest nightly.
The bug was due to the way a file was being saved by C::B to avoid corrupting the existing file. C::B used to write the new contents to a temporary file before deleting the old one and then renaming the temp file to new file. But this created a bug as the temporary file may/may not get the file permission attributes of the original. Continue reading