Browse Source

Bugfixes in lodel/buildconf.py & mongodb plugin

Yann Weber 7 years ago
parent
commit
be01af2c3e
4 changed files with 5 additions and 5 deletions
  1. 2
    2
      configure.ac
  2. 1
    1
      lodel/buildconf.py.in
  3. 0
    1
      lodel/plugin/plugins.py
  4. 2
    1
      plugins/mongodb_datasource/__init__.py

+ 2
- 2
configure.ac View File

@@ -44,10 +44,10 @@ PC_PYTHON_CHECK_MODULE([werkzeug], ,
44 44
 	AC_MSG_WARN([Module werkzeug not found but mandatory for default web interface])
45 45
 	AC_SUBST([WEBUI], 'False'))
46 46
 #Mongo datasource deps
47
-AC_SUBST([MONGODB], 'True') #Can be found in lodel/buildconf.py
47
+AC_SUBST([PYMONGO], 'True') #Can be found in lodel/buildconf.py
48 48
 PC_PYTHON_CHECK_MODULE([pymongo], ,
49 49
 	AC_MSG_WARN([Module pymongo not found. The mongodb datasource will not be able to work])
50
-	AC_SUBST([MONGODB], 'False'))
50
+	AC_SUBST([PYMONGO], 'False'))
51 51
 
52 52
 #Documentation checks
53 53
 AC_SUBST([DOCOK], 'OK')

+ 1
- 1
lodel/buildconf.py.in View File

@@ -1,5 +1,5 @@
1 1
 ##@brief Stores constant evaluated at build time
2 2
 #@note Populated by ./configure
3 3
 
4
-PYMONGO=@MONGODB@
4
+PYMONGO=@PYMONGO@
5 5
 WEBUI=@WEBUI@

+ 0
- 1
lodel/plugin/plugins.py View File

@@ -7,7 +7,6 @@ import copy
7 7
 import json
8 8
 from importlib.machinery import SourceFileLoader, SourcelessFileLoader
9 9
 
10
-import plugins
11 10
 from lodel import logger
12 11
 from lodel.settings.utils import SettingsError
13 12
 from .exceptions import *

+ 2
- 1
plugins/mongodb_datasource/__init__.py View File

@@ -17,4 +17,5 @@ __fullname__ = "MongoDB plugin"
17 17
 #
18 18
 # @return bool|str : True if all the checks are OK, an error message if not
19 19
 def _activate():
20
-    return True
20
+    from lodel import buildconf
21
+    return buildconf.PYMONGO

Loading…
Cancel
Save