|
NCBI Home IEB Home C Toolkit docs C++ Toolkit source browser C Toolkit source browser (2) |
NCBI C Toolkit Cross ReferenceC/demo/asn2asn.mk |
source navigation diff markup identifier search freetext search file search |
1 ######################################################################## 2 # demo makefile for NCBI applications 3 # 4 # This assumes the following variables are set in a file called "ncbi.mk" 5 # which is included by this one. In this case it resides in a directory 6 # set by the environment variable "NCBI" 7 # 8 # NCBI_CC = default compiler to use 9 # NCBI_CFLAGS1 = default compiler switches (not optimization) 10 # NCBI_LDFLAGS1 = default compiler switches when linking (not optimization) 11 # NCBI_OPTFLAG = default optimization (-O) 12 # NCBI_INCDIR = default toolkit include paths 13 # NCBI_LIBDIR = default toolkit library paths 14 # NCBI_ALTLIB = debugging toolkit library paths 15 # NCBI_VIBFLAG = additional include paths/defines for Vibrant apps 16 # NCBI_VIBLIBS = additional libraries needed to link Vibrant apps 17 # NCBI_OTHERLIBS = additional libraries needed to link the system 18 # 19 # This enables platform independent makefiles for ncbi toolkit apps. You 20 # can change any default behavior by setting the variable on the command 21 # line. 22 # 23 # Use gcc complier. "make NCBI_CC=gcc" or "make CC=gcc" 24 # Change optimization to debug 25 # "make NCBI_OPTFLAG="-g" NCBI_LIBPATH=$NCBI_ALTLIB" 26 # or 27 # "make OPTFLAG="-g" LIBPATH=$NCBI_ALTLIB" 28 # 29 # You can also change the behavior permanently in the makefile by changing 30 # the assignment of the internal variable to the one from the include 31 # file: 32 # 33 # Use gcc compiler. 34 # Change CC=$(NCBI_CC) 35 # To CC=gcc 36 # in the makefile itself 37 # 38 # Make debugging version 39 # OPTFLAG=-g 40 # LIBPATH=$(NCBI_ALTDIR) 41 # 42 # Current settings are: 43 # Sun OS: 44 # NCBI_CC = acc 45 # NCBI_CFLAGS1 = "-c" 46 # NCBI_LDFLAGS1 = "" 47 # NCBI_OPTFLAG = "-O" 48 # NCBI_INCPATH = "/usr/ncbi/include/NCBI" 49 # NCBI_LIBPATH = "/usr/ncbi/lib" 50 # NCBI_ALTLIB = "/am/ncbi/altlib" 51 # NCBI_VIBFLAG = "-I/am/Motif/include -L/am/Motif/lib -DWIN_MOTIF" 52 # NCBI_VIBLIBS = "-lXm -lXmu -lXt -lX11" 53 # NCBI_OTHERLIBS = "-lm" 54 # 55 # Silicon Graphics: 56 # NCBI_CC = cc 57 # NCBI_CFLAGS1 = "-c" 58 # NCBI_LDFLAGS1 = "" 59 # NCBI_OPTFLAG = "-O" 60 # NCBI_INCPATH = "/usr/ncbi/include/NCBI" 61 # NCBI_LIBPATH = "/usr/ncbi/lib" 62 # NCBI_ALTLIB = "/am/ncbi/altlib" 63 # NCBI_VIBFLAG = "-I/am/Motif/include -L/am/Motif/lib -DWIN_MOTIF" 64 # NCBI_VIBLIBS = "-lXm -lXmu -lXt -lX11" 65 # NCBI_OTHERLIBS = "-lm -lPW -lsun" 66 # 67 # Solaris: 68 # NCBI_CC = cc 69 # NCBI_CFLAGS1 = "-c -Xa" 70 # NCBI_LDFLAGS1 = "-Xa" 71 # NCBI_OPTFLAG = "-O" 72 # NCBI_INCPATH = "/netopt/ncbi_tools/ver0.0/ncbi/include/NCBI" 73 # NCBI_LIBPATH = "/netopt/ncbi_tools/ver0.0/ncbi/lib" 74 # NCBI_ALTLIB = "/netopt/ncbi_tools/ver0.0/ncbi/altlib" 75 # NCBI_VIBFLAG = "-I/netopt/X11R5/include -I/netopt/Motif1.2.2/include -L/netopt/X11R5/lib -L/netopt/Motif1.2.2/lib -DWIN_MOTIF" 76 # NCBI_VIBLIBS = "-lXm -lXmu -lXt -lX11" 77 # NCBI_OTHERLIBS = "-lm -lsocket -lnsl" 78 # 79 ####################################################################### 80 # 81 # default flags for compiling and loading 82 # 83 ####################################################################### 84 85 include $(NCBI)/ncbi.mk 86 87 CC = $(NCBI_CC) 88 CFLAGS1 = $(NCBI_CFLAGS1) 89 LDFLAGS1 = $(NCBI_LDFLAGS1) 90 OPTFLAG = $(NCBI_OPTFLAG) 91 OTHERLIBS = $(NCBI_OTHERLIBS) 92 VIBLIBS= $(NCBI_VIBLIBS) 93 VIBFLAG= $(NCBI_VIBFLAG) 94 INCPATH = $(NCBI_INCDIR) 95 LIBPATH = $(NCBI_LIBDIR) 96 97 CFLAGS = $(CFLAGS1) $(OPTFLAG) -I$(INCPATH) $(VIBFLAG) 98 LDFLAGS = -I$(INCPATH) $(OPTFLAG) -L$(LIBPATH) $(VIBFLAG) 99 100 # all NCBI libraries aliased for easy access here 101 102 LIB1 = -lncbi 103 LIB2 = -lncbiobj 104 LIB3 = -lncbicdr 105 LIB4 = -lvibrant 106 LIB5 = -lncbiacc 107 LIB6 = -lnetcli 108 LIB7 = -lnetentr 109 LIB8 = -lncbiNacc 110 LIB9 = -lncbiCacc 111 # LIB10 is reserved for NCSA socket library 112 LIB10 = 113 LIB11 = -lncbimla 114 LIB12 = -lncbitax 115 LIB13 = -lncbiid0 116 LIB14 = -lncbibls1 117 LIB15 = -lncbispel 118 119 ## To clean out the directory without removing make 120 ## 121 122 ## Implicit actions 123 ## 124 ## if need a .o, compile the .c 125 ## 126 127 .c.o : 128 $(CC) $(CFLAGS) $< 129 130 ##################################################################### 131 ## 132 ## Here is where you set up your own things to make 133 ## 134 ##################################################################### 135 136 ## Default thing to make will be "all", in this case it checks that the 137 ## source files exist, then tries to make "testcds" 138 ## 139 140 141 all : asn2asn 142 143 144 ## make individual applications and components 145 ## 146 147 ## These are non-vibrant versions 148 149 asn2asn : asn2asn.c 150 $(CC) -o asn2asn $(LDFLAGS) asn2asn.c $(LIB2) $(LIB1) $(OTHERLIBS) 151 152 asn2asn.pure : asn2asn.c 153 purify3 $(CC) -o asn2asn.pure $(LDFLAGS) asn2asn.c $(LIB2) $(LIB1) $(OTHERLIBS) 154 155 ## these are vibrant versions 156 ## 157 158 asn2asnv : asn2asn.c 159 $(CC) -o asn2asn $(LDFLAGS) asn2asn.c $(LIB4) $(LIB2) $(LIB1) $(OTHERLIBS) 160 161 asn2asnv.pure : asn2asn.c 162 purify3 $(CC) -o asn2asn.pure $(LDFLAGS) asn2asn.c $(LIB4) $(LIB2) $(LIB1) $(OTHERLIBS) 163
|
This page was automatically generated by the
LXR engine.
Visit the LXR main site for more information. |