Commit 0db4dcec authored by Howard Chu's avatar Howard Chu
Browse files

Specifies the symbols that slapd must export, for Mingw32 support

See README 1.27 log
parent dd89498e
......@@ -5,6 +5,10 @@
PROGRAMS=slapd
XPROGRAMS=sslapd libbackends.a .backend
XSRCS=version.c
NT_SRCS = nt_svc.c
NT_OBJS = nt_svc.o ../../libraries/liblutil/slapdmsg.res
SRCS = main.c daemon.c connection.c search.c filter.c add.c charray.c \
attr.c entry.c config.c backend.c result.c operation.c \
dn.c compare.c modify.c delete.c modrdn.c ch_malloc.c \
......@@ -12,7 +16,8 @@ SRCS = main.c daemon.c connection.c search.c filter.c add.c charray.c \
phonetic.c acl.c str2filter.c aclparse.c init.c user.c \
repl.c lock.c controls.c extended.c \
schema.c schemaparse.c monitor.c configinfo.c \
root_dse.c sasl.c module.c suffixalias.c
root_dse.c sasl.c module.c suffixalias.c $(@PLAT@_SRCS)
OBJS = main.o daemon.o connection.o search.o filter.o add.o charray.o \
attr.o entry.o config.o backend.o result.o operation.o \
dn.o compare.o modify.o delete.o modrdn.o ch_malloc.o \
......@@ -20,7 +25,7 @@ OBJS = main.o daemon.o connection.o search.o filter.o add.o charray.o \
phonetic.o acl.o str2filter.o aclparse.o init.o user.o \
repl.o lock.o controls.o extended.o \
schema.o schemaparse.o monitor.o configinfo.o \
root_dse.o sasl.o module.o suffixalias.o
root_dse.o sasl.o module.o suffixalias.o $(@PLAT@_OBJS)
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
......@@ -31,7 +36,7 @@ XDEFS = $(MODULES_CPPFLAGS)
XLDFLAGS = $(MODULES_LDFLAGS) $(SLAPD_MODULES)
# $(LTHREAD_LIBS) must be last
XLIBS = libbackends.a -lavl -lldbm -lldif -lldap_r -llber -llutil
XLIBS = libbackends.a -lavl -lldbm -lldif -llutil -lldap_r -llber
XXLIBS = $(LDBM_LIBS) $(SLAPD_LIBS) \
$(SLAPD_PERL_LDFLAGS) $(SECURITY_LIBS) \
$(LDIF_LIBS) $(LUTIL_LIBS)
......@@ -42,8 +47,41 @@ BUILD_SRV = @BUILD_SLAPD@
all-local-srv: all-cffiles
slapd: libbackends.a version.o
$(LTLINK) -o $@ $(OBJS) version.o $(LIBS) $(WRAP_LIBS)
NT_GEN_DEFS = -DLIBLUTIL_DECL=dllexport -DLIBAVL_DECL=dllexport \
-DLIBLDBM_DECL=dllexport -DLIBLDIF_DECL=dllexport
NT_DYN_DEFS = -DLIBLBER_DECL=dllimport -DLIBLDAP_DECL=dllimport $(NT_GEN_DEFS)
NT_STAT_DEFS = -DLIBLBER_DECL=dllexport -DLIBLDAP_DECL=dllexport $(NT_GEN_DEFS)
DEFINES = $(@PLAT@_@LIB_LINKAGE@_DEFS)
slapd.def: slapd.syms
( \
echo EXPORTS > $@; \
_hint=1; \
for symbol in `cat $<`; do \
echo " $$symbol @ $$_hint ; " >> $@; \
_hint=`expr 1 + $$_hint`; \
done \
)
slapd.base: version.o
$(LTLINK) -o slapd $(OBJS) version.o $(LIBS) $(WRAP_LIBS) \
-Wl,--base-file,$@
rm -f slapd
slapd.exp: slapd.def slapd.base
dlltool --dllname slapd.exe --def slapd.def --base-file slapd.base \
--output-exp $@
libslapd.a: slapd.def
dlltool --dllname slapd.exe --def $< --output-lib $@
NT_EXP = slapd.exp
NT_IMP_LIB = libslapd.a
slapd: $(@PLAT@_IMP_LIB) libbackends.a version.o $(@PLAT@_EXP)
$(LTLINK) -o $@ $(OBJS) version.o $(LIBS) $(WRAP_LIBS) $(@PLAT@_EXP)
(cd tools; $(MAKE) $(MFLAGS) all)
sslapd: version.o
......@@ -92,6 +130,10 @@ depend-local-srv: FORCE
( cd $$i; $(MAKE) $(MFLAGS) depend ); \
fi; \
done
@echo ""
clean-local:
rm -f *.exp *.def *.base *.a
clean-local-srv: FORCE
@for i in back-* shell-backends tools; do \
......@@ -115,7 +157,8 @@ install-local-srv: install-slapd install-conf install-tools
install-slapd: FORCE
-$(MKDIR) $(DESTDIR)$(libexecdir)
-$(MKDIR) $(DESTDIR)$(localstatedir)
$(LTINSTALL) $(INSTALLFLAGS) -m 755 slapd $(DESTDIR)$(libexecdir)
$(LTINSTALL) $(INSTALLFLAGS) -m 755 slapd$(EXEEXT) \
$(DESTDIR)$(libexecdir)
@if [ ! -z "$(SLAPD_MODULES)" ]; then \
for i in back-* shell-backends tools; do \
if [ -d $$i ]; then \
......
......@@ -16,6 +16,17 @@ BUILD_OPT = "--enable-ldbm"
BUILD_MOD = @BUILD_LDBM@
LINKAGE = @BUILD_LDBM_DYNAMIC@
DYN_DEFS = -DLIBLBER_DECL=dllimport -DLIBLDAP_DECL=dllimport
# TODO
#NT_mod_DYN_MODDEFS =
#NT_mod_STAT_MODDEFS =
NT_yes_DYN_MODDEFS = $(DYN_DEFS)
NT_yes_STAT_MODDEFS =
MODDEFS = $(@PLAT@_@BUILD_LDBM@_@LIB_LINKAGE@_MODDEFS)
LIBBASE = back_ldbm
XINCPATH = -I.. -I$(srcdir)/..
......
access2str
access_allowed
acl_access_allowed
acl_check_modlist
acl_get_applicable
active_threads
active_threads_cond
active_threads_mutex
add_values
attrs_dup
attrs_free
attr_delete
attr_dup
attr_find
attr_free
attr_index_config
attr_index_destroy
attr_masks
attr_merge
attr_merge_fast
attr_normalize
attr_syntax
attr_syntax_config
at_add
at_append_to_list
at_canonical_name
at_delete_from_list
at_fake_if_needed
at_find
at_find_in_list
at_schema_info
ava_free
backendDB
backendInfo
backend_add
backend_connection_destroy
backend_connection_init
backend_db_init
backend_destroy
backend_group
backend_info
backend_init
backend_num
backend_shutdown
backend_startup
backend_subschemasubentry
backend_unbind
ber_bvfree
ber_free
be_db_close
be_entry_release_rw
be_isroot
be_isroot_pw
be_issuffix
be_root_dn
bind_addr
build_new_dn
cache_add_entry_rw
cache_delete_entry
cache_find_entry_dn2id
cache_find_entry_id
cache_release_all
cache_return_entry_rw
cache_update_entry
case_ignore_normalize
charray2str
charray_add
charray_dup
charray_free
charray_inlist
charray_merge
ch_calloc
ch_free
ch_malloc
ch_realloc
ch_strdup
config_info
connections_destroy
connections_init
connections_nextid
connections_shutdown
connections_timeout_idle
connection_closing
connection_done
connection_first
connection_init
connection_next
connection_read
connection_state2str
connection_state_closing
connection_write
default_referral
defsize
deftime
delete_values
deref_internal_r
dn2entry_rw
dn2id
dn2idl
dn2id_add
dn2id_delete
dn_issuffix
dn_normalize
dn_parent
dn_rdn
dn_subtree
dn_validate
do_abandon
do_add
do_bind
do_compare
do_delete
do_extended
do_modify
do_modrdn
do_search
do_unbind
dscompare
dtblsize
entry2str
entry2str_mutex
entry_cmp
entry_destroy
entry_dn_cmp
entry_free
entry_id_cmp
filter_candidates
filter_free
filter_print
first_word
get_ava
get_ctrls
get_entry_referrals
get_filter
get_manageDSAit
global_acl
global_default_access
global_idletimeout
global_lastmod
global_readonly
global_realm
global_schemacheck
gmtime_mutex
g_argc
g_argv
has_children
id2entry_add
id2entry_delete
id2entry_rw
idl_allids
idl_alloc
idl_delete_key
idl_fetch
idl_firstid
idl_free
idl_insert
idl_insert_key
idl_intersection
idl_nextid
idl_notin
idl_union
index_add_entry
index_add_mods
index_change_values
index_read
is_entry_objectclass
ldap_add_s
ldap_bind_s
ldap_delete_s
ldap_first_attribute
ldap_first_entry
ldap_get_dn
ldap_get_option
ldap_get_values_len
ldap_init
ldap_modify_s
ldap_modrdn_s
ldap_msgfree
ldap_next_attribute
ldap_pvt_str2upper
ldap_pvt_thread_mutex_lock
ldap_pvt_thread_mutex_unlock
ldap_result
ldap_search
ldap_srvtab
ldap_syslog
ldap_syslog_level
ldap_unbind
ldbm_back_abandon
ldbm_back_add
ldbm_back_bind
ldbm_back_close
ldbm_back_compare
ldbm_back_db_close
ldbm_back_db_config
ldbm_back_db_destroy
ldbm_back_db_init
ldbm_back_db_open
ldbm_back_delete
ldbm_back_destroy
ldbm_back_entry_release_rw
ldbm_back_group
ldbm_back_initialize
ldbm_back_modify
ldbm_back_modrdn
ldbm_back_open
ldbm_back_search
ldbm_back_unbind
ldbm_cache_close
ldbm_cache_delete
ldbm_cache_fetch
ldbm_cache_flush_all
ldbm_cache_open
ldbm_cache_really_close
ldbm_cache_store
ldbm_close
ldbm_datum_free
ldbm_delete
ldbm_fetch
ldbm_firstkey
ldbm_initialize
ldbm_modify_internal
ldbm_nextkey
ldbm_open
ldbm_store
ldbm_sync
ldbm_tool_entry_close
ldbm_tool_entry_first
ldbm_tool_entry_get
ldbm_tool_entry_next
ldbm_tool_entry_open
ldbm_tool_entry_put
ldbm_tool_index_attr
ldbm_tool_index_change
ldbm_tool_sync
lock_fclose
lock_fopen
lutil_debug
main
module_load
module_path
monitor_info
mrule_defs
mr_add
mr_find
nBackendDB
nBackendInfo
next_id
next_id_get
next_id_write
next_word
num_bytes_sent
num_conns
num_entries_sent
num_ops_completed
num_ops_initiated
num_ops_mutex
num_pdu_sent
num_refs_sent
num_sent_mutex
oc_add
oc_check_no_usermod_attr
oc_check_operational_attr
oc_check_usermod_attr
oc_find
oc_schema_check
parse_acl
parse_at
parse_oc
parse_oc_old
parse_oidm
phonetic
rdn_attr_type
rdn_attr_value
rdn_validate
read_config
register_matching_rule
register_syntax
replace_values
replog
replogfile
replog_mutex
root_dse_info
sasl_destroy
sasl_init
schema_info
schema_init
scherr2str
select_backend
send_ldap_disconnect
send_ldap_result
send_search_entry
send_search_reference
send_search_result
slapd_args_file
slapd_clr_read
slapd_clr_write
slapd_daemon
slapd_daemon_destroy
slapd_daemon_init
slapd_pid_file
slapd_remove
slapd_set_read
slapd_set_write
slapd_shutdown
slapMode
slap_debug
slap_destroy
slap_get_time
slap_init
slap_listeners
slap_op_add
slap_op_alloc
slap_op_free
slap_op_pop
slap_op_remove
slap_shutdown
slap_sig_shutdown
slap_sig_wake
slap_startup
started_event
starttime
start_status_tid
stopped_event
stop_status_tid
str2access
str2charray
str2entry
str2filter
str2result
suffix_alias
supportedControls
supportedExtensions
supportedSASLMechanisms
syntax_defs
syn_add
syn_find
syn_find_desc
test_filter
value_add
value_add_fast
value_cmp
value_find
value_normalize
Versionstr
word_dup
......@@ -25,7 +25,7 @@ SLAPD_MODULES = @SLAPD_MODULES_LIST@
XDEFS = $(MODULES_CPPFLAGS)
XLDFLAGS = $(MODULES_LDFLAGS) $(SLAPD_MODULES)
XLIBS = -lavl -lldif -lldbm -lldap_r -llber -llutil
XLIBS = -lavl -lldif -lldbm -llutil -lldap_r -llber
XXLIBS = $(LDAPD_LIBS) $(SLAPD_LIBS) \
$(PERL_LDFLAGS) $(LDBM_LIBS) $(SECURITY_LIBS) \
$(LDIF_LIBS) $(LUTIL_LIBS)
......@@ -36,6 +36,10 @@ LDBMPROGRAMS=centipede sizecount
BDB2PROGRAMS=
QUIPUPROGRAMS=chlog2replog edb2ldif
# CPPFLAGS will include the defines for dynamic libs in Mingw32.
NT_DYN_DEFS = -DLIBLBER_DECL=dllimport -DLIBLDAP_DECL=dllimport
CPPFLAGS = $(@PLAT@_@LIB_LINKAGE@_DEFS)
SRCS = ldif.c mimic.c slapcommon.c
XSRCS = edb2-vers.c
......@@ -55,7 +59,9 @@ SLAPOBJS = $(SLAPD_OBJS) slapcommon.o mimic.o
EDB2LDIFSRCS = edb2ldif.c ldapsyntax.c
EDB2LDIFOBJS = edb2ldif.o ldapsyntax.o
all-local: build-progs build-ldbm build-bdb2 build-quipu
UNIX_PRGS = build-ldbm build-bdb2 build-quipu
all-local: build-progs $(@PLAT@_PRGS)
build-progs: $(PROGRAMS)
......@@ -120,10 +126,10 @@ chlog2replog: chlog2replog.o ../lock.o ../ch_malloc.o $(SLAPD_LIBDEPEND)
clean-local: FORCE
$(RM) $(PROGRAMS) $(LDBMPROGRAMS) $(BDB2PROGRAMS) $(QUIPUPROGRAMS) \
$(XPROGRAMS) $(XSRCS) *.o core .libs/*
$(XPROGRAMS) $(XSRCS) *.o core .libs/* *.exe
depend-local: FORCE
@DEPEND_LDBM= ; DEPEND_BDB2= ; DEPEND_QUIPU= ; \
DEPEND_LDBM= ; DEPEND_BDB2= ; DEPEND_QUIPU= ; \
if [ "$(BUILD_LDBM)" != "no" ]; then \
DEPEND_LDBM="$(LDBMSRCS)"; \
fi; \
......@@ -143,8 +149,9 @@ install-ldbm-no install-bdb2-no install-quipu-no:
install-ldbm-yes install-ldbm-mod: FORCE
-$(MKDIR) $(DESTDIR)$(sbindir)
for bin in slapadd slapcat slapindex centipede ldif; do \
$(LTINSTALL) $(INSTALLFLAGS) -m 755 $$bin $(DESTDIR)$(sbindir); \
@for bin in $(PROGRAMS); do \
$(LTINSTALL) $(INSTALLFLAGS) -m 755 $$bin$(EXEEXT) \
$(DESTDIR)$(sbindir); \
done
install-bdb2-yes install-bdb2-mod: FORCE
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment