Fix markup to be compatible with Sphinx and add rough API doc
diff --git a/doc/api.rst b/doc/api.rst
new file mode 100644
index 0000000..2efddd0
--- /dev/null
+++ b/doc/api.rst
@@ -0,0 +1,9 @@
+API
+===
+
+.. toctree::
+ :maxdepth: 2
+
+ api/crypto
+ api/rand
+ api/SSL
diff --git a/doc/api/SSL.rst b/doc/api/SSL.rst
new file mode 100644
index 0000000..434721e
--- /dev/null
+++ b/doc/api/SSL.rst
@@ -0,0 +1,11 @@
+OpenSSL.SSL module
+==================
+
+.. automodule:: OpenSSL.SSL
+ :members:
+
+.. autoclass:: OpenSSL.SSL.Context
+ :members:
+
+.. autoclass:: OpenSSL.SSL.Connection
+ :members:
diff --git a/doc/api/crypto.rst b/doc/api/crypto.rst
new file mode 100644
index 0000000..222431d
--- /dev/null
+++ b/doc/api/crypto.rst
@@ -0,0 +1,38 @@
+OpenSSL.crypto module
+=====================
+
+
+.. automodule:: OpenSSL.crypto
+ :members:
+
+.. autoclass:: OpenSSL.crypto.X509
+ :members:
+
+.. autoclass:: OpenSSL.crypto.X509Name
+ :members:
+
+.. autoclass:: OpenSSL.crypto.X509Req
+ :members:
+
+.. autoclass:: OpenSSL.crypto.X509StoreType
+ :members:
+
+.. autoclass:: OpenSSL.crypto.PKey
+ :members:
+
+.. autoclass:: OpenSSL.crypto.PKCS7Type
+ :members:
+
+.. autoclass:: OpenSSL.crypto.PKCS12
+ :members:
+
+.. autoclass:: OpenSSL.crypto.NetscapeSPKI
+ :members:
+
+.. autoclass:: OpenSSL.crypto.CRL
+ :members:
+
+.. autoclass:: OpenSSL.crypto.Revoked
+ :members:
+
+
diff --git a/doc/api/rand.rst b/doc/api/rand.rst
new file mode 100644
index 0000000..640cf85
--- /dev/null
+++ b/doc/api/rand.rst
@@ -0,0 +1,6 @@
+OpenSSL.rand module
+===================
+
+
+.. automodule:: OpenSSL.rand
+ :members:
diff --git a/doc/conf.py b/doc/conf.py
index 395a16a..c7bcb13 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -13,6 +13,9 @@
import sys, os
+DOC_DIR = os.path.abspath(os.path.dirname(__file__))
+sys.path.insert(0, os.path.abspath(os.path.join(DOC_DIR, "..")))
+
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
@@ -25,7 +28,7 @@
# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
-extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx']
+extensions = ['sphinx.ext.autodoc']
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
diff --git a/doc/index.rst b/doc/index.rst
index c2aa3f5..fd79546 100644
--- a/doc/index.rst
+++ b/doc/index.rst
@@ -11,6 +11,8 @@
.. toctree::
:maxdepth: 2
+ api
+
Indices and tables
==================