raven::set
raven::set User's Guide
Not logged in

Download

Copy/Paste

Paste the code into an editor.

Zip

A zip file containing all the source code files.

Repository

A Fossil repository containing everything, including this documentation.

 Directory of C:\Users\James\code\ravenset

22/06/2012  01:48 PM    <DIR>          .
22/06/2012  01:48 PM    <DIR>          ..
22/06/2012  01:48 PM             4,201 cRunWatch.cpp
22/06/2012  01:48 PM             3,257 cRunWatch.h
22/06/2012  01:48 PM             7,796 cutest.cpp
22/06/2012  01:48 PM            22,099 cutest.h
22/06/2012  01:48 PM    <DIR>          doc
22/06/2012  01:47 PM           409,600 ravenset.fsl
22/06/2012  01:48 PM             2,390 raven_sqlite.cpp
22/06/2012  01:48 PM             1,165 raven_sqlite.h
22/06/2012  01:48 PM           324,759 sqlite3.h
22/06/2012  01:48 PM            42,672 sqlite3.lib
22/06/2012  01:48 PM    <DIR>          tst
22/06/2012  01:48 PM            15,360 _FOSSIL_

Integration

Coders really prefer to re-invent the wheel. They know they shouldn’t, because there is so much really useful, complete and tested open source code available, but it always turns into a tedious hassle integrating other people’s code with your own.

I think the problem is that everyone arranges the files required to build a program executable in their own peculiar way. This is called configuration management and it is not hard, which is why programmers prefer not to think about it, but it has to be done perfectly or you end up with all those mysterious undefined symbols and missing links that can take hours to track down.

There is no right way to do configuration management, since almost any arrangement can be made to work. Here is how I like to arrange things, which has the one advantage that the raven::set code will integrate ‘out of the box’.

I work on Windows using the Microsoft Visual Studio C++ integrated development environment.

I create a folder to contain everything in a solution. A solution is one or more executable program, the files required to build them, and the documentation.

Under the solution folder I create a folder called ‘src’ which contains all my source code that is shared by the programs in the solution and the source code from other open source projects that I use.

Under the ‘src’ folder I create a folder called ‘ravenset’. This contains the raven::set source code files.

I create a folder under the solution folder for each project, containing everything required to build one executable.

For each project in the solution I add the following lines, as required, to the file stdafx.h

#include “ravenset/cutest.h”
#include “ravenset/cRunWatch.h”

For each project in the solution I add ‘../src’ to Project | Properties | C++ | Additional Include Directories.

If you do this, raven::set will now be integrated, and available in any code wherever you want to use the tool set.

However, you will also need the boost libraries. I use these libraries in almost every solution I create, so they are installed in their own common location pointed to by the environment variable BOOSTROOT. Using this arrangement, you will have to add $(BOOSTROOT) to Project | Properties | C++ | Additional Include Directories and $(BOOSTROOT)/lib to Project | Properties | Linker | Additional Library Directories