The following is a sample platform generic makefile which can be used to build the sample Proxy application that is delivered with the CA Gen product installation. This makefile as well as the supporting cproxy.c source file can be found the sample subdirectory of the CA Gen installation directory.
######################################################################### # # # This is a platform generic makefile which can be used to build a # # sample C proxy which targets a Tuxedo server environment. The base # # name of the executable to be built is "cproxy". To provide a generic # # makefile for use on the supported platforms the following make # # commands should be executed on the specified platform. # # # # To use on Windows: # # nmake /f makefile.tux cproxy_win # # and # # nmake /f makefile.tux clean_win # # # # To use on HP UNIX: # # make -f makefile.tux cproxy_hp # # and # # make /f makefile.tux clean_hp # # # # To use on Sun Solaris: # # make /f makefile.tux cproxy_sol # # and # # make /f makefile.tux clean_sol # # # # To use on IBM AIX: # # make /f makefile.tux cproxy_aix # # and # # nmake /f makefile.tux clean_win # # # # # ######################################################################### ############## Common section #################################### #RELEASE= echo "Set RELEASE to the current release level" RELEASE=85 all: cproxy .SUFFIXES: .TVF .V .VV # Suffix rule for UNIX requires .V view files .TVF.V : echo y | viewc32 -n $< # Suffix rule for Windows requires .VV view files .TVF.VV: echo y | viewc32 -n $< # UNIX requires .V files UNIX_VFILES=SERVERD1.V SERVERDE.V SERVERM2.V SERVERD2.V SERVERM1.V SERVERMA.V # Windows requires .VV files WIN_VFILES=SERVERD1.VV SERVERDE.VV SERVERM2.VV SERVERD2.VV SERVERM1.VV SERVERMA.VV #################### UNIX Compiler Defines ######################### # # for building on HP11 Itanium UNIX HP_CC="aCC -DUNIX +DD64 -DHPIA64 -g +Z -DTUXEDO" # For building on Sun Solaris UNIX SOL_CC= "CC -m64 -DUNIX -DSYSV -DIEF_SOL -DTCP_THREAD -D_THREAD_SAFE -D_REENTRANT -g -DTUXEDO" # For building on IBM AIX AIX_CC="xlC_r -q64 -DUNIX -DAIX -q cpluscmt -DIEF_AIX -g -DTUXEDO" # common UNIX defines UNIX_INCS= -I. -I$(IEFH)/include -I$(TUXDIR)/include ######### Native Work-Station clients ################## # # For building native (local) clients uncomment the following MESSAGE # and UNIX_LIB lines # # For UNIX, to build a native client uncomment the following lines. # Native clients reside in the same Tuxedo Domain (same machine as Tuxedo # servers) and use the same TUXCONFIG file. Therefore make sure that the # TUXCONFIG environment variable is set to the same value as used by the Tuxedo # servers. In addition set the following env variables prior to executing # the sample application: VIEWDIR32, VIEWFILES32. # # VIEWDIR32 is a colon separate list of search directories. Where to # # find Tuxedo view (.V) files # export VIEWDIR32=/users/testuser/model.ief/c/proxy/c # # VIEWFILES32 is a comma separated list of Tuxedo view (.V) files. # export VIEWFILES32=SERVERD1.V,SERVERDE.V,SERVERM2.V,SERVERD2.V,SERVERM1.V,SERVERMA.V # # MESSAGE="Building A Native Client" UNIX_LIB=-L$(IEFH)/lib -lpxrt.$(RELEASE) # # # For building Work-Station client's uncomment the following MESSAGE, # UNIX_CFLAGS2, and UNIX_LIB lines # # Work-Station clients reside outside the Tuxedo Domain ( on a machine # separate from the machine hosting the Tuxedo servers) and use the # WSL to connect to the Tuxedo Servers. In addition set the following # environment variables prior to executing the sample application: # WSNADDR, VIEWDIR32, VIEWFILES32. # # VIEWDIR32 is a colon separate list of search directories. Where to # # find Tuxedo view (.V) files # export VIEWDIR32=/users/testuser/model.ief/c/proxy/c # # VIEWFILES32 is a comma separated list of Tuxedo view (.V) files. # export VIEWFILES32=SERVERD1.V,SERVERDE.V,SERVERM2.V,SERVERD2.V,SERVERM1.V,SERVERMA.V # # WSNADDR contains the hostname and port number assigned to the Tuxedo # # WSL process running on the Target server machine # # export WSNADDR=//Server_hostname:7878 # # #UNIX_CFLAGS2=-DWS_CLIENT #MESSAGE="Building A Work-Station Client" #UNIX_LIB=-L$(IEFH)/lib -lpxrt.$(RELEASE) -ltxwcf.$(RELEASE) #BLDCLNT_OPT=-w #################### UNIX Compile/link rules ########################### # # cproxy_hp : $(UNIX_VFILES) echo $(MESSAGE) CC=$(HP_CC) CFLAGS="$(UNIX_CFLAGS2) $(UNIX_INCS) $(UNIX_LIB)" buildclient $(BLDCLNT_OPT) -o cproxy -f cproxy.c cproxy_aix : $(UNIX_VFILES) echo $(MESSAGE) CC=$(AIX_CC) CFLAGS="$(UNIX_CFLAGS2) $(UNIX_INCS) $(UNIX_LIB)" buildclient $(BLDCLNT_OPT) -o cproxy -f cproxy.c cproxy_sol : $(UNIX_VFILES) echo $(MESSAGE) CC=$(SOL_CC) CFLAGS="$(UNIX_CFLAGS2) $(UNIX_INCS) $(UNIX_LIB)" buildclient $(BLDCLNT_OPT) -o cproxy -f cproxy.c #################### Windows compile/link rules ###################### # # Windows Work-Station clients reside outside the Tuxedo Domain ( on a # machine separate from the machine hosting the Tuxedo servers) thus # must use the Tuxedo environment WSL process to connect to the Tuxedo # Servers. The following environment variables must be set prior to # executing the sample application: # WSNADDR, VIEWDIR32, VIEWFILES32. # # VIEWDIR32 is a semicolon separate list of search directories. # # where to find Tuxedo view (.V) files # set VIEWDIR32=/users/testuser/model.ief/c/proxy/c # # VIEWFILES32 is a comma separated list of Tuxedo view (.V) files. # set VIEWFILES32=SERVERD1.V,SERVERDE.V,SERVERM2.V,SERVERD2.V,SERVERM1.V,SERVERMA.V # # WSNADDR contains the hostname and port number assigned to the # # Tuxedo WSL process running on the Target server machine # set WSNADDR=//Server_hostname:7878 # cproxy_win : $(WIN_VFILES) set CFLAGS= -DTUXEDO -DWS_CLIENT -I. -I"$(IEFH)" "$(IEFH)\pxrt85n.lib" -I"$(TUXDIR)\include" buildclient -o cproxy -f cproxy.c # # clean rules # clean_unx : rm -f *.o cproxy *.V S*.h clean_win : del s*.h *.obj cproxy.exe *.VV clean_aix: clean_unx clean_hp: clean_unx
|
Copyright © 2015 CA Technologies.
All rights reserved.
|
|