Split up ldap build options into two sections: ldap and ldap_experimental, in preparation for turning on just the ldap module in the default builds. Also fixes LDAP C SDK bustage introduced by change to --enable-nspr-autoconf. Bug 70658. Patch from leif@netscape.com, r=dmose@netscape.com, sr=alecf@netscape.com.

This commit is contained in:
dmose%netscape.com 2001-03-14 06:41:35 +00:00
Родитель eceaf72715
Коммит 42c00de566
9 изменённых файлов: 77 добавлений и 47 удалений

Просмотреть файл

@ -79,6 +79,7 @@ IBMBIDI = @IBMBIDI@
BUILD_IDLC = @BUILD_IDLC@
MOZ_ENDER_LITE = @MOZ_ENDER_LITE@
MOZ_LDAP_XPCOM = @MOZ_LDAP_XPCOM@
MOZ_LDAP_XPCOM_EXPERIMENTAL = @MOZ_LDAP_XPCOM_EXPERIMENTAL@
XPCOM_USE_LEA = @XPCOM_USE_LEA@
MOZ_COMPONENTS_VERSION_SCRIPT_LDFLAGS = @MOZ_COMPONENTS_VERSION_SCRIPT_LDFLAGS@

Просмотреть файл

@ -3759,6 +3759,15 @@ MOZ_ARG_ENABLE_BOOL(ldap,
MOZ_LDAP_XPCOM=1
)
dnl --enable-ldap-experimental
dnl
MOZ_ARG_ENABLE_BOOL(ldap-experimental,
[ --enable-ldap-experimental
Enable LDAP experimental features (default=no)],
MOZ_LDAP_XPCOM_EXPERIMENTAL=1
)
dnl --disable-xul
dnl
MOZ_XUL=1
@ -3961,6 +3970,7 @@ AC_SUBST(MOZ_INSURE_EXCLUDE_DIRS)
AC_SUBST(MOZ_INSURIFYING)
AC_SUBST(MOZ_BUILD_XPFE)
AC_SUBST(MOZ_LDAP_XPCOM)
AC_SUBST(MOZ_LDAP_XPCOM_EXPERIMENTAL)
AC_SUBST(XPCOM_USE_LEA)
AC_SUBST(UNIX_CRASH_ON_ASSERT)

Просмотреть файл

@ -38,15 +38,22 @@ VPATH = @srcdir@
include $(DEPTH)/config/autoconf.mk
# Note that for the time being "tests" require LDAP Experimental
#
DIRS = \
base \
$(NULL)
ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
DIRS += \
datasource \
$(NULL)
# uncomment this once test dir is created and populated
#
# ifdef ENABLE_TESTS
DIRS += tests
# endif
ifdef ENABLE_TESTS
DIRS += \
tests
endif
endif
include $(topsrcdir)/config/rules.mk

Просмотреть файл

@ -41,7 +41,8 @@ include $(DEPTH)/config/autoconf.mk
MODULE = mozldap
XPIDL_MODULE = mozldap
XPIDLSRCS = nsILDAPConnection.idl \
XPIDLSRCS = \
nsILDAPConnection.idl \
nsILDAPOperation.idl \
nsILDAPMessage.idl \
nsILDAPMessageListener.idl \
@ -49,6 +50,10 @@ XPIDLSRCS = nsILDAPConnection.idl \
nsILDAPErrors.idl \
$(NULL)
ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
XPIDLSRCS += \
$(NULL)
endif
EXPORTS = \
nsLDAP.h \
$(NULL)

Просмотреть файл

@ -31,6 +31,8 @@ XPIDLSRCS= .\nsILDAPConnection.idl \
.\nsILDAPURL.idl \
.\nsILDAPMessageListener.idl \
.\nsILDAPErrors.idl \
!if defined(ENABLE_LDAP_EXPERIMENTAL)
!endif
$(NULL)
include <$(DEPTH)\config\rules.mak>
include <$(DEPTH)\config\rules.mak>

Просмотреть файл

@ -46,16 +46,24 @@ REQUIRES = xpcom string necko mime
CPPSRCS = \
nsLDAPService.cpp \
nsLDAPProtocolHandler.cpp \
nsLDAPProtocolModule.cpp \
nsLDAPChannel.cpp \
nsLDAPMessage.cpp \
nsLDAPConnection.cpp \
nsLDAPOperation.cpp \
nsLDAPURL.cpp \
$(NULL)
ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
DEFINES += -DMOZ_LDAP_XPCOM_EXPERIMENTAL
CPPSRCS += \
nsLDAPProtocolHandler.cpp \
nsLDAPChannel.cpp \
nsLDAPService.cpp \
$(NULL)
endif
CSRCS = \
nsLDAPConnectionCallbacks.c \
$(NULL)

