# # $Id: Makefile.aimk,v 1.1 1999/11/15 23:55:25 tim Exp $ # # Makefile.aimk for PVM example programs. # # Set PVM_ROOT to the path where PVM includes & libraries are installed. # Set PVM_ARCH to your architecture type (SUN4, HP9K, RS6K, SGI, etc.) # Set ARCHLIB to any special libs needed on PVM_ARCH (-lrpc, -lsocket, # etc.) # otherwise leave ARCHLIB blank # # PVM_ARCH and ARCHLIB are set for you if you use "$PVM_ROOT/lib/aimk" # instead of "make". # # aimk also creates a $PVM_ARCH directory below this one and will cd # to it before invoking make - this allows building in parallel on # different arches. # PVM_ROOT = /usr/local/pvm3 #Quay added this SHELL = /bin/sh PVMDIR = ../.. LIBDIR = $(PVM_ROOT) SDIR = $(PVMDIR)/examples CFLOPTS = -g CFLAGS = $(CFLOPTS) -I$(PVMDIR)/include -I$(PVM_ROOT)/include $(ARCHCFLAGS) ##### Need to select some architecture-specific libraries to link tasks # The default setup is for workstations ### Select PVMLIB depending on architecture. # For MPPs (PGON and SP2MPI) select: # PVMLIB = -lpvm3pe # For Workstations and shared memory architectures select: # PVMLIB = -lpvm3 PVMLIB = -lpvm3 ### Select the PVMHLIB depending on architecture # Host versions of programs use sockets to communicate with the daemon. # They can be built with aimk hostprogs, they are only necessary for # MPPs and are OPTIONAL for other architectures # # For MPPs and Workstations select # PVMHLIB = -lpvm3 # for Shared Memory Archtiectures # PVMHLIB = -lpvm3s PVMHLIB = -lpvm3 ######################################################################## LIBS = $(PVMLIB) $(ARCHLIB) HLIBS = $(PVMHLIB) $(ARCHLIB) GLIBS = -lgpvm3 #F77 = f77 FORT = `case "$(FC)@$(F77)" in @) echo f77 ;; *@) echo $(FC) ;; @*) echo $(F77) ;; *) echo $(FC) ;; esac` FFLOPTS = -g FFLAGS = $(FFLOPTS) $(ARCHFFLAGS) FLIBS = -lfpvm3 LFLAGS = $(LOPT) -L$(LIBDIR)/lib/$(PVM_ARCH) CPROGS = hello$(EXESFX) hello_other$(EXESFX) HOSTCPROGS = helloh default: hello$(EXESFX) hello_other$(EXESFX) all: c-all c-all: $(CPROGS) $(CTXPROGS) $(MBPROGS) hostprogs: $(HOSTCRPROGS) clean: rm -f *.o $(CPROGS) hello$(EXESFX): $(SDIR)/hello.c $(CC) $(CFLAGS) -o $@ $(SDIR)/hello.c $(LFLAGS) $(LIBS) helloh: $(SDIR)/hello.c $(CC) $(CFLAGS) -o $@ $(SDIR)/hello.c $(LFLAGS) $(HLIBS) hello_other$(EXESFX): $(SDIR)/hello_other.c $(CC) $(CFLAGS) -o $@ $(SDIR)/hello_other.c $(LFLAGS) $(LIBS)