Makefile revision 115013
1115013Smarcel# Makefile for IPF unwind express library, libuwx. 2115013Smarcel# 3115013Smarcel# To build a cross-unwind library (i.e., one hosted on a 4115013Smarcel# non-IPF, non-HP-UX system), omit the "self" callbacks 5115013Smarcel# and the dependency on libuca by setting SELFOBJS and 6115013Smarcel# SELFLIBS to empty strings. 7115013Smarcel 8115013SmarcelAR = ar 9115013SmarcelRANLIB = : 10115013Smarcel 11115013Smarcel# OTHERCFLAGS = -DDISABLE_TRACE # Disables trace output 12115013Smarcel# OTHERCFLAGS = +DD64 # Builds 64-bit library 13115013SmarcelOTHERCFLAGS = 14115013Smarcel 15115013SmarcelCFLAGS = +W944 -O $(OTHERCFLAGS) 16115013Smarcel 17115013SmarcelOBJS = uwx_bstream.o uwx_context.o uwx_env.o uwx_scoreboard.o \ 18115013Smarcel uwx_step.o uwx_str.o uwx_swap.o uwx_trace.o uwx_uinfo.o \ 19115013Smarcel uwx_utable.o 20115013Smarcel 21115013Smarcel# SELFOBJS = # For cross-unwind library 22115013SmarcelSELFOBJS = uwx_self.o uwx_self_context.o uwx_ttrace.o 23115013Smarcel 24115013Smarcel# SELFLIBS = # For cross-unwind library 25115013SmarcelSELFLIBS = -luca 26115013Smarcel 27115013Smarcellibuwx.a: $(OBJS) $(SELFOBJS) 28115013Smarcel $(AR) rv libuwx.a $? 29115013Smarcel $(RANLIB) libuwx.a 30115013Smarcel 31115013Smarcellibuwx.so: $(OBJS) $(SELFOBJS) 32115013Smarcel ld -b -o libuwx.so $(OBJS) $(SELFOBJS) $(SELFLIBS) 33115013Smarcel 34115013Smarcellibuwx.sl: $(OBJS) $(SELFOBJS) 35115013Smarcel ld -b -o libuwx.sl $(OBJS) $(SELFOBJS) $(SELFLIBS) 36115013Smarcel 37115013Smarceluwx_bstream.o: uwx.h uwx_env.h uwx_bstream.h 38115013Smarcel 39115013Smarceluwx_context.o: uwx.h uwx_env.h uwx_scoreboard.h uwx_trace.h 40115013Smarcel 41115013Smarceluwx_env.o: uwx.h uwx_env.h uwx_scoreboard.h uwx_str.h uwx_trace.h 42115013Smarcel 43115013Smarceluwx_scoreboard.o: uwx.h uwx_env.h uwx_scoreboard.h uwx_trace.h 44115013Smarcel 45115013Smarceluwx_step.o: uwx.h uwx_env.h uwx_context.h uwx_utable.h \ 46115013Smarcel uwx_uinfo.h uwx_scoreboard.h uwx_str.h uwx_trace.h 47115013Smarcel 48115013Smarceluwx_str.o: uwx.h uwx_env.h uwx_str.h 49115013Smarcel 50115013Smarceluwx_swap.o: uwx.h uwx_env.h uwx_swap.h 51115013Smarcel 52115013Smarceluwx_trace.o: uwx.h uwx_env.h uwx_uinfo.h uwx_scoreboard.h uwx_trace.h 53115013Smarcel 54115013Smarceluwx_uinfo.o: uwx.h uwx_env.h uwx_uinfo.h uwx_utable.h \ 55115013Smarcel uwx_scoreboard.h uwx_bstream.h uwx_trace.h 56115013Smarcel 57115013Smarceluwx_utable.o: uwx.h uwx_env.h uwx_utable.h uwx_swap.h uwx_trace.h 58115013Smarcel 59115013Smarceluwx_self.o: uwx.h uwx_env.h uwx_context.h uwx_trace.h uwx_self.h 60115013Smarcel 61115013Smarceluwx_self_context.o: uwx_self_context.s 62115013Smarcel $(CC) -c $(CFLAGS) -o uwx_self_context.o uwx_self_context.s 63115013Smarcel 64115013Smarceluwx_ttrace.o: uwx.h uwx_env.h uwx_context.h uwx_trace.h uwx_ttrace.h 65