mirror of
https://git.proxmox.com/git/libgit2
synced 2025-08-02 22:54:15 +00:00
Find proper path to 'ldconfig' on wscript
Don't hardcode the '/sbin/ldconfig' path; also, don't run anything if ldconfig cannot be found (Mac OS X, for instance). Signed-off-by: Vicent Marti <tanoku@gmail.com>
This commit is contained in:
parent
e52ed7a559
commit
2645053be2
7
wscript
7
wscript
@ -138,11 +138,14 @@ def build_library(bld, build_type):
|
||||
bld.install_files('${PREFIX}/include/git2', directory.ant_glob('src/git2/*.h'))
|
||||
|
||||
# On Unix systems, let them know about installation
|
||||
if bld.env.PLATFORM == 'unix' and bld.cmd in ['install-static', 'install-shared']:
|
||||
if bld.env.PLATFORM == 'unix' and bld.cmd == 'install-shared':
|
||||
bld.add_post_fun(call_ldconfig)
|
||||
|
||||
def call_ldconfig(bld):
|
||||
bld.exec_command('/sbin/ldconfig')
|
||||
import distutils.spawn as s
|
||||
ldconf = s.find_executable('ldconfig')
|
||||
if ldconf:
|
||||
bld.exec_command(ldconf)
|
||||
|
||||
def grep_test_header(text, test_file):
|
||||
return '\n'.join(l for l in test_file.read().splitlines() if text in l)
|
||||
|
Loading…
Reference in New Issue
Block a user