summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2021-01-23 15:34:24 +0100
committerCarl Hetherington <cth@carlh.net>2021-01-23 15:34:24 +0100
commitb75d977a38f039fd68ed5d4055ae70b4bf631603 (patch)
treed26d62a6d3f50f375fad7811e0c6e884cac299de
parentac98ff177ee2912cc51dc99595cd4e80a46976f9 (diff)
Tidy a little and add some coding style.
-rw-r--r--README.md34
1 files changed, 20 insertions, 14 deletions
diff --git a/README.md b/README.md
index e4034936..e03f4fb4 100644
--- a/README.md
+++ b/README.md
@@ -1,11 +1,9 @@
-libdcp
-======
+# libdcp
Library for reading and writing Digital Cinema Packages (DCPs).
-Acknowledgements
-================
+# Acknowledgements
Wolfgang Woehl's cinemaslides was most informative on the
nasty details of encryption.
@@ -14,8 +12,7 @@ libdcp is written by Carl Hetherington and Mart Jansink.
Bugfixes were received from Philip Tschiemer.
-Building
-========
+# Building
```
./waf configure
@@ -24,8 +21,7 @@ Building
```
-Dependencies
---------
+# Dependencies
- pkg-config (for build system)
- boost (1.45 or above): filesystem, signals2, datetime and unit testing libraries
@@ -42,8 +38,8 @@ Dependencies
- (optional) gcov (for tests)
-Build options
----------
+# Build options
+
```
--target-windows set up to do a cross-compile to Windows
--enable-debug build with debugging information and without optimisation
@@ -57,8 +53,8 @@ Build options
--force-cpp11 force use of C++11
```
-A note on building for macOS
---------
+# A note on building for macOS
+
As goto solution, all dependencies can be installed using [Homebrew](https://brew.sh/).
Make sure to add the respective `PKG_CONFIG_PATH` paths so the packages are indeed found.
@@ -86,9 +82,19 @@ export CXX=/usr/local/opt/llvm/bin/clang++
```
-Documentation
-=============
+# Documentation
Run doxygen in the top-level directory and then see build/doc/html/index.html.
There are some examples in the examples/ directory.
+
+
+# Coding style
+
+* Use C++11 but nothing higher, as we need the library to be usable on some quite old compilers.
+* Put a Doxygen @file comment under the GPL banner in each source file.
+* Two blank lines between methods, and between 'blocks' in headers.
+* Doxygen comments in header files for public methods, source files for protected / private methods; no full stops after simple doxygen strings.
+* Use `= delete` on copy constructors and assignment operators instead of boost::noncopyable.
+* Initialise POD members in classes in the header.
+* Use std::make_shared to create shared pointers to things.