1# Copyright (C) 2002 artofcode LLC. All rights reserved. 2# 3# This software is provided AS-IS with no warranty, either express or 4# implied. 5# 6# This software is distributed under license and may not be copied, 7# modified or distributed except as expressly authorized under the terms 8# of the license contained in the file LICENSE in this distribution. 9# 10# For more information about licensing, please refer to 11# http://www.ghostscript.com/licensing/. For information on 12# commercial licensing, go to http://www.artifex.com/licensing/ or 13# contact Artifex Software, Inc., 101 Lucas Valley Road #110, 14# San Rafael, CA 94903, U.S.A., +1(415)492-9861. 15 16# $Id: ijs.mak,v 1.6 2002/02/21 22:24:53 giles Exp $ 17# makefile for ijs client library code. 18# Users of this makefile must define the following: 19# IJSSRCDIR - the icclib source directory 20# IJSEXECTYPE - which process control code to use 21# in spawning the server. currently 22# 'unix' and 'win' are supported. 23# BINDIR - where to put the executible examples 24 25# This partial makefile compiles the IJS client library for use in 26# Ghostscript. 27 28IJSSRC=$(IJSSRCDIR)$(D) 29IJSGEN=$(IJSGENDIR)$(D) 30IJSOBJ=$(IJSOBJDIR)$(D) 31IJSO_=$(O_)$(IJSOBJ) 32 33# We need I_, _I_, and _I because the OpenVMS compiler uses different 34# syntax from other compilers. 35# IJSI_ and IJSF_ are defined in gs.mak (why?) 36# as are IJSGENDIR and IJSOBJDIR above. 37IJS_INCL=$(I_)$(IJSI_)$(_I) 38IJS_CCFLAGS=$(IJS_INCL) $(IJSF_) 39IJS_CC=$(CC_) $(IJS_CCFLAGS) 40 41# Define the name of this makefile. 42IJS_MAK=$(GLSRC)ijs.mak 43 44ijs.clean : ijs.config-clean ijs.clean-not-config-clean 45 46### WRONG. MUST DELETE OBJ AND GEN FILES SELECTIVELY. 47ijs.clean-not-config-clean : 48# echo $(IJSSRC) $(IJSGEN) $(IJSOBJ) $(IJSO_) 49 $(EXP)$(ECHOGS_XE) $(IJSSRC) $(IJSGEN) $(IJSOBJ) $(IJSO_) 50 $(RM_) $(IJSOBJ)*.$(OBJ) 51 52ijs.config-clean : 53 $(RMN_) $(IJSGEN)ijs*.dev 54 55IJSDEP=$(AK) 56 57ijslib_=$(IJSOBJ)ijs.$(OBJ) $(IJSOBJ)ijs_server.$(OBJ) \ 58 $(IJSOBJ)ijs_client.$(OBJ) $(IJSOBJ)ijs_exec_$(IJSEXECTYPE).$(OBJ) 59$(IJSGEN)ijslib.dev : $(IJS_MAK) $(ECHOGS_XE) $(ijslib_) 60 $(SETMOD) $(IJSGEN)ijslib $(ijslib_) 61 62ijs_h=$(IJSSRC)ijs.h 63 64ijs_client_h=$(IJSSRC)$(D)ijs_client.h 65ijs_server_h=$(IJSSRC)$(D)ijs_server.h 66 67$(IJSOBJ)ijs.$(OBJ) : $(IJSSRC)ijs.c $(IJSDEP) $(ijs_h) 68# echo $(IJS_CCFLAGS) 69 $(EXP)$(ECHOGS_XE) $(IJS_CCFLAGS) 70 $(IJS_CC) $(IJSO_)ijs.$(OBJ) $(C_) $(IJSSRC)ijs.c 71 72$(IJSOBJ)ijs_client.$(OBJ) : $(IJSSRC)ijs_client.c \ 73 $(IJSDEP) $(ijs_h) $(ijs_client_h) 74 $(IJS_CC) $(IJSO_)ijs_client.$(OBJ) $(C_) $(IJSSRC)ijs_client.c 75 76$(IJSOBJ)ijs_server.$(OBJ) : $(IJSSRC)ijs_server.c \ 77 $(IJSDEP) $(ijs_h) $(ijs_server_h) 78 $(IJS_CC) $(IJSO_)ijs_server.$(OBJ) $(C_) $(IJSSRC)ijs_server.c 79 80$(IJSOBJ)ijs_exec_unix.$(OBJ) : $(IJSSRC)ijs_exec_unix.c \ 81 $(IJSDEP) $(ijs_h) $(ijs_client_h) 82 $(IJS_CC) $(IJSO_)ijs_exec_unix.$(OBJ) $(C_) $(IJSSRC)ijs_exec_unix.c 83 84$(IJSOBJ)ijs_exec_win.$(OBJ) : $(IJSSRC)ijs_exec_win.c \ 85 $(IJSDEP) $(ijs_h) $(ijs_client_h) 86# This can't be compiled with /Za because it needs windows.h. 87 $(CC_WX) $(IJS_CCFLAGS) $(IJSO_)ijs_exec_win.$(OBJ) $(C_) $(IJSSRC)ijs_exec_win.c 88 89 90# 91# rules for the example client/server implementation 92# FIXME: linking not portable (or per policy!) 93 94ijs_server_example_=$(BINDIR)$(D)ijs_server_example 95 96ijs_client_example_=$(BINDIR)$(D)ijs_client_example 97 98 99ijs_examples_=$(ijs_server_example_) $(ijs_client_example_) 100$(IJSGEN)ijs_examples.dev : $(IJS_MAK) $(ECHOGS_XE) \ 101 $(ijs_examples_) $(ijslib_) 102 $(SETMOD) $(IJSGEN)ijs_examples $(ijs_examples_) 103 $(ADDMOD) $(IJSGEN)ijs_examples $(ijslib_) 104 105$(IJSOBJ)ijs_client_example.$(OBJ) : $(IJSSRC)ijs_client_example.c \ 106 $(IJSDEP) $(ijs_h) $(ijs_client_h) 107 $(IJS_CC) $(IJSO_)ijs_client_example.$(OBJ) $(C_) $(IJSSRC)ijs_client_example.c 108 109$(BINDIR)$(D)ijs_client_example : $(IJSOBJ)ijs_client_example.$(OBJ) $(ijslib_) 110 $(IJS_CC) -o bin/ijs_client_example $(IJSOBJ)ijs_client_example.$(OBJ) $(ijslib_) 111 112$(IJSOBJ)ijs_server_example.$(OBJ) : $(IJSSRC)ijs_server_example.c \ 113 $(IJSDEP) $(ijs_h) $(ijs_server_h) 114 $(IJS_CC) $(IJSO_)ijs_server_example.$(OBJ) $(C_) $(IJSSRC)ijs_server_example.c 115 116$(BINDIR)$(D)ijs_server_example : $(IJSOBJ)ijs_server_example.$(OBJ) $(ijslib_) 117 $(IJS_CC) -o bin/ijs_server_example $(IJSOBJ)ijs_server_example.$(OBJ) $(ijslib_) 118