![]() ![]() |
![]() |
File: [Development] / JSOC / Rules.mk
(download)
Revision: 1.5, Wed Feb 2 19:49:16 2011 UTC (12 years, 3 months ago) by arta Branch: MAIN CVS Tags: Ver_LATEST, Ver_DRMSLATEST, Ver_9-5, Ver_9-41, Ver_9-4, Ver_9-3, Ver_9-2, Ver_9-1, Ver_9-0, Ver_8-8, Ver_8-7, Ver_8-6, Ver_8-5, Ver_8-4, Ver_8-3, Ver_8-2, Ver_8-12, Ver_8-11, Ver_8-10, Ver_8-1, Ver_8-0, Ver_7-1, Ver_7-0, Ver_6-4, Ver_6-3, Ver_6-2, Ver_6-1, Ver_6-0, Ver_5-14, Ver_5-13, NetDRMS_Ver_LATEST, NetDRMS_Ver_9-9, NetDRMS_Ver_9-5, NetDRMS_Ver_9-41, NetDRMS_Ver_9-4, NetDRMS_Ver_9-3, NetDRMS_Ver_9-2, NetDRMS_Ver_9-1, NetDRMS_Ver_9-0, NetDRMS_Ver_8-8, NetDRMS_Ver_8-7, NetDRMS_Ver_8-6, NetDRMS_Ver_8-5, NetDRMS_Ver_8-4, NetDRMS_Ver_8-3, NetDRMS_Ver_8-2, NetDRMS_Ver_8-12, NetDRMS_Ver_8-11, NetDRMS_Ver_8-10, NetDRMS_Ver_8-1, NetDRMS_Ver_8-0, NetDRMS_Ver_7-1, NetDRMS_Ver_7-0, NetDRMS_Ver_6-4, NetDRMS_Ver_6-3, NetDRMS_Ver_6-2, NetDRMS_Ver_6-1, NetDRMS_Ver_6-0, NetDRMS_Ver_2-7, NetDRMS_Ver_2-6 Changes since 1.4: +1 -1 lines Source configure and make changes that allow users to checkout NetDRMS plus specified proj directories. |
# Note: this design uses target-specific flags, because it's the only # way to get the value of a variable that's different for each # subdirectory, $(d), into the build recipes. Once you go that way, # you can as well use the feature to specify (extra) objects and # libraries to be linked or archived. # Standard stuff .SUFFIXES: .SUFFIXES: .c .o all: targets # Subdirectories, in random order dir := base -include $(SRCDIR)/$(dir)/Rules.mk dir := proj -include $(SRCDIR)/$(LOCALIZATIONDIR)/Rules.mk # Non-default targets idl: $(LIBJSOC_MAIN_SOCK_I) dsds: $(LIBSOIJSOC) $(LIBDSDS) examples: $(EXAMPLES) sums: $(SUMS_BIN) universe: targets idl dsds examples sums $(LIBDSPUTIL) # General directory-independent flags (MUST BE DEFINED BEFORE THE SECTION # "General directory-independent rules" $(FPICOBJ): CF_TGT := $(CF_TGT) -fPIC $(FIOBJ): CF_TGT := $(CF_TGT) -DFLIB $(IIOBJ): CF_TGT := $(CF_TGT) -DIDLLIB # General directory-independent rules %.c: %.pgc $(ECPG) %.c: %.i $(SWIG) %.o: %.f $(FCOMP) %.o: %.f90 $(FCOMP) # If a .f file is to be compiled more than one, the Rules.mk file that # contains the rules for that .f file exists in a subdirectory of the # directory that contains the .f file. As a result, the stem of the # of the corresponding .o file is the child of the stem of the .f file. %.o: ../%.f $(FCOMP) %.o: ../%.f90 $(FCOMP) %.o: %.c $(COMP) # If a .c file is to be compiled more than one, the Rules.mk file that # contains the rules for that .c file exists in a subdirectory of the # directory that contains the .c file. As a result, the stem of the # of the corresponding .o file is the child of the stem of the .c file. %.o: ../%.c $(COMP) %: %.o $(LINK) %: %.c $(COMPLINK) # These two targets collect real targets, i.e. ones that can be built. .PHONY: targets targets: $(TGT_BIN) $(TGT_LIB) # These targets merely contain commands to be executed, i.e. they collect # only .PHONY targets, even if they're not explicitly marked as such. # The install target does not collect dependencies (other than for forcing # things to be built) because it's always considered 'out of date' anway as # it's a .PHONY target. Instead, it collects installation commands that will be # ran in addition to the standard ones to install the known targets. .PHONY: clean clean: rm -f $(CLEAN) # Prevent make from removing any build targets, including intermediate ones .SECONDARY: $(CLEAN)
Karen Tian |
Powered by ViewCVS 0.9.4 |