#------------------------------------------------------------------# # # # KOFIA executable Makefile # # Morgan Burke (TRIUMF) # # 1992-Sept-08 # # # # usage examples: # # # # % make # # % make photo # # % make FFLAGS=-g OBJECTS="dplot.o define.o" OUTPUT=test.exe # #------------------------------------------------------------------# #------------------------------------------------------------------# # this can be changed here, or defined on the command line. # (Say "make OUTPUT=progname", for example.) OUTPUT=kofia_online.exe #------------------------------------------------------------------# # this is defined so that you can specify extra object files # on the command line. (Say "make OBJECTS=file.o", for example.) OBJECTS=unp3377.o #------------------------------------------------------------------# # if you have your own version of a standard library, add it # to the environment variable $LDIRFLAGS, or to the front of this # list LIBDIRS= $(LDIRFLAGS) -L$(E949LIB) -L$(CERNLIB) #------------------------------------------------------------------# # add your object files and personal libraries to the end of this list KOFIA_OBJS = \ $(ONLINE_KOFIA)/kofia_dd.o \ $(E949LIB)/kofia.o #------------------------------------------------------------------# # don't change these settings PLAIN_LIBS = \ -lmain$(KOFIA_VERS) PHOTO_LIBS = \ -lmain$(KOFIA_VERS) \ -lphoto$(KOFIA_VERS) #------------------------------------------------------------------# # add or delete the standard KOFIA libraries as you require them KOFIA_LIBS = \ -lutc$(KOFIA_VERS) \ -luser$(KOFIA_VERS) \ -lkumc$(KOFIA_VERS) \ -ltt$(KOFIA_VERS) \ -lbw$(KOFIA_VERS) \ -lccd$(KOFIA_VERS) \ -ltd$(KOFIA_VERS) \ -lunp$(KOFIA_VERS) \ -lcal$(KOFIA_VERS) OLD_KOFIA_LIBS = \ -luser$(KOFIA_VERS) \ -lkumc$(KOFIA_VERS) \ -ltt$(KOFIA_VERS) \ -lbw$(KOFIA_VERS) \ -lutc$(KOFIA_VERS) \ -lccd$(KOFIA_VERS) \ -ltd$(KOFIA_VERS) \ -lunp$(KOFIA_VERS) \ -lcal$(KOFIA_VERS) DD_LIBS = $(DD_LIB)/lib$(DBG_PREFIX)dd.a #------------------------------------------------------------------# # add or delete the support libraries as you require them # additional libraries can be specified using the $LFLAGS environment # variable OTHER_LIBS = \ -lcfm \ -lbru \ -lgplot \ -lybos$(YBOS_VERS) \ -lpacklib \ -lmathlib \ -lkernlib \ -ldummy$(KOFIA_VERS) \ $(LFLAGS) #------------------------------------------------------------------# # normal kofia, suitable for analysis jobs. # Say "make" or "make kofia". kofia : $(KOFIA_OBJS) $(OBJECTS) CC -o $(OUTPUT) $(CFLAGS) $(LIBDIRS) -g -o32 -exceptions -G 0 $(KOFIA_OBJS) $(OBJECTS) $(PLAIN_LIBS) $(KOFIA_LIBS) $(DD_LIB)/lib$(DBG_PREFIX)dd.a $(OTOOLS_LIB)/lib$(DBG_PREFIX)otools.a $(OTHER_LIBS) -lX11 -lI77 -lisam -lF77 -lU77 -lm #kofia : $(KOFIA_OBJS) $(OBJECTS) # $(F77) -o $(OUTPUT) $(FFLAGS) $(LIBDIRS) $(KOFIA_OBJS) $(OBJECTS) $(PLAIN_LIBS) $(KOFIA_LIBS) $(OTHER_LIBS) $(DD_LIBS) #------------------------------------------------------------------# # plain kofia, no analysis code linked in. # Say "make plain". plain : $(KOFIA_OBJS) $(F77) -o $(OUTPUT) $(FFLAGS) $(LIBDIRS) $(KOFIA_OBJS) $(PLAIN_LIBS) $(OTHER_LIBS) #------------------------------------------------------------------# # normal photo, suitable for non-X terminal types. # Say "make photo". photo : $(KOFIA_OBJS) $(OBJECTS) $(F77) -o $(OUTPUT) $(FFLAGS) $(LIBDIRS) $(KOFIA_OBJS) $(OBJECTS) $(PHOTO_LIBS) $(KOFIA_LIBS) $(OTHER_LIBS) -lX11 #------------------------------------------------------------------# # photo with Motif interface, suitable for interactive photo jobs. # Say "make xphoto". xphoto : $(KOFIA_OBJS) $(OBJECTS) ld -o $(OUTPUT) $(LIBDIRS) -G 0 -g0 -nocount /usr/lib/crt1.o -count $(KOFIA_OBJS) $(OBJECTS) $(PHOTO_LIBS) $(KOFIA_LIBS) -lui $(OTHER_LIBS) -lfpe -lXm -lXt -lX11 -lPW -nocount -lF77 -lm -lU77 -lI77 -lisam -lmpc -lc /usr/lib/crtn.o #------------------------------------------------------------------# # all binaries all : -rm plain kofia photo xphoto make -f $(E949BIN)/make.kofia plain OUTPUT=plain make -f $(E949BIN)/make.kofia kofia OUTPUT=kofia make -f $(E949BIN)/make.kofia photo OUTPUT=photo make -f $(E949BIN)/make.kofia xphoto OUTPUT=xphoto #------------------------------------------------------------------# # standard rules and definitions include $(E949ETC)/make.std