Library Version 18.1.40

Building the C# API
Prev | Chapter 4. Building Berkeley DB for Windows | Next

## Building the C# API

The C# support is built by a separate Visual Studio solution and requires version 2.0 (or higher) of the .NET platform. If the Berkeley DB utilities are required, build Berkeley DB first following the instructions under Building Berkeley DB for Windows.

To build the C# API in Visual Studio 2010 the solution is `build_windows\BDB_dotnet_vs2010.sln`; in Visual Studio 2012 and 2013 the solution is `build_windows\BDB_dotnet_vs2012.sln`; and in Visual Studio 2015 the solution is `build_windows\BDB_dotnet_vs2015.sln`.

By default, the solution will build the native libraries, the managed assembly and all example programs. The NUnit tests need to be built explicitly because of their dependence upon the NUnit assembly. The native libraries will be placed in one of the following subdirectories, depending upon the chosen configuration:

`build_windows\x64\Debug`
`build_windows\x64\Release`
`build_windows\Win32\Debug`
`build_windows\Win32\Release`

The managed assembly and all C# example programs will be placed in one of the following subdirectories, depending upon the chosen configuration:

`build_windows\AnyCPU\Debug`
`build_windows\AnyCPU\Release`

The native libraries need to be locatable by the .NET platform, meaning they must be copied into an application's directory, the Windows or System directory, or their location must be added to the PATH environment variable. The example programs demonstrate how to programmatically edit the PATH variable.

Prev | Up | Next
Building the Java API | Home | Building the Tcl API