Search code examples
mysqlsqlcachingbazaar

Where can I find MySQL source code and how could I edit it?


I am doing a project in which I have to tweak the Query Cache implementation of MySQL. I have installed bazaar but I am unable to find the source code of MySQL. I am using Ubuntu 14.04 and MySQL 5.5.37. If branch is the source code, should I compulsorily use the branch of MySQL 5.5? 1) Where can I find the source code for MySQL and how do I install it for use? What are branches in Launchpad? 2) Also, hoping that it might be tens of thousands of LOC, how could I find out the code pertaining to Query Cache? Any handy editors?

Kindly answer in a not-so-sophisticated language as I am new to Ubuntu. Thanks in advance.


Solution

  • Finally I found the answers to my questions.

    1. Source code was obtained from Bazaar repository. Installation was done according to http://dev.mysql.com/doc/refman/5.0/en/installing-development-tree.html

      A Bazaar branch has the entire history of the software and it usually contains the working tree (allowing all operations to be entirely local). Bazaar branches can be standalone.

    2. Cscope is an awesome source code browsing tool. Just give the name of a function and it can find its definition, its occurrences in the code, the functions that call it and the functions that are called by it. An elegant tutorial on how to use cscope has been given in http://cscope.sourceforge.net/cscope_vim_tutorial.html

    Hope someone benefits from this :)