Fix compilation with latest ndn-cxx
And switch source archive to xz compression
Change-Id: I2d6cf9c0f455dd377308b51f80997e4731d11fa2
diff --git a/docs/conf.py b/docs/conf.py
index 255dbe3..d1a6386 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -35,12 +35,15 @@
'sphinx.ext.todo',
]
-def addExtensionIfExists(extension):
- if importlib.util.find_spec(extension) is not None:
- extensions.append(extension)
- else:
+def addExtensionIfExists(extension: str):
+ try:
+ if importlib.util.find_spec(extension) is None:
+ raise ModuleNotFoundError(extension)
+ except (ImportError, ValueError):
sys.stderr.write(f'WARNING: Extension {extension!r} not found. '
- 'Some documentation may not build correctly.\n')
+ 'Some documentation may not build correctly.\n')
+ else:
+ extensions.append(extension)
addExtensionIfExists('sphinxcontrib.doxylink')