Commit e6c8966d37833f6cd6329afa2c71e8c167cfc248

Vicent Marti 2010-12-23T00:49:34

Merge branch 'call-ldconfig-on-unix' of https://github.com/marvil07/libgit2

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
diff --git a/wscript b/wscript
index 0307df5..b028568 100644
--- a/wscript
+++ b/wscript
@@ -137,6 +137,13 @@ def build_library(bld, build_type):
     bld.install_files('${PREFIX}/include', directory.find_node('src/git2.h'))
     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']:
+        bld.add_post_fun(call_ldconfig)
+
+def call_ldconfig(bld):
+    bld.exec_command('/sbin/ldconfig')
+
 def grep_test_header(text, test_file):
     return '\n'.join(l for l in test_file.read().splitlines() if text in l)