Netscape DIRECTORY SERVER 6.2 - PLUG-IN Manual page 37

Table of Contents

Advertisement

If you want, you can compile all plug-in functions in a single library. Although
you can include different types of plug-in functions in the same library, you
need to write separate initialization functions for each type of plug-in function.
Refer to the chapter "Configuring Plug-Ins" on page 39 for details on how to
specify each initialization function in a directive for a specific type of plug-in.
The following code shows a sample Makefile for Solaris. The example assumes that
the source files are located in the following directory:
<server_root>/plugins/slapd/slapi/examples
The server plug-in API header files are located in the relative path
Code Example 2-5
# SOLARIS Makefile for Directory Server plug-in examples
#
CC = cc
LD = ld
INCLUDE_FLAGS = -I../include
CFLAGS = $(INCLUDE_FLAGS) -D_REENTRANT -KPIC
LDFLAGS = -G
OBJS = testsaslbind.o testextendedop.o testpreop.o testpostop.o
testentry.o
all: libtest-plugin.so
libtest-plugin.so: $(OBJS)
$(LD) $(LDFLAGS) -o $@ $(OBJS)
.c.o:
$(CC) $(CFLAGS) -c $<
clean:
-rm -f $(OBJS) libtest-plugin.so
Example Solaris Makefile
Compiling a Directory Server Plug-In
../include
Chapter 2
Writing and Compiling Plug-Ins
.
37

Advertisement

Table of Contents
loading

This manual is also suitable for:

Directory server 6.2

Table of Contents