Skip to content

Commit 352dee5

Browse files
PeterTurcanalandefreitas
authored andcommitted
Contributor guide legacy content
1 parent e527bbf commit 352dee5

11 files changed

+428
-14
lines changed

contributor-guide/modules/ROOT/nav.adoc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
1-
* New Content
2-
* xref:index.adoc[Contributor Guide]
1+
2+
33
* xref:intro.adoc[Introduction to becoming a Boost Contributor]
4+
** xref:license-requirements.adoc[License Requirements]
5+
** xref:portability-requirements.adoc[Portability Requirements]
6+
** xref:organization-requirements.adoc[Organization Requirements]
7+
** xref:library-design-guidelines.adoc[Library Design Guidelines]
48
* xref:antora.adoc[Antora Guide]
59
* Legacy Content
610
** xref:documentation-overview.adoc[Writing Documentation for Boost - Documentation Structure]

contributor-guide/modules/ROOT/pages/documentation-structure-guidelines.adoc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,14 @@ Where you see `<LibraryName>` in the templates, replace with the name of your li
1111
== Contents
1212

1313
. xref:templates/01-overview-template.adoc[Overview]
14+
15+
+
16+
*Library Guide*
17+
. Basic Tutorials or Examples
18+
. How to compile and link
19+
. How to test and debug
1420
+
15-
*Reference*
21+
*Library Reference*
1622

1723
. xref:templates/02-header-template.adoc[\{\{header}}]
1824

@@ -22,7 +28,7 @@ Where you see `<LibraryName>` in the templates, replace with the name of your li
2228

2329
. xref:templates/05-definitions-template.adoc[Definitions]
2430

25-
. Tutorials or Examples
31+
. More Advanced Tutorials or Examples
2632

2733
. Advanced Topics
2834

contributor-guide/modules/ROOT/pages/intro.adoc

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,18 @@ As a first step to developing a library, read the Requirements Overview for Boos
1111

1212
To avoid a proposed library being rejected, it must meet these requirements:
1313

14-
. The license must meet the <<License Requirements>>. Restricted licenses like the GPL and LGPL are not acceptable.
15-
. The <<Copyright Ownership>> must be clear.
14+
. The license must meet the xref:license-requirements.adoc[License Requirements]. Restricted licenses like the GPL and LGPL are not acceptable.
15+
. The <<Ownership>> (copyright) must be clear.
16+
1617
. The library should be useful to a general audience.
17-
. The library must meet the <<Portability Requirements>>.
18-
. The library should preferably meet the <<Organization Requirements>>. But is only required to meet them after acceptance.
18+
19+
. The library must meet the xref:portability-requirements.adoc[Portability Requirements].
20+
21+
. The library should preferably meet the xref:organization-requirements.adoc[Organization Requirements]. But is only required to meet them after acceptance.
22+
1923
. The library must come reasonably close to meeting the
20-
<<Design Guidelines>>.
24+
xref:library-design-guidelines.adoc[Library Design Guidelines].
25+
2126
. The author must be willing to participate in discussions
2227
on the mailing list, and to refine the library accordingly.
2328

@@ -26,13 +31,12 @@ TIP:: There's no requirement that an author read the mailing list
2631
however, that submissions which begin "I just started to read
2732
this mailing list ..." seem to fail, often embarrassingly.
2833

29-
== License Requirements
34+
== Ownership
3035

31-
== Copyright Ownership
36+
Before proceeding, are you sure you own the library you are thinking of submitting? In the book *How to Copyright Software*" by MJ Salone, Nolo Press, 1990 says:
3237

33-
== Portability Requirements
38+
_"Doing work on your own time that is very similar to programming you do for your employer on company time can raise nasty legal problems. In this situation, it's best to get a written release from your employer in advance."_
3439

35-
== Organization Requirements
40+
Place a copyright notice in all the important files you submit. Boost won't accept libraries without clear copyright information.
3641

37-
== Design Guidelines
3842

contributor-guide/modules/ROOT/pages/library-design-guidelines.adoc

