[ANDROID] Deactivate some features if we are compiling for android.

Android libc doesn't support all thread feature (as pthread_cancel).
Do not compile those files if we are compiling for android.
This commit is contained in:
Matthieu Gautier 2017-02-22 16:56:21 +01:00
parent 9616530648
commit aafe9a4435
3 changed files with 15 additions and 4 deletions

View File

@ -1,11 +1,14 @@
headers = [
'indexer.h',
'library.h',
'manager.h',
'reader.h',
'searcher.h'
]
if not get_option('android')
headers += ['indexer.h']
endif
if xapian_dep.found()
headers += ['xapianIndexer.h', 'xapianSearcher.h']
endif

View File

@ -1,2 +1,4 @@
option('ctpp2-install-prefix', type : 'string', value : '',
description : 'Prefix where ctpp libs has been installed')
description : 'Prefix where ctpp libs has been installed')
option('android', type : 'boolean', value : false,
description : 'Do we make a kiwix-lib for android')

View File

@ -3,7 +3,6 @@ kiwix_sources = [
'manager.cpp',
'reader.cpp',
'searcher.cpp',
'indexer.cpp',
'common/base64.cpp',
'common/pathTools.cpp',
'common/regexTools.cpp',
@ -16,7 +15,14 @@ kiwix_sources = [
kiwix_sources += lib_resources
if xapian_dep.found()
kiwix_sources += ['xapianIndexer.cpp', 'xapianSearcher.cpp']
kiwix_sources += ['xapianSearcher.cpp']
if not get_option('android')
kiwix_sources += ['xapianIndexer.cpp']
endif
endif
if not get_option('android')
kiwix_sources += ['indexer.cpp']
endif
if has_ctpp2_dep