Просмотреть файл

@ -28,16 +28,26 @@ LLIBS = $(LIBNSPR) \
$(DIST)\lib\nsldap32v40.lib \
$(NULL)
CPP_OBJS = .\$(OBJDIR)\nsLDAPService.obj \
.\$(OBJDIR)\nsLDAPProtocolHandler.obj \
CPP_OBJS = .\$(OBJDIR)\nsLDAPURL.obj \
.\$(OBJDIR)\nsLDAPProtocolModule.obj \
.\$(OBJDIR)\nsLDAPChannel.obj \
.\$(OBJDIR)\nsLDAPURL.obj \
.\$(OBJDIR)\nsLDAPMessage.obj \
.\$(OBJDIR)\nsLDAPConnection.obj \
.\$(OBJDIR)\nsLDAPConnection.obj \
.\$(OBJDIR)\nsLDAPOperation.obj \
!if defined(ENABLE_LDAP_EXPERIMENTAL)
.\$(OBJDIR)\nsLDAPProtocolHandler.obj \
.\$(OBJDIR)\nsLDAPChannel.obj \
.\$(OBJDIR)\nsLDAPService.obj \
!endif
$(NULL)
!if defined(ENABLE_LDAP_EXPERIMENTAL)
DEFINES = -DMOZ_LDAP_XPCOM_EXPERIMENTAL $(DEFINES)
LCFLAGS = \
$(LCFLAGS) \
$(DEFINES) \
$(NULL)
!endif
C_OBJS = .\$(OBJDIR)\nsLDAPConnectionCallbacks.obj \
$(NULL)

Просмотреть файл

@ -34,31 +34,33 @@
#include "nsLDAPURL.h"
#include "nsIGenericFactory.h"
#include "nsLDAPProtocolHandler.h"
#include "nsLDAPChannel.h"
#include "nsLDAPService.h"
#include "nsLDAPConnection.h"
#include "nsLDAPOperation.h"
#include "nsLDAPMessage.h"
#ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
#include "nsLDAPProtocolHandler.h"
#include "nsLDAPChannel.h"
#include "nsLDAPService.h"
#endif
// use the default constructor
//
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPProtocolHandler);
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsLDAPService, Init);
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPConnection);
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPOperation);
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPMessage);
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPURL);
#ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
NS_GENERIC_FACTORY_CONSTRUCTOR(nsLDAPProtocolHandler);
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsLDAPService, Init);
#endif
// a table of the CIDs implemented by this module (in this case, just one)
//
static nsModuleComponentInfo components[] =
{
{ "LDAP Protocol Handler", NS_LDAPPROTOCOLHANDLER_CID,
NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "ldap",
nsLDAPProtocolHandlerConstructor },
{ "LDAP Service", NS_LDAPSERVICE_CID,
"@mozilla.org/network/ldap-service;1", nsLDAPServiceConstructor },
{ "LDAP Connection", NS_LDAPCONNECTION_CID,
"@mozilla.org/network/ldap-connection;1",
nsLDAPConnectionConstructor },
@ -67,6 +69,13 @@ static nsModuleComponentInfo components[] =
nsLDAPOperationConstructor },
{ "LDAP Message", NS_LDAPMESSAGE_CID,
"@mozilla.org/network/ldap-message;1", nsLDAPMessageConstructor },
#ifdef MOZ_LDAP_XPCOM_EXPERIMENTAL
{ "LDAP Protocol Handler", NS_LDAPPROTOCOLHANDLER_CID,
NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "ldap",
nsLDAPProtocolHandlerConstructor },
{ "LDAP Service", NS_LDAPSERVICE_CID,
"@mozilla.org/network/ldap-service;1", nsLDAPServiceConstructor },
#endif
{ "LDAP URL", NS_LDAPURL_CID,
"@mozilla.org/network/ldap-url;1", nsLDAPURLConstructor }
};

Просмотреть файл

@ -1,22 +0,0 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public License
# Version 1.0 (the "NPL"); you may not use this file except in
# compliance with the NPL. You may obtain a copy of the NPL at
# http://www.mozilla.org/NPL/
#
# Software distributed under the NPL is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
# for the specific language governing rights and limitations under the
# NPL.
#
# The Initial Developer of this code under the NPL is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All Rights
# Reserved.
DEPTH=..\..
DIRS=base
include <$(DEPTH)\config\rules.mak>