diff options
author | Andrew Bartlett <abartlet@samba.org> | 2008-01-11 09:25:14 +1100 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2008-01-11 09:25:14 +1100 |
commit | 80902a2a2b14bc27af0f195d18c40ccef9cb780c (patch) | |
tree | 792ae2b86096db9026933c7fe22c57ff7a401bf4 /source4/lib/ldb | |
parent | 7054ce65485482d1cc5fa4ff83272feb752e71c2 (diff) | |
parent | 84c9b6235ed52770eb6dfae8b75c346d435cb260 (diff) | |
download | samba-80902a2a2b14bc27af0f195d18c40ccef9cb780c.tar.gz samba-80902a2a2b14bc27af0f195d18c40ccef9cb780c.tar.bz2 samba-80902a2a2b14bc27af0f195d18c40ccef9cb780c.zip |
Merge commit 'origin/v4-0-test' into 4-0-local
(This used to be commit 4720f53a92644dd6959e18923924fbe01889111c)
Diffstat (limited to 'source4/lib/ldb')
-rw-r--r-- | source4/lib/ldb/Makefile.in | 28 | ||||
-rw-r--r-- | source4/lib/ldb/configure.ac | 13 |
2 files changed, 34 insertions, 7 deletions
diff --git a/source4/lib/ldb/Makefile.in b/source4/lib/ldb/Makefile.in index 4788c02598..8be5d11958 100644 --- a/source4/lib/ldb/Makefile.in +++ b/source4/lib/ldb/Makefile.in @@ -112,7 +112,8 @@ lib/libldb.$(SHLIBEXT): $(SOLIB) $(SOLIB): $(OBJS) $(SHLD) $(SHLD_FLAGS) -o $@ $(OBJS) $(LDFLAGS) $(LIBS) $(TALLOC_LIBS) $(TDB_LIBS) $(LIBDL) $(LDAP_LIBS) @SONAMEFLAG@$(SONAME) -all: showflags dirs $(OBJS) $(STATICLIB) $(SOLIB) $(BINS) $(EXAMPLES) manpages +all: showflags dirs $(OBJS) $(STATICLIB) $(SOLIB) $(BINS) $(EXAMPLES) manpages \ + @PYTHON_BUILD_TARGET@ showflags: @echo 'ldb will be compiled with flags:' @@ -212,12 +213,23 @@ valgrindtest: all installcheck: install test -install:: all +install:: all installdirs installheaders installlibs installbin installdoc \ + @PYTHON_INSTALL_TARGET@ + +installdirs: mkdir -p $(DESTDIR)$(includedir) $(DESTDIR)$(libdir) $(DESTDIR)$(bindir) $(DESTDIR)$(libdir)/pkgconfig + +installheaders: installdirs cp $(headers) $(DESTDIR)$(includedir) + +installlibs: installdirs cp $(STATICLIB) $(SOLIB) $(DESTDIR)$(libdir) - cp $(BINS) $(DESTDIR)$(bindir) cp ldb.pc $(DESTDIR)$(libdir)/pkgconfig + +installbin: installdirs + cp $(BINS) $(DESTDIR)$(bindir) + +installdocs: installdirs $(srcdir)/docs/installdocs.sh $(DESTDIR)$(mandir) gcov: @@ -234,15 +246,17 @@ etags: ctags: ctags `find $(srcdir) -name "*.[ch]"` -%_wrap.c %.py: %.i - $(SWIG) -O -Wall -python -keyword $< +.SUFFIXES: _wrap.c .i + +.i_wrap.c: + [ "$(SWIG)" == "no" ] || $(SWIG) -O -Wall -python -keyword $< # Python bindings -build-python: lib/libldb.$(SHLIBEXT) ldb_wrap.c ldb.py +build-python: lib/libldb.$(SHLIBEXT) ldb_wrap.c ./setup.py build install-python: build-python - ./setup.py install --prefix=$(prefix) + ./setup.py install --prefix=$(DESTDIR)$(prefix) install-swig: cp ldb.i `$(SWIG) -swiglib` diff --git a/source4/lib/ldb/configure.ac b/source4/lib/ldb/configure.ac index 73966e8f93..62a840e561 100644 --- a/source4/lib/ldb/configure.ac +++ b/source4/lib/ldb/configure.ac @@ -75,6 +75,19 @@ AC_LIBREPLACE_SHLD AC_LIBREPLACE_SHLD_FLAGS AC_LIBREPLACE_MDLD AC_LIBREPLACE_MDLD_FLAGS +AC_LIBREPLACE_RUNTIME_LIB_PATH_VAR + +AC_PATH_PROGS([PYTHON_CONFIG], [python2.6-config python2.5-config python2.4-config python-config]) + +PYTHON_BUILD_TARGET="build-python" +PYTHON_INSTALL_TARGET="install-python" +AC_SUBST(PYTHON_BUILD_TARGET) +AC_SUBST(PYTHON_INSTALL_TARGET) + +if test -z "$PYTHON_CONFIG"; then + PYTHON_BUILD_TARGET="" + PYTHON_INSTALL_TARGET="" +fi m4_include(libldb.m4) AC_OUTPUT(Makefile ldb.pc) |