Tweak include/lib dir detection in ffi.py

Joint work with @carlosmn
This commit is contained in:
Jasper Lievisse Adriaanse
2014-07-03 10:10:38 +02:00
parent 1d509c1109
commit b0bf223276

View File

@@ -112,9 +112,9 @@ with codecs.open(decl_path, 'r', 'utf-8') as header:
# if LIBGIT2 exists, set build and link against that version # if LIBGIT2 exists, set build and link against that version
libgit2_path = getenv('LIBGIT2') libgit2_path = getenv('LIBGIT2')
include_dirs = [] if not libgit2_path:
library_dirs = [] libgit2_path = '/usr/local'
if libgit2_path:
include_dirs = [path.join(libgit2_path, 'include')] include_dirs = [path.join(libgit2_path, 'include')]
library_dirs = [path.join(libgit2_path, 'lib')] library_dirs = [path.join(libgit2_path, 'lib')]