source: trunk/WRF.COMMON/WRFV3/external/io_grib_share/build/utility_rules.mk @ 2759

Last change on this file since 2759 was 2759, checked in by aslmd, 2 years ago

adding unmodified code from WRFV3.0.1.1, expurged from useless data +1M size

File size: 2.2 KB
Line 
1#------------------------------------------------------------------------------
2#  Make rules for building an application program.
3#
4#  This file is intended for use in Makefile via the include directive, e.g.
5#
6#      include $(BUILD_DIR)/application_rules.mk
7#
8#  It is assumed that the environment has been set by sourcing the build
9#  resource file (buildrc).
10#
11#  Copyright (C) 2001, WSI Corporation
12#------------------------------------------------------------------------------
13#
14#  For portability, use the Bourne shell within Makefiles.
15#  There have been problems using the C-shell under Linux.
16#
17SHELL=/bin/sh
18
19#
20#  RULES for building a single utility program.
21#        The program will be named $(EXE_NAME).
22#        The objects files used to create the utility should be $(OBJS). 
23#        The libraries that should be linked should be $(DEP_LIBS).
24#
25all: exe config
26
27exe: $(OBJS) 
28        @echo "    Building utility program $(EXE_NAME)" ; \
29        $(LDD) $(DEBUG) $(OPTIMIZE) -o $(EXE_NAME) $(OBJS) $(DEP_LIBS) ;\
30        mv -f $(EXE_NAME) $(BIN_DEST) ;
31
32#
33#  Include the RULES for compilation and installation of config files
34#
35include $(BUILD_DIR)/compile_rules.mk
36include $(BUILD_DIR)/config_rules.mk
37
38#
39#  RULE for building a library
40#
41#  For exe modules, these do nothing, but we define one so that make lib
42#  can be passed down to all source directories.
43#
44lib:
45        @echo "make lib does nothing for utility modules"
46
47#
48#  RULES for cleaning up derived files.
49#
50#  'clean' removes all objects produced by this file, as well as other
51#      extraneous artifacts of compiling and building applications.
52#
53#      A subsequent make will both recompile the source code and recreate
54#      the executable.  clean also removes files core files and other
55#      auxilliary files created during compilation.
56#
57#  'clean_exe' removes the utility program.
58#
59clean: 
60        @/bin/rm -f *.o core* so_locations Makefile.bak *~ #*#
61        @/bin/rm -fr ii_files
62
63clean_exe:
64        @/bin/rm -f $(BIN_DEST)/$(EXE_NAME)
65
66clean_lib:
67        @echo "       make clean_lib does nothing for utility modules"
68
69#
70#  RULES for creating the include dependencies.
71#
72include $(BUILD_DIR)/depend_rules.mk
73
74clean_depend: generic_clean_depend
75
76depend: generic_depend
Note: See TracBrowser for help on using the repository browser.