Import BSDDB 4.7.25 (as of svn r89086)
This commit is contained in:
BIN
docs/porting/BDB-Porting-Guide.pdf
Normal file
BIN
docs/porting/BDB-Porting-Guide.pdf
Normal file
Binary file not shown.
64
docs/porting/buildtarget.html
Normal file
64
docs/porting/buildtarget.html
Normal file
@@ -0,0 +1,64 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title> Building on the Target Platform</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="newbinary.html" title="Chapter 2. Creating a New Berkeley DB Binary" />
|
||||
<link rel="previous" href="modscope.html" title=" Determining the Scope of the Modifications " />
|
||||
<link rel="next" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center"> Building on the Target Platform</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="modscope.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 2. Creating a New Berkeley DB Binary</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="testport.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="buildtarget"></a> Building on the Target Platform</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Once you have an idea of the scope of the modifications, use the files generated on the UNIX system to help you create any compiler or linker tool chain files that you need to build on the target platform. At this point, start building the Berkeley DB on the target platform making the changes to the code that you identified earlier in the process.
|
||||
Once you have identified the modifications that you need to make, change the code accordingly.
|
||||
</p>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="modscope.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="newbinary.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="testport.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">
|
||||
Determining the Scope of the Modifications
|
||||
</td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Chapter 3. Testing and Certifying the Port</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
70
docs/porting/certport.html
Normal file
70
docs/porting/certport.html
Normal file
@@ -0,0 +1,70 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Certifying a Port of Berkeley DB</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="previous" href="sourceintegrate.html" title="Integrating Changes into the Berkeley DB Source Code" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Certifying a Port of Berkeley DB</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="sourceintegrate.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
<td width="20%" align="right"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="certport"></a>Certifying a Port of Berkeley DB</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
When the target platform supports using Tcl, the port is considered
|
||||
certified after a successful standard run (<tt class="literal">run_std</tt>) of the Test Suite .
|
||||
</p>
|
||||
<p>
|
||||
When the target platform does not support using Tcl, a port is considered
|
||||
certified if you see successful message reports for each of the tests in
|
||||
<tt class="literal">test_os</tt>, <tt class="literal">test_micro</tt>,
|
||||
and <tt class="literal">test_mutex</tt>.
|
||||
</p>
|
||||
<p>
|
||||
Additionally, the configuration and compilation of Berkeley DB must be complete without errors or warninigs of any kind. You must provide specific information about the hardware, software, and compiler used during the porting process, especially versions of all thrid party tools used. If you have other diagnostic tools available, such as memory allocation checking tools, please conduct tests using them as well and provide Oracle engineering with the results. Finally, do not constrain your testing to one configuration. There are many different ways to configure Berkeley DB (that is many options to the "configure" script), please configure, built, and test Berkeley DB on the target platform with as many combinations of these flags as possible to ensure that nothing is missed.
|
||||
</p>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="sourceintegrate.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="testport.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Integrating Changes into the Berkeley DB Source Code </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
41
docs/porting/gettingStarted.css
Normal file
41
docs/porting/gettingStarted.css
Normal file
@@ -0,0 +1,41 @@
|
||||
body { width: 45em;
|
||||
margin-left: 3em;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 11pt;
|
||||
}
|
||||
|
||||
h2.title { margin-left: -1em;
|
||||
font-family: Verdana, serif;
|
||||
font-size: 16pt;
|
||||
}
|
||||
|
||||
h3.title { font-family: Verdana, serif;
|
||||
font-size: 14pt;
|
||||
}
|
||||
|
||||
pre.programlisting {
|
||||
font-family: monospace;
|
||||
background-color: #eae8e9;
|
||||
}
|
||||
|
||||
div.navheader { font-size: 9pt;
|
||||
width: 60em;
|
||||
margin-left: -2em;
|
||||
}
|
||||
|
||||
div.navheader table tr td { font-size: 9pt; }
|
||||
|
||||
div.navfooter { font-size: 9pt;
|
||||
width: 60em;
|
||||
margin-left: -2em;
|
||||
}
|
||||
div.navfooter table tr td { font-size: 9pt; }
|
||||
|
||||
span.emphasis { font-style: italic; font-size: 9pt;}
|
||||
|
||||
div.appendix div.informaltable { font-size: 9pt; }
|
||||
div.appendix div.informaltable td { vertical-align: top; }
|
||||
div.appendix div.informaltable p { margin-top: .25em; }
|
||||
div.appendix div.informaltable p { margin-bottom: .25em; }
|
||||
|
||||
|
||||
253
docs/porting/index.html
Normal file
253
docs/porting/index.html
Normal file
@@ -0,0 +1,253 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Porting Berkeley DB</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="next" href="preface.html" title="Preface" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Porting Berkeley DB</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"> </td>
|
||||
<th width="60%" align="center"> </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="preface.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="book" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h1 class="title"><a id="id613728"></a>Porting Berkeley DB</h1>
|
||||
</div>
|
||||
<div>
|
||||
<div class="legalnotice">
|
||||
<p class="legalnotice-title">
|
||||
<b>Legal Notice</b>
|
||||
</p>
|
||||
<p>
|
||||
This documentation is distributed under an open source license.
|
||||
You may review the terms of this license at:
|
||||
<a href="http://www.oracle.com/technology/software/products/berkeley-db/htdocs/oslicense.html" target="_top">http://www.oracle.com/technology/software/products/berkeley-db/htdocs/oslicense.html</a>
|
||||
|
||||
|
||||
</p>
|
||||
<p>
|
||||
Oracle, Berkeley DB,
|
||||
|
||||
|
||||
and
|
||||
Sleepycat are trademarks or registered trademarks of
|
||||
Oracle. All rights to these marks are reserved.
|
||||
No third-party use is permitted without the
|
||||
express prior written consent of Oracle.
|
||||
</p>
|
||||
<p>
|
||||
To obtain a copy of this document's original source code, please
|
||||
submit a request to the Oracle Technology Network forum at:
|
||||
<a href="http://forums.oracle.com/forums/forum.jspa?forumID=271" target="_top">http://forums.oracle.com/forums/forum.jspa?forumID=271</a>
|
||||
|
||||
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<p class="pubdate">4/25/2008</p>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="toc">
|
||||
<p>
|
||||
<b>Table of Contents</b>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="preface">
|
||||
<a href="preface.html">Preface</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="preface.html#conventions">Conventions Used in this Book</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="preface.html#audience">Audience</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="preface.html#moreinfo">For More Information</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="chapter">
|
||||
<a href="introduction.html">1. Introduction to Porting Berkeley DB </a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="introduction.html#porttypes">Types of Berkeley DB ports</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="introduction.html#id793975">When Oracle Has Agreed to Support Berkeley DB on the New Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="introduction.html#id794049">When Oracle has Not Agreed to Support Berkeley DB on the New Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="portprocess.html">Berkeley DB Porting Process</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="chapter">
|
||||
<a href="newbinary.html">2. Creating a New Berkeley DB Binary</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="newbinary.html#basebuild">
|
||||
Creating a Base Build of Berkeley DB
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="modscope.html">
|
||||
Determining the Scope of the Modifications
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#osfunc">
|
||||
Do Changes Need to be Made to the Operating System Functionality?
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#standardfunc">Are Some Standard Functions Missing on the Target Platform?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#sharedmem">How Will the Port Handle Shared Memory?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#typemutex">What Type of Mutexes Will the Port Use?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#otherchanges">Do Any Other Changes Need to be Made?</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="buildtarget.html"> Building on the Target Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="chapter">
|
||||
<a href="testport.html">3. Testing and Certifying the Port</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testport.html#testtypes">Types of Tests for Berkeley DB</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="modifytest.html">Modifying the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testrun.html">Running the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testreview.html">Reviewing the Results of the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="sourceintegrate.html">Integrating Changes into the Berkeley DB Source Code</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="certport.html">Certifying a Port of Berkeley DB</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"> </td>
|
||||
<td width="20%" align="center"> </td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="preface.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top"> </td>
|
||||
<td width="20%" align="center"> </td>
|
||||
<td width="40%" align="right" valign="top"> Preface</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
209
docs/porting/introduction.html
Normal file
209
docs/porting/introduction.html
Normal file
@@ -0,0 +1,209 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Chapter 1. Introduction to Porting Berkeley DB </title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="previous" href="preface.html" title="Preface" />
|
||||
<link rel="next" href="portprocess.html" title="Berkeley DB Porting Process" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Chapter 1. Introduction to Porting Berkeley DB </th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="preface.html">Prev</a> </td>
|
||||
<th width="60%" align="center"> </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="portprocess.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="chapter" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title"><a id="introduction"></a>Chapter 1. Introduction to Porting Berkeley DB </h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div class="toc">
|
||||
<p>
|
||||
<b>Table of Contents</b>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="introduction.html#porttypes">Types of Berkeley DB ports</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="introduction.html#id793975">When Oracle Has Agreed to Support Berkeley DB on the New Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="introduction.html#id794049">When Oracle has Not Agreed to Support Berkeley DB on the New Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="portprocess.html">Berkeley DB Porting Process</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</div>
|
||||
<p>
|
||||
Berkeley DB is an open source database product that supports a
|
||||
variety of platforms. When there is a need to run Berkeley DB on a
|
||||
platform that is currently not supported, DB is distributed in
|
||||
source code form that you can use as base source to port Berkeley
|
||||
DB to that platform.
|
||||
</p>
|
||||
<p>
|
||||
Before you begin actually porting Berkeley DB, you need an
|
||||
understanding of the:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
<a href="introduction.html#porttypes">Types of Berkeley DB ports</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="portprocess.html">Berkeley DB Porting Process</a>
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="porttypes"></a>Types of Berkeley DB ports</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
There are several types of Berkeley DB ports:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
Ports developed and supported by Oracle
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
Ports developed by a customer or a partner, but which Oracle has
|
||||
agreed to support.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
Ports developed, maintained, and supported by a customer or partner.
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<p>
|
||||
For a port developed by a customer or a partner, the general steps for porting
|
||||
Berkeley DB to a new platform are the same whether or not Oracle has agreed to
|
||||
support Berkeley DB on the new platform. For example, after you complete the port
|
||||
you send it to Berkeley DB as described in <a href="sourceintegrate.html">Integrating Changes into the Berkeley DB Source Code</a>.
|
||||
However, there are some differences.
|
||||
</p>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="id793975"></a>When Oracle Has Agreed to Support Berkeley DB on the New Platform</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
When porting Berkeley DB to a platform that Oracle has agreed to support,
|
||||
you need to have Berkeley DB engineering review your port at various points.
|
||||
These review points are discussed more fully in
|
||||
<a href="sourceintegrate.html">Integrating Changes into the Berkeley DB Source Code</a>,
|
||||
<a href="modifytest.html">Modifying the Tests</a>, and
|
||||
<a href="testreview.html">Reviewing the Results of the Tests</a>.
|
||||
</p>
|
||||
<p>
|
||||
It is up to you to submit the results of the tests (test_micro,
|
||||
test_os, test_mutex, and, if possible, the entire tcl test
|
||||
suit) for review by Oracle Berkelely DB engineering in order for Oracle to
|
||||
consider providing support for Berkeley DB on a new platform.
|
||||
</p>
|
||||
<p>
|
||||
You must also assign copyrights for your changes to any part of Berkeley DB
|
||||
to "Oracle Corporation" and attest to the fact that you are not infringing
|
||||
on any software patents for the changes to be included in the general
|
||||
Berekely DB distribution.
|
||||
</p>
|
||||
<p>
|
||||
Once the port is certified, Oracle provides support for Berkeley DB on the
|
||||
new platform in the same manner that it does for Berkeley DB running on
|
||||
other established platforms.
|
||||
</p>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="id794049"></a>When Oracle has Not Agreed to Support Berkeley DB on the New Platform</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
When Oracle has <span class="emphasis"><em>not</em></span> agreed to support
|
||||
Berkeley DB on the new platform, the customer or partner assume the
|
||||
responsibility of front-line support. When it is determined that there is a
|
||||
problem in the code that was not modified by the customer or partner, then
|
||||
Berkeley DB engineering provides support to the customer or vendor who
|
||||
implemented the port, However, in these cases, Oracle needs access to the
|
||||
platform and hardware for diagnosing, debugging, and testing.
|
||||
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="preface.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="index.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="portprocess.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Preface </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Berkeley DB Porting Process</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
64
docs/porting/modifytest.html
Normal file
64
docs/porting/modifytest.html
Normal file
@@ -0,0 +1,64 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Modifying the Tests</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="previous" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="next" href="testrun.html" title="Running the Tests" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Modifying the Tests</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="testport.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="testrun.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="modifytest"></a>Modifying the Tests</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
There should be no need to make modifications to the tests. However, in a few situations, the test hardware may have some constraints (for example, small amount of memory) which may cause certain tests (which expect more memory) to fail. In these rare situations, you may need to modify the tests to work within the constraints of the platform.
|
||||
</p>
|
||||
<p>
|
||||
When Oracle has agreed to support Berkeley DB on the new platform, submit any proposed test changes for review and approval by Oracle Engineering before running the tests.
|
||||
</p>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="testport.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="testport.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="testrun.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Chapter 3. Testing and Certifying the Port </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Running the Tests</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
628
docs/porting/modscope.html
Normal file
628
docs/porting/modscope.html
Normal file
@@ -0,0 +1,628 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>
|
||||
Determining the Scope of the Modifications
|
||||
</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="newbinary.html" title="Chapter 2. Creating a New Berkeley DB Binary" />
|
||||
<link rel="previous" href="newbinary.html" title="Chapter 2. Creating a New Berkeley DB Binary" />
|
||||
<link rel="next" href="buildtarget.html" title=" Building on the Target Platform" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">
|
||||
Determining the Scope of the Modifications
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="newbinary.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 2. Creating a New Berkeley DB Binary</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="buildtarget.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="modscope"></a>
|
||||
Determining the Scope of the Modifications
|
||||
</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Once you have a good build of Berkeley DB on a UNIX or UNIX-like system, look over the code to determine what type of code changes you need to make so that you can successfully build Berkeley DB on your target system. This process involves determining:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html#osfunc">
|
||||
Do Changes Need to be Made to the Operating System Functionality?
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html#standardfunc">Are Some Standard Functions Missing on the Target Platform?</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html#sharedmem">How Will the Port Handle Shared Memory?</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html#typemutex">What Type of Mutexes Will the Port Use?</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html#otherchanges">Do Any Other Changes Need to be Made?</a>
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="osfunc"></a>
|
||||
Do Changes Need to be Made to the Operating System Functionality?
|
||||
</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Berkeley DB uses about forty operating system primitives. The Berkeley DB distribution contains files which are wrappers around these operating system primitives that act as an abstraction layer to separate the main Berkeley DB code from operating system and architecture-specific components. You <span class="emphasis"><em>must</em></span> port these files (or versions of these files) whenever you port Berkeley DB to a new platform.
|
||||
</p>
|
||||
<p>
|
||||
Within a Berkeley DB distribution, typically, there is only a single
|
||||
version of these files for all platforms that Berkeley DB supports. Those
|
||||
versions of the files live in the <tt class="literal">os</tt> directory of the
|
||||
distribution and follow the ANSI C and POSIX 1003.1 standards. Within each
|
||||
file, there is usually one, but sometimes several functions (for example,
|
||||
the <tt class="literal">os_alloc.c</tt> file contains the
|
||||
<tt class="literal">malloc</tt>, <tt class="literal">realloc</tt>,
|
||||
<tt class="literal">strdup</tt>, and <tt class="literal">free</tt> functions). The following table describes the files in the os directory of the Berkeley DB distribution.
|
||||
</p>
|
||||
<div class="informaltable">
|
||||
<table border="1" width="80%">
|
||||
<colgroup>
|
||||
<col />
|
||||
<col />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>
|
||||
<p>
|
||||
Source file
|
||||
</p>
|
||||
</th>
|
||||
<th>
|
||||
<p>
|
||||
Description
|
||||
</p>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_abort.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
abort()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_abs.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return if a filename is an absolute path name
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_addrinfo.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
getaddrinfo(), freeaddrinfo()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_alloc.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
malloc(), realloc(), strdup(), free()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_clock.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
clock_gettime()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_config.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Minor run-time configuration information
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_ctime.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
ctime()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_dir.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return a list of files for a directory
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_errno.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Library and system error translation
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_fid.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return a unique identifier for a file
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_fsync.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
fsync()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_handle.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return a file handle
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_pid.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return a unique identifier for a threa
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_map.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Shared memory mapping
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_mkdir.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
mkdir()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_oflags.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
open() Used to convert open flags to Berkeley DB flags
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_open.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return a file handle
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_rename.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
rename()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_root.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return if application has special permissions
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_rpath.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return last separator in a path
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_rw.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
read(), write()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_seek.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
lseek()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_sleep.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
sleep()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_spin.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return the number of test-and-set mutex spins before blocking
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_stat.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
stat()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_tmpdir.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return the directory name used by the system for temporary files
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_truncate.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
ftruncate()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_uid.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Return unique 32-bit id
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os_unlink.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
unlink()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p>
|
||||
os.yield.c
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
yield()
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<p>
|
||||
When the operating system primitives on the target platform are identical
|
||||
or close to the POSIX semantics that Berkeley DB requiress, then no code
|
||||
changes or minimal code changes to the files in the <tt class="literal">os</tt> directory are required. If the operating system primitives are quite different, then some code changes may be required to bridge the gap between the requirements of Berkeley DB and what the operating system provides.
|
||||
</p>
|
||||
<p>
|
||||
Where different code is required, you write an entirely different version
|
||||
of the file and place it in an <tt class="literal">os</tt>_<span class="emphasis"><em>xxx</em></span> directory where <span class="emphasis"><em>xxx</em></span> represents a platform name.
|
||||
There are <tt class="literal">os</tt>_<span class="emphasis"><em>xxx</em></span>
|
||||
subdirectories in the Berkeley DB distribution for several established
|
||||
non-POSIX platforms. For example, there is a he
|
||||
<tt class="literal">os_vxworks</tt> directory that contains VxWorks
|
||||
versions of some of the files in the os directory, and Windows versions of
|
||||
some files are in the <tt class="literal">os_windows</tt> directory. If
|
||||
your target platform needs a different version of a file, you will need to
|
||||
write that file and place it in a new <tt class="literal">os</tt>_<span class="emphasis"><em>xxx</em></span> directory that you create for your target platform.
|
||||
</p>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="standardfunc"></a>Are Some Standard Functions Missing on the Target Platform?</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
In some cases, the target platform may not provide the few POSIX
|
||||
functions required by Berkeley DB or the functions provided by the
|
||||
target platform may not operate in a standard compliant way.
|
||||
Berkeley DB provides replacement functionsin the
|
||||
<tt class="literal">clib</tt> directory
|
||||
of the Berkeley DB distribution.
|
||||
</p>
|
||||
<p>
|
||||
You need to determine how your target platfrom handles these functions:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
When the target platform does <span class="emphasis"><em>not</em></span> have a POSIX
|
||||
function required by Berkeley DB, no action is required on your
|
||||
part. When Berekely DB cannot find one of these functions on the
|
||||
target platform, it automatically uses the replacement functions
|
||||
supplied in the <tt class="literal">clib</tt> directory of the Berkeley
|
||||
DB distribution. For example, if the target platform does not have
|
||||
the <tt class="literal">atoi</tt> or <tt class="literal">strtol</tt> functions,
|
||||
Berkeley DB uses <tt class="literal">clib/atoi.c</tt> and
|
||||
<tt class="literal">clib/strtol.c</tt>.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
When the target platform has a function required by Berekely DB, but that
|
||||
function operates in a non-standard compliant way, you can code to the
|
||||
replacement functions supplied in the <tt class="literal">clib</tt> directory.
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="sharedmem"></a>How Will the Port Handle Shared Memory?</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
In order to write
|
||||
multiprocess database applications (not multithreaded, but threads of control running in different address spaces), Berkeley DB must be able to name pieces of shared memory and access them from multiple processes.
|
||||
</p>
|
||||
<p>
|
||||
On UNIX/POSIX systems, Berkeley DB uses
|
||||
<tt class="literal">mmap</tt> and <tt class="literal">shmget</tt> for that purpose,
|
||||
but any interface that provides access to named shared memory is
|
||||
sufficient. If you have a simple, flat address space, you should be able
|
||||
to use the code in <tt class="literal">os_vxworks/os_map.c</tt> as a starting point for the port.
|
||||
</p>
|
||||
<p>
|
||||
If you are not intending to write multiprocess database applications, then this won't be necessary, as Berkeley DB can simply allocate memory from the heap if all threads of control will live in a single address space.
|
||||
</p>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="typemutex"></a>What Type of Mutexes Will the Port Use?</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Berkeley DB requires some form of self-blocking mutual exclusion
|
||||
mutex. Blocking mutexes
|
||||
are preferred as they tend to be less CPU-expensive and less likely
|
||||
to cause thrashing. If blocking mutexes are not available, however,
|
||||
test-and-set will work as well. The code for mutexes is in two
|
||||
places in the system: the include file
|
||||
<tt class="literal">dbinc/mutex_int.h</tt>, and the
|
||||
distribution directory <tt class="literal">mutex</tt>.
|
||||
</p>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="otherchanges"></a>Do Any Other Changes Need to be Made?</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
In most cases, you do not need to make any changes to the Berkeley DB
|
||||
source code that is not in the abstraction layer (that is, that is in the
|
||||
<tt class="literal">os</tt> directory) as that code is designed to be platform-independent code. However, in some situations, the compiler for the target platform is non-standard and may raise errors when compiling some aspects of the Berkeley DB code (for example, additional casting may be required, or a certain type may cause a problem). In these cases, you will need to modify the generic Berkeley DB code in order to have error-free compilation.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="newbinary.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="newbinary.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="buildtarget.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Chapter 2. Creating a New Berkeley DB Binary </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Building on the Target Platform</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
177
docs/porting/newbinary.html
Normal file
177
docs/porting/newbinary.html
Normal file
@@ -0,0 +1,177 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Chapter 2. Creating a New Berkeley DB Binary</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="previous" href="portprocess.html" title="Berkeley DB Porting Process" />
|
||||
<link rel="next" href="modscope.html" title=" Determining the Scope of the Modifications " />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Chapter 2. Creating a New Berkeley DB Binary</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="portprocess.html">Prev</a> </td>
|
||||
<th width="60%" align="center"> </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="modscope.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="chapter" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title"><a id="newbinary"></a>Chapter 2. Creating a New Berkeley DB Binary</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div class="toc">
|
||||
<p>
|
||||
<b>Table of Contents</b>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="newbinary.html#basebuild">
|
||||
Creating a Base Build of Berkeley DB
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="modscope.html">
|
||||
Determining the Scope of the Modifications
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#osfunc">
|
||||
Do Changes Need to be Made to the Operating System Functionality?
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#standardfunc">Are Some Standard Functions Missing on the Target Platform?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#sharedmem">How Will the Port Handle Shared Memory?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#typemutex">What Type of Mutexes Will the Port Use?</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="modscope.html#otherchanges">Do Any Other Changes Need to be Made?</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="buildtarget.html"> Building on the Target Platform</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</div>
|
||||
<p>
|
||||
Creating a new Berkeley DB executable on the target platform, involves:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="1">
|
||||
<li>
|
||||
<p>
|
||||
<a href="newbinary.html#basebuild">
|
||||
Creating a Base Build of Berkeley DB
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="modscope.html">
|
||||
Determining the Scope of the Modifications
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="buildtarget.html"> Building on the Target Platform</a>
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="basebuild"></a>
|
||||
Creating a Base Build of Berkeley DB
|
||||
</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
The simplest way to begin a port is to attempt to configure and build Berkeley DB on a UNIX or UNIX-like system. This gives you a list of the files that you needed to build Berkeley DB as well as the configuration files you can use as a starting point for building on your target port.
|
||||
</p>
|
||||
<p>
|
||||
To create a base build of Berkeley DB, following the instructions in the
|
||||
<i class="citetitle">Berkeley DB Programmer's Reference Guide</i>:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="1">
|
||||
<li>
|
||||
<p>
|
||||
Download a Berkeley DB distribution from
|
||||
<a href="http://www.oracle.com/technology/software/products/berkeley-db/db/" target="_top">http://www.oracle.com/technology/software/products/berkeley-db/db/</a>.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
Build Berkeley DB.
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="portprocess.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="index.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="modscope.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Berkeley DB Porting Process </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top">
|
||||
Determining the Scope of the Modifications
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
81
docs/porting/portprocess.html
Normal file
81
docs/porting/portprocess.html
Normal file
@@ -0,0 +1,81 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Berkeley DB Porting Process</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="introduction.html" title="Chapter 1. Introduction to Porting Berkeley DB " />
|
||||
<link rel="previous" href="introduction.html" title="Chapter 1. Introduction to Porting Berkeley DB " />
|
||||
<link rel="next" href="newbinary.html" title="Chapter 2. Creating a New Berkeley DB Binary" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Berkeley DB Porting Process</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="introduction.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 1. Introduction to Porting Berkeley DB </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="newbinary.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="portprocess"></a>Berkeley DB Porting Process</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
As with any porting project, porting Berkeley DB to a new
|
||||
platform consists of the following process:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="1">
|
||||
<li>
|
||||
<p>
|
||||
Determine the modifications that you need to make in the base code
|
||||
and create a working executable of Berkeley DB on the target
|
||||
platform as described in
|
||||
<a href="newbinary.html">Creating a New Berkeley DB Binary</a>.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
Perform final test and quality assurance functions on the target
|
||||
platform as described in
|
||||
<a href="testport.html">Testing and Certifying the Port</a>.
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="introduction.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="introduction.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="newbinary.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Chapter 1. Introduction to Porting Berkeley DB </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Chapter 2. Creating a New Berkeley DB Binary</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
228
docs/porting/preface.html
Normal file
228
docs/porting/preface.html
Normal file
@@ -0,0 +1,228 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Preface</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="previous" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="next" href="introduction.html" title="Chapter 1. Introduction to Porting Berkeley DB " />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Preface</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="index.html">Prev</a> </td>
|
||||
<th width="60%" align="center"> </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="introduction.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="preface" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title"><a id="preface"></a>Preface</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div class="toc">
|
||||
<p>
|
||||
<b>Table of Contents</b>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="preface.html#conventions">Conventions Used in this Book</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="preface.html#audience">Audience</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect2">
|
||||
<a href="preface.html#moreinfo">For More Information</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<p>
|
||||
The Berkeley DB family of open source, embeddable databases
|
||||
provides developers with fast, reliable persistence with zero
|
||||
administration. Often deployed as "edge" databases, the Berkeley DB
|
||||
family provides very high performance, reliability, scalability,
|
||||
and availability for application use cases that do not require SQL.
|
||||
</p>
|
||||
<p>
|
||||
As an open source database, Berkeley DB works on many different
|
||||
platforms, from Wind River's Tornado system, to VMS, to
|
||||
Windows NT and Windows 95, and most existing UNIX
|
||||
platforms. It runs on 32 and 64-bit machines, little or big-endian.
|
||||
</p>
|
||||
<p>
|
||||
<span class="emphasis"><em>Berkeley DB Porting Guide</em></span> provides the information you need to
|
||||
port Berkeley DB to additional platforms.
|
||||
</p>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="conventions"></a>Conventions Used in this Book</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
The following typographical conventions are used within in this manual:
|
||||
</p>
|
||||
<p>
|
||||
Structure names are represented in <tt class="classname">monospaced font</tt>, as are <tt class="methodname">method
|
||||
names</tt>. For example: "<tt class="methodname">DB->open()</tt> is a method
|
||||
on a <tt class="classname">DB</tt> handle."
|
||||
</p>
|
||||
<p>
|
||||
Variable or non-literal text is presented in <span class="emphasis"><em>italics</em></span>. For example: "Go to your
|
||||
<span class="emphasis"><em>DB_INSTALL</em></span>
|
||||
directory."
|
||||
</p>
|
||||
<p>
|
||||
Program examples are displayed in a <tt class="classname">monospaced font</tt> on a shaded background.
|
||||
For example:
|
||||
</p>
|
||||
<pre class="programlisting">/* File: gettingstarted_common.h */
|
||||
typedef struct stock_dbs {
|
||||
DB *inventory_dbp; /* Database containing inventory information */
|
||||
DB *vendor_dbp; /* Database containing vendor information */
|
||||
|
||||
char *db_home_dir; /* Directory containing the database files */
|
||||
char *inventory_db_name; /* Name of the inventory database */
|
||||
char *vendor_db_name; /* Name of the vendor database */
|
||||
} STOCK_DBS; </pre>
|
||||
<div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
|
||||
<h3 class="title">Note</h3>
|
||||
<p>
|
||||
Finally, notes of interest are represented using a note block such
|
||||
as this.
|
||||
</p>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="audience"></a>Audience</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
This guide is intended
|
||||
for programmers porting Berkeley DB to a new platform. It
|
||||
assumes that these programmers possess:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
Familiarity with standard ANSI C and POSIX C 1003.1 and 1003.2 library and system
|
||||
calls.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
|
||||
Working knowledge of the target platform as well as the development tools (for example, compilers, linkers, and debuggers) available on that platform.
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sect2" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h3 class="title"><a id="moreinfo"></a>For More Information</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Beyond this manual, you may also find the following sources of information useful when building a
|
||||
DB application:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/gsg/C/index.html" target="_top">
|
||||
Getting Started with Berkeley DB for C
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/gsg_txn/C/index.html" target="_top">
|
||||
Getting Started with Transaction Processing for C
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/gsg_db_rep/C/index.html" target="_top">
|
||||
Berkeley DB Getting Started with Replicated Applications for C
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/ref/toc.html" target="_top">
|
||||
Berkeley DB Programmer's Reference Guide
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/api_c/frame.html" target="_top">
|
||||
Berkeley DB C API
|
||||
</a>
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="index.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="index.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="introduction.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Porting Berkeley DB </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Chapter 1. Introduction to Porting Berkeley DB </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
81
docs/porting/sourceintegrate.html
Normal file
81
docs/porting/sourceintegrate.html
Normal file
@@ -0,0 +1,81 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Integrating Changes into the Berkeley DB Source Code</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="previous" href="testreview.html" title="Reviewing the Results of the Tests" />
|
||||
<link rel="next" href="certport.html" title="Certifying a Port of Berkeley DB" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Integrating Changes into the Berkeley DB Source Code</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="testreview.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="certport.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="sourceintegrate"></a>Integrating Changes into the Berkeley DB Source Code</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
Once you have have a completed your port send all code changes that you made as "diff" files to Berkeley DB development for review.
|
||||
</p>
|
||||
<p>
|
||||
Exactly how you integrate changes into the Berkeley DB source code varies depending on whether or not Oracle has agreed to support Berkeley DB on the new platform:
|
||||
</p>
|
||||
<p>
|
||||
At this point, when Oracle has agreed to support Berkeley DB on the new platform:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="1">
|
||||
<li>
|
||||
<p>
|
||||
Berkeley DB development reviews the changes, makes the changes (with modifications if necessary) in the source code, creates another snapshot which includes the new platform-specific changes, and sends you the new snapshot.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
On receipt of the new snapshot, recompile this new snapshot. If the new snapshot compiles correctly without any changes, test the port again.
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="testreview.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="testport.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="certport.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Reviewing the Results of the Tests </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Certifying a Port of Berkeley DB</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
183
docs/porting/testport.html
Normal file
183
docs/porting/testport.html
Normal file
@@ -0,0 +1,183 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Chapter 3. Testing and Certifying the Port</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="previous" href="buildtarget.html" title=" Building on the Target Platform" />
|
||||
<link rel="next" href="modifytest.html" title="Modifying the Tests" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="buildtarget.html">Prev</a> </td>
|
||||
<th width="60%" align="center"> </th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="modifytest.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="chapter" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title"><a id="testport"></a>Chapter 3. Testing and Certifying the Port</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div class="toc">
|
||||
<p>
|
||||
<b>Table of Contents</b>
|
||||
</p>
|
||||
<dl>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testport.html#testtypes">Types of Tests for Berkeley DB</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="modifytest.html">Modifying the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testrun.html">Running the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="testreview.html">Reviewing the Results of the Tests</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="sourceintegrate.html">Integrating Changes into the Berkeley DB Source Code</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dt>
|
||||
<span class="sect1">
|
||||
<a href="certport.html">Certifying a Port of Berkeley DB</a>
|
||||
</span>
|
||||
</dt>
|
||||
</dl>
|
||||
</div>
|
||||
<p>
|
||||
There are several different types of tests available for validating your
|
||||
port of Berkeley DB as discussed in <a href="testport.html#testtypes">Types of Tests for Berkeley DB</a>. Testing your port involves:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
<a href="modifytest.html">Modifying the Tests</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="testrun.html">Running the Tests</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="testreview.html">Reviewing the Results of the Tests</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="sourceintegrate.html">Integrating Changes into the Berkeley DB Source Code</a>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<a href="certport.html">Certifying a Port of Berkeley DB</a>
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="testtypes"></a>Types of Tests for Berkeley DB</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
There are two types of tests available for testing your port of Berkeley DB:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>The C Tests for Berkeley DB</p>
|
||||
<p>
|
||||
There are three types of C tests for Berkeley DB. Each of these is in its own directory:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="circle">
|
||||
<li>
|
||||
<p>
|
||||
<tt class="literal">test_os</tt>
|
||||
contains files that test the system primitives. See the
|
||||
<tt class="literal">test_os/Test_OS_Technical_Detail</tt> file for detailed information on these tests (for example, how each function is tested).
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<tt class="literal">test_mutex</tt>
|
||||
contains files that test the use of mutexes in Berkeley DB.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<tt class="literal">test_micro</tt>
|
||||
contains the C tests that exercise the most common code paths, but it is
|
||||
not intended to be an exhaustive Test Suite. Additionally, it tests the
|
||||
different versions of Berkeley DB (including the new port) against each
|
||||
other. The <tt class="literal">test_micro</tt> tests can either be run in a shell or as simple C tests.
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p>The Berkeley DB Test Suite</p>
|
||||
<p>
|
||||
The <tt class="literal">test</tt> directory contains the Berkeley DB Test Suite that tests all of the code in Berkeley DB. Using the Test Suite involves using Tool Command Language (Tcl) version 8.4 or later. Running the standard version of the Test Suite executes tests the major functionality of Berkeley DB. A more exhaustive version of the Test Suite runs all the tests several more times, testing encryption, replication, and different page sizes.
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="buildtarget.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="index.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="modifytest.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top"> Building on the Target Platform </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Modifying the Tests</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
66
docs/porting/testreview.html
Normal file
66
docs/porting/testreview.html
Normal file
@@ -0,0 +1,66 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Reviewing the Results of the Tests</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="previous" href="testrun.html" title="Running the Tests" />
|
||||
<link rel="next" href="sourceintegrate.html" title="Integrating Changes into the Berkeley DB Source Code" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Reviewing the Results of the Tests</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="testrun.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="sourceintegrate.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="testreview"></a>Reviewing the Results of the Tests</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
It is up to you to submit the results of the tests
|
||||
(<tt class="literal">test_micro</tt>, <tt class="literal">test_os</tt>,
|
||||
<tt class="literal">test_mutex</tt>, and, if possible, the entire tcl test suit) for review by Oracle Berkelely DB engineering in order for Oracle to consider providing support for Berkeley DB on a new platform.
|
||||
</p>
|
||||
<p>
|
||||
When Oracle has <span class="emphasis"><em>not</em></span> agreed to support Berkeley DB on the new platform, you are responsible for ensuring that the tests run successfully.
|
||||
</p>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="testrun.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="testport.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="sourceintegrate.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Running the Tests </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Integrating Changes into the Berkeley DB Source Code</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
131
docs/porting/testrun.html
Normal file
131
docs/porting/testrun.html
Normal file
@@ -0,0 +1,131 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Running the Tests</title>
|
||||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||||
<meta name="generator" content="DocBook XSL Stylesheets V1.62.4" />
|
||||
<link rel="home" href="index.html" title="Porting Berkeley DB" />
|
||||
<link rel="up" href="testport.html" title="Chapter 3. Testing and Certifying the Port" />
|
||||
<link rel="previous" href="modifytest.html" title="Modifying the Tests" />
|
||||
<link rel="next" href="testreview.html" title="Reviewing the Results of the Tests" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="navheader">
|
||||
<table width="100%" summary="Navigation header">
|
||||
<tr>
|
||||
<th colspan="3" align="center">Running the Tests</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="20%" align="left"><a accesskey="p" href="modifytest.html">Prev</a> </td>
|
||||
<th width="60%" align="center">Chapter 3. Testing and Certifying the Port</th>
|
||||
<td width="20%" align="right"> <a accesskey="n" href="testreview.html">Next</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="sect1" lang="en" xml:lang="en">
|
||||
<div class="titlepage">
|
||||
<div>
|
||||
<div>
|
||||
<h2 class="title" style="clear: both"><a id="testrun"></a>Running the Tests</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<p>
|
||||
You test your new port of Berkeley DB by running the tests in the following order:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="1">
|
||||
<li>
|
||||
<p>
|
||||
Run the C tests in the following order:
|
||||
</p>
|
||||
<div class="orderedlist">
|
||||
<ol type="a">
|
||||
<li>
|
||||
<p>
|
||||
Tests for the system primitives located in the
|
||||
<tt class="literal">test_os</tt> directory. To run the tests, follow the
|
||||
instructions in the <tt class="literal">test_os/readme</tt> file.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
|
||||
Tests for mutexes located in the <tt class="literal">test_mutex</tt>
|
||||
directory. To run the tests, follow the instructions in the
|
||||
<tt class="literal">test_mutex/readme</tt> file.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
Tests for the common code paths located in the
|
||||
<tt class="literal">test_micro</tt> directory. To run the tests in a shell
|
||||
script, follow the instructions in the
|
||||
<tt class="literal">test_micro/readme</tt> file. To run the tests as
|
||||
simple C tests, follow the instructions in the
|
||||
<tt class="literal">test_micro/readme_embedded</tt> file.
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
If the target platform supports the use of Tcl (version 8.4 or later), run the Test Suite.
|
||||
How you run the Test Suite varies depending on the target platform:
|
||||
</p>
|
||||
<div class="itemizedlist">
|
||||
<ul type="disc">
|
||||
<li>
|
||||
<p>
|
||||
If the target platform supports a UNIX-like version of Tcl, then set up Tcl
|
||||
and build the Test Suite as described in "Running the Test Suite under
|
||||
UNIX" in <i class="citetitle">Berkeley DB Programmer's Reference Guide</i> at
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/ref/build_unix/test.html" target="_top">http://www.oracle.com/technology/documentation/berkeley-db/db/ref/build_unix/test.html</a>
|
||||
and, then, run the Test Suite as described in "Running the Test Suite" in
|
||||
<i class="citetitle">Berkeley DB Programmer's Reference Guide</i> at
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/ref/test/run.html" target="_top">http://www.oracle.com/technology/documentation/berkeley-db/db/ref/test/run.html</a>.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
|
||||
If the target platform supports a Windows-like version of Tcl, then
|
||||
setup Tcl, and build and run the Test Suite as described in
|
||||
"Running the Test Suite under Windows" in
|
||||
<i class="citetitle">Berkeley DB Programmer's Reference Guide</i> at
|
||||
<a href="http://www.oracle.com/technology/documentation/berkeley-db/db/ref/build_win/test.html" target="_top">http://www.oracle.com/technology/documentation/berkeley-db/db/ref/build_win/test.html</a>
|
||||
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<div class="navfooter">
|
||||
<hr />
|
||||
<table width="100%" summary="Navigation footer">
|
||||
<tr>
|
||||
<td width="40%" align="left"><a accesskey="p" href="modifytest.html">Prev</a> </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="u" href="testport.html">Up</a>
|
||||
</td>
|
||||
<td width="40%" align="right"> <a accesskey="n" href="testreview.html">Next</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="40%" align="left" valign="top">Modifying the Tests </td>
|
||||
<td width="20%" align="center">
|
||||
<a accesskey="h" href="index.html">Home</a>
|
||||
</td>
|
||||
<td width="40%" align="right" valign="top"> Reviewing the Results of the Tests</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user