11e9368a226272085c337e9e74b79808c16fbdbaTinderbox User# CDDL HEADER START
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# The contents of this file are subject to the terms of the
4a14ce5ba00ab7bc55c99ffdcf59c7a4ab902721Automatic Updater# Common Development and Distribution License, Version 1.0 only
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# (the "License"). You may not use this file except in compliance
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# with the License.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# You can obtain a copy of the license at
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# trunk/opends/resource/legal-notices/OpenDS.LICENSE
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# See the License for the specific language governing permissions
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# and limitations under the License.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# When distributing Covered Code, include this CDDL HEADER in each
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# file and include the License file at
ea94d370123a5892f6c47a97f21d1b28d44bb168Tinderbox User# trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# add the following below this CDDL HEADER, with the fields enclosed
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# by brackets "[]" replaced with your own identifying information:
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Portions Copyright [yyyy] [name of copyright owner]
e21a2904f02a03fa06b6db04d348f65fe9c67b2bMark Andrews# CDDL HEADER END
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Copyright 2008 Sun Microsystems, Inc.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Portions Copyright 2011 ForgeRock AS
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# This is the Makefile than can be used to generate the executables
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# winlauncher.exe and opendj_service.exe that are used by OpenDS in
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# The compilation of winlauncher.exe is straightforward but in the case of
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# opendj_service.exe uses a Message File called EventLogMsg.mc which
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# makes the compilation a little bit more complex.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# During compilation the first step is to generate EventLogMsg.h and
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# EventLogMsg.res using the rc.exe and mc.exe utilities.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# EventLogMsg.h contains some references to the message IDs that are sent to
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# the Windows Event Log and is required in order service.c to be compiled.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Once the EvenLogMsg.h file is generated we can compile the service.c and
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# common.c and finally we link the service.obj, common.obj and
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# EventLogMsg.res files and we generate the opendj_service.exe executable.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinLAUNCHER_ADMINISTRATOR_PROGNAME=launcher_administrator.exe
d9184858dd5d7677050a813d444c281c56f697aaTinderbox UserSERVICE_MANIFEST_FILE = opendj_service.exe.manifest
5d564da348e890e42f63eebf2dced9a05b41f4fbTinderbox UserLAUNCHER_ADMINISTRATOR_MANIFEST_FILE = launcher_administrator.exe.manifest
a1ad6695ed6f988406cf155aa26376f84f73bcb9Automatic Updaterall: $(SERVICE_PROGNAME) $(WINLAUNCHER_PROGNAME) $(LAUNCHER_ADMINISTRATOR_PROGNAME)
5d564da348e890e42f63eebf2dced9a05b41f4fbTinderbox User$(SERVICE_PROGNAME) : $(RES_FILE) $(SERVICE_OBJS)
2895f101b5585a19015ac2c2c1e1812ac467fa12Automatic Updater $(LINKER) /OUT:$(SERVICE_PROGNAME) $(RES_FILE) $(SERVICE_OBJS) $(LIBS)
bd84b04e4fda4f41923bba6e7277546d87045b5aTinderbox User $(MT) -manifest "$(SERVICE_MANIFEST_FILE)" -outputresource:"$(SERVICE_PROGNAME)";#1
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein $(LINKER) $(WINLAUNCHER_OBJS) /OUT:$(WINLAUNCHER_PROGNAME)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein$(LAUNCHER_ADMINISTRATOR_PROGNAME) : $(WINLAUNCHER_OBJS)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein $(LINKER) $(WINLAUNCHER_OBJS) /OUT:$(LAUNCHER_ADMINISTRATOR_PROGNAME)
bd84b04e4fda4f41923bba6e7277546d87045b5aTinderbox User $(MT) -manifest "$(LAUNCHER_ADMINISTRATOR_MANIFEST_FILE)" -outputresource:"$(LAUNCHER_ADMINISTRATOR_PROGNAME)";#1