Lines changed: 279 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
= License Requirements
2+
3+
The preferred way to meet the license requirements is to use the https://www.boost.org/LICENSE_1_0.txt[Boost Software License]. See license information. If for any reason you do not intend to use the Boost Software License, please discuss the issues on the Boost developers mailing list first.
4+
5+
The license requirements:
6+
7+
* Must be simple to read and understand.
8+
* Must grant permission without fee to copy, use and modify the software for any use (commercial and non-commercial).
9+
* Must require that the license appear on all copies of the software source code.
10+
* Must not require that the license appear with executables or other binary uses of the library.
11+
* Must not require that the source code be available for execution or other binary uses of the library.
12+
* May restrict the use of the name and description of the library to the standard version found on the Boost web site.
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
= Organization Requirements
2+
3+
The quality of the Boost libraries is not just about the APIs and code design. But also about presenting a consistent view to users of the libraries as a whole. Upon acceptance libraries must adhere to this directory and file structure:
4+
5+
== Boost Standard Library Organization
6+
7+
[cols="1,5,2",options="header"]
8+
|===
9+
|Sub-directory or file |Contents |Required
10+
|*build* |Library build files such as a Jamfile, IDE projects, Makefiles, Cmake files, etc. |Required if the library has sources to build.
11+
|*config* |Files used for build-time configuration checks. This directory may contain source files and build system scripts to be used when building the library, tests or examples to check if the target system satisfies certain conditions. For example, a check may test if the compiler implements a certain feature, or if the target system supports a certain API. |Optional.
12+
|*doc* |Sources to build with and built documentation for the library. If the library needs to build documentation from non-HTML files this location must be build-able with Boost Build. |Required for all libraries.
13+
|*doc/html* |Documentation (HTML) files. |Required for all libraries with pregenerated documentation. And generated documentation must be generated here.
14+
|*example* |Sample program files. |Required if library has sample files. Which is highly recommended.
15+
|*index.html* |Redirection to HTML documentation. See "Redirection" for a template for this file. |Required for all libraries.
16+
|*include/boost/library* |Header files for the library. |Required for all libraries.
17+
|*meta* |Meta-data about the library. |Required for all libraries.
18+
|*meta/libraries.json* |A JSON file containing information about the library used to generate website and documentation for the Boost C++ Libraries collection. |Required for all libraries.
19+
|*meta/explicit-failures-markup.xml* |XML file describing expected test failures, used to generate the test report. |Optional
20+
|*src* |Source files which must be compiled to build the library. |Required if the library has source files to build.
21+
|*test* |Regression or other test programs or scripts. This is the only location considered for automated testing. If you have additional locations that need to be part of automated testing it is required that this location refer to the additional test locations. |Required for all libraries.
22+
|*tools* |Tools used, or offered, by the library. The structure within this is up to the library, but it's recommended to use similar structure as a regular Boost library or tool. |Required for libraries that have run-able tools.
23+
|===
24+
25+
== Integration
26+
27+
Once a library is accepted as part of the Boost Libraries it is required that it integrate properly into the development, testing, documentation, and release processes. This integration increases the eventual quality of all the libraries and is integral to the expected quality of the whole of the Boost C++ Libraries from users. In addition to the organization requirements above the following integration is required:
28+
29+
=== Building Sources
30+
31+
The library needs to provide a Boost Build project that the user, and the top level Boost project, can use to build the library if it has sources to build. The Jamfile for the source build needs to minimally declare the project, the library target(s), and register the target(s) for installation. For example:
32+
33+
[source,bash]
34+
----
35+
project boost/my_lib ;
36+
37+
lib boost_my_lib : a.cpp ;
38+
39+
boost-install boost_my_lib ;
40+
----
41+
42+
=== Testing
43+
44+
The library needs to provide a Boost Build project that the user, and the root Boost test script, can use to build and run the tests for the library. The testing build project must reside in the project-root/test directory and must be build-able from this or another directory (for example, b2 libs/library/test from the Boost root must work.)
45+
46+
An example test/Jamfile is given below:
47+
[source,bash]
48+
----
49+
import testing ;
50+
51+
run default_constructor.cpp ;
52+
run copy_constructor.cpp ;
53+
compile nested_value_type.cpp ;
54+
compile-fail invalid_conversion_1.cpp ;
55+
----
56+
57+
WARNING:: This is the only location considered for testing by the top level testing script. If you want to test additional locations you must declare such that they are built as dependencies or by using build-project.
58+
59+
If the library requires a level of C++ conformance that precludes certain compilers or configurations from working, it's possible (and recommended) to declare these requirements in the test Jamfile so that the tests aren't run, to conserve test resources, as given in the example below:
60+
61+
[source,bash]
62+
----
63+
import testing ;
64+
import ../../config/checks/config : requires ;
65+
66+
project : requirements [ requires cxx11_variadic_templates cxx11_template_aliases ] ;
67+
68+
run cpp11_test.cpp ;
69+
----
70+
71+
For more information, see the documentation of Boost.Config.
72+
73+
=== Building Documentation
74+
75+
The library needs to provide a Boost Build project for building the documentation for the library. The project-root/doc project is the only location referred to by the top level documentation build scripts and the release building scripts. The documentation build project must have the following two features:
76+
77+
Define a boostdoc target. This target should likely be an alias that looks roughly like:
78+
79+
[source,bash]
80+
----
81+
alias boostdoc : my_boostbook_target
82+
: : : <implicit-dependency>my_boostbook_target ;
83+
----
84+
85+
But if your project doesn't integrate into the global documentation book you can use an empty alias like:
86+
87+
[source,bash]
88+
----
89+
alias boostdoc ;
90+
----
91+
92+
The project must default to building standalone documentation if it has any. The release scripts build this default so as to guarantee all projects have up to date documentation.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
= Portability Requirements
2+
3+
* A library's interface must be portable and not restricted to a particular compiler or operating system.
4+
* A library's implementation must if possible be portable and not restricted to a particular compiler or operating system. If a portable implementation is not possible, non-portable constructions are acceptable if reasonably easy to port to other environments, and implementations are provided for at least two popular operating systems (such as UNIX and Windows).
5+
* A library runs on at least two C++ compilers implementing the latest ISO standard.
6+
* There is no requirement that a library run on C++ compilers which do not conform to the ISO standard.
7+
* There is no requirement that a library run on any particular C++ compiler. Boost contributors often try to ensure their libraries work with popular compilers. The `boost/config.hpp` configuration header is the preferred mechanism for working around compiler deficiencies.
8+
9+
Since there is no absolute way to prove portability, many boost submissions demonstrate practical portability by compiling and executing correctly with two different C++ compilers, often under different operating systems. Otherwise reviewers may disbelieve that porting is in fact practical.

contributor-guide/modules/ROOT/pages/templates/01-overview-template.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ A developer should have a good idea if the library is right for their project, a
88

99
Note that footnote references link to the footnotes section, and the entries in the footnote section link back to the references.
1010

11+
== AsciiDocs Source
12+
1113
[source,t]
1214
----
1315

contributor-guide/modules/ROOT/pages/templates/02-header-template.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
Provide a complete API reference to your library.
44

5+
== AsciiDocs Source
6+
57
[source,txt]
68
----
79

contributor-guide/modules/ROOT/pages/templates/03-configuration-template.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
Describe the configuration macros that are used in your library.
44

5+
== AsciiDocs Source
6+
57
[source,txt]
68
----
79

0 commit comments

Comments
 (0)