mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-02-23 14:09:39 +08:00
Define library version/release in version.var to avoid regenerating
Makefile.in with every release. (works similar to OpenLDAP's main version.sh/version.var)
This commit is contained in:
parent
2bc9106fe1
commit
1d82d1d86a
@ -5,6 +5,5 @@
|
||||
# COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
||||
##
|
||||
|
||||
EXTRA_DIST = BUGS
|
||||
SUBDIRS = src examples
|
||||
|
||||
|
@ -13,6 +13,15 @@ AC_CONFIG_SRCDIR(src/LDAPConnection.h)
|
||||
AM_INIT_AUTOMAKE(foreign)
|
||||
AM_CONFIG_HEADER(src/config.h)
|
||||
|
||||
eval `$ac_aux_dir/version.sh`
|
||||
if test -z "$OL_CPP_API_RELEASE"; then
|
||||
AC_MSG_ERROR([could not determine version])
|
||||
fi
|
||||
|
||||
VERSION=$OL_CPP_API_RELEASE
|
||||
OPENLDAP_CPP_API_VERSION=$OL_CPP_API_VERSION
|
||||
AC_SUBST(VERSION)
|
||||
AC_SUBST(OPENLDAP_CPP_API_VERSION)
|
||||
dnl Checks for programs.
|
||||
AC_PROG_INSTALL
|
||||
dnl AC_PROG_CC
|
||||
@ -24,9 +33,7 @@ dnl AC_PROG_MAKE_SET
|
||||
AC_ARG_ENABLE(debug,[ --enable-debug],[
|
||||
CXXFLAGS="-g -O0 -Wall"
|
||||
AC_DEFINE(WITH_DEBUG,[],[Define to 1 ot enable debug logging])
|
||||
],[
|
||||
CXXFLAGS="-O0"
|
||||
]
|
||||
],
|
||||
)
|
||||
|
||||
AC_ARG_WITH(libldap,[ --with-libldap=DIR Path to the libldap library [/usr/local/lib]],[
|
||||
|
@ -1,7 +1,7 @@
|
||||
# $OpenLDAP$
|
||||
|
||||
###
|
||||
# Copyright 2000, OpenLDAP Foundation, All Rights Reserved.
|
||||
# Copyright 2000-2008, OpenLDAP Foundation, All Rights Reserved.
|
||||
# COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
||||
##
|
||||
|
||||
@ -95,5 +95,5 @@ noinst_HEADERS = LDAPAddRequest.h \
|
||||
LDAPSearchRequest.h
|
||||
|
||||
libldapcpp_la_LIBADD = -lldap -llber
|
||||
libldapcpp_la_LDFLAGS = -version-info 0:5:0
|
||||
libldapcpp_la_LDFLAGS = -version-info @OPENLDAP_CPP_API_VERSION@
|
||||
|
||||
|
10
contrib/ldapc++/version.sh
Executable file
10
contrib/ldapc++/version.sh
Executable file
@ -0,0 +1,10 @@
|
||||
#! /bin/sh
|
||||
# $OpenLDAP$
|
||||
#
|
||||
# Copyright 2008, OpenLDAP Foundation, All Rights Reserved.
|
||||
# COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
||||
DIR=`dirname $0`
|
||||
. $DIR/version.var
|
||||
|
||||
echo OL_CPP_API_VERSION=$ol_cpp_api_current:$ol_cpp_api_revision:$ol_cpp_api_age
|
||||
echo OL_CPP_API_RELEASE=$ol_cpp_api_rel_major.$ol_cpp_api_rel_minor.$ol_cpp_api_rel_patch
|
13
contrib/ldapc++/version.var
Normal file
13
contrib/ldapc++/version.var
Normal file
@ -0,0 +1,13 @@
|
||||
#! /bin/sh
|
||||
# $OpenLDAP$
|
||||
#
|
||||
# Copyright 2008, OpenLDAP Foundation, All Rights Reserved.
|
||||
# COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
||||
|
||||
ol_cpp_api_rel_major=0
|
||||
ol_cpp_api_rel_minor=0
|
||||
ol_cpp_api_rel_patch=0
|
||||
|
||||
ol_cpp_api_current=0
|
||||
ol_cpp_api_revision=0
|
||||
ol_cpp_api_age=0
|
Loading…
Reference in New Issue
Block a user