willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 1 | # This makefile supports different OS and CPU setups. |
| 2 | # You should use it this way : |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 3 | # make TARGET=os CPU=cpu REGEX=lib |
Willy Tarreau | f2ef8c5 | 2007-07-11 09:19:31 +0200 | [diff] [blame] | 4 | # |
| 5 | # Some external components may be build with it, such dlmalloc : |
| 6 | # |
| 7 | # make DLMALLOC_SRC=/usr/local/src/dlmalloc.c |
willy tarreau | cee272f | 2006-03-19 21:16:26 +0100 | [diff] [blame] | 8 | |
willy tarreau | 750a472 | 2005-12-17 13:21:24 +0100 | [diff] [blame] | 9 | # Select target OS. TARGET must match a system for which COPTS and LIBS are |
| 10 | # correctly defined below. |
willy tarreau | 1c2ad21 | 2005-12-18 01:11:29 +0100 | [diff] [blame] | 11 | #TARGET = linux26 |
willy tarreau | 750a472 | 2005-12-17 13:21:24 +0100 | [diff] [blame] | 12 | TARGET = linux24 |
willy tarreau | 64a3cc3 | 2005-12-18 01:13:11 +0100 | [diff] [blame] | 13 | #TARGET = linux24e |
willy tarreau | 750a472 | 2005-12-17 13:21:24 +0100 | [diff] [blame] | 14 | #TARGET = linux22 |
| 15 | #TARGET = solaris |
willy tarreau | 750a472 | 2005-12-17 13:21:24 +0100 | [diff] [blame] | 16 | |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 17 | USE_POLL = 1 |
| 18 | |
| 19 | ifeq ($(TARGET),linux24e) |
| 20 | USE_EPOLL = 1 |
Willy Tarreau | de99e99 | 2007-04-16 00:53:59 +0200 | [diff] [blame] | 21 | USE_SEPOLL = 1 |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 22 | endif |
| 23 | |
| 24 | ifeq ($(TARGET),linux26) |
| 25 | USE_EPOLL = 1 |
Willy Tarreau | de99e99 | 2007-04-16 00:53:59 +0200 | [diff] [blame] | 26 | USE_SEPOLL = 1 |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 27 | endif |
| 28 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 29 | # pass CPU=<cpu_name> to make to optimize for a particular CPU |
| 30 | CPU = generic |
| 31 | #CPU = i586 |
| 32 | #CPU = i686 |
| 33 | #CPU = ultrasparc |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 34 | |
willy tarreau | 4373b96 | 2005-12-18 01:32:31 +0100 | [diff] [blame] | 35 | # By default, we use libc's regex. WARNING! On Solaris 8/Sparc, group |
| 36 | # references seem broken using libc ! Use pcre instead. |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 37 | REGEX=libc |
| 38 | #REGEX=pcre |
willy tarreau | 4373b96 | 2005-12-18 01:32:31 +0100 | [diff] [blame] | 39 | #REGEX=static-pcre |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 40 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 41 | # tools options |
| 42 | CC = gcc |
| 43 | LD = gcc |
| 44 | |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 45 | # This is the directory hosting include/pcre.h and lib/libpcre.* when REGEX=pcre |
willy tarreau | 2f6ba65 | 2005-12-17 13:57:42 +0100 | [diff] [blame] | 46 | PCREDIR := $(shell pcre-config --prefix 2>/dev/null || :) |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 47 | #PCREDIR=/usr/local |
| 48 | |
Willy Tarreau | 6d1a988 | 2007-01-07 02:03:04 +0100 | [diff] [blame] | 49 | # This is the directory hosting libtcpsplice.[ah] when USE_TCPSPLICE is set |
| 50 | TCPSPLICEDIR := |
| 51 | |
willy tarreau | 64a3cc3 | 2005-12-18 01:13:11 +0100 | [diff] [blame] | 52 | # This is for standard Linux 2.6 with netfilter and epoll() |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 53 | COPTS.linux26 = -DNETFILTER |
willy tarreau | 1c2ad21 | 2005-12-18 01:11:29 +0100 | [diff] [blame] | 54 | LIBS.linux26 = |
| 55 | |
willy tarreau | b952e1d | 2005-12-18 01:31:20 +0100 | [diff] [blame] | 56 | # This is for enhanced Linux 2.4 with netfilter and epoll() patch. |
| 57 | # Warning! If kernel is 2.4 with epoll-lt <= 0.21, then you must add |
| 58 | # -DEPOLL_CTL_MOD_WORKAROUND to workaround a very rare bug. |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 59 | #COPTS.linux24e = -DNETFILTER -DUSE_MY_EPOLL -DEPOLL_CTL_MOD_WORKAROUND |
| 60 | COPTS.linux24e = -DNETFILTER -DUSE_MY_EPOLL |
willy tarreau | 64a3cc3 | 2005-12-18 01:13:11 +0100 | [diff] [blame] | 61 | LIBS.linux24e = |
| 62 | |
| 63 | # This is for standard Linux 2.4 with netfilter but without epoll() |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 64 | COPTS.linux24 = -DNETFILTER |
willy tarreau | 5cbea6f | 2005-12-17 12:48:26 +0100 | [diff] [blame] | 65 | LIBS.linux24 = |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 66 | |
willy tarreau | 5cbea6f | 2005-12-17 12:48:26 +0100 | [diff] [blame] | 67 | # This is for Linux 2.2 |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 68 | COPTS.linux22 = -DUSE_GETSOCKNAME |
willy tarreau | 5cbea6f | 2005-12-17 12:48:26 +0100 | [diff] [blame] | 69 | LIBS.linux22 = |
| 70 | |
| 71 | # This is for Solaris 8 |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 72 | COPTS.solaris = -fomit-frame-pointer -DFD_SETSIZE=65536 |
willy tarreau | 9da061b | 2005-12-17 12:29:56 +0100 | [diff] [blame] | 73 | LIBS.solaris = -lnsl -lsocket |
| 74 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 75 | # CPU dependant optimizations |
| 76 | COPTS.generic = -O2 |
Willy Tarreau | 390223b | 2006-10-15 23:43:42 +0200 | [diff] [blame] | 77 | COPTS.i586 = -O2 -march=i586 -DCONFIG_HAP_USE_REGPARM |
| 78 | COPTS.i686 = -O2 -march=i686 -DCONFIG_HAP_USE_REGPARM |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 79 | COPTS.ultrasparc = -O6 -mcpu=v9 -mtune=ultrasparc |
| 80 | |
| 81 | # options for standard regex library |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 82 | COPTS.libc= |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 83 | LIBS.libc= |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 84 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 85 | # options for libpcre |
willy tarreau | 036e1ce | 2005-12-17 13:46:33 +0100 | [diff] [blame] | 86 | COPTS.pcre=-DUSE_PCRE -I$(PCREDIR)/include |
| 87 | LIBS.pcre=-L$(PCREDIR)/lib -lpcreposix -lpcre |
| 88 | |
willy tarreau | 4373b96 | 2005-12-18 01:32:31 +0100 | [diff] [blame] | 89 | # options for static libpcre |
| 90 | COPTS.static-pcre=-DUSE_PCRE -I$(PCREDIR)/include |
| 91 | LIBS.static-pcre=-L$(PCREDIR)/lib -Wl,-Bstatic -lpcreposix -lpcre -Wl,-Bdynamic |
| 92 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 93 | # you can enable debug arguments with "DEBUG=-g" or disable them with "DEBUG=" |
willy tarreau | d38e72d | 2006-03-19 20:56:52 +0100 | [diff] [blame] | 94 | #DEBUG = -g -DDEBUG_MEMORY -DDEBUG_FULL |
willy tarreau | 5cbea6f | 2005-12-17 12:48:26 +0100 | [diff] [blame] | 95 | DEBUG = -g |
willy tarreau | 9da061b | 2005-12-17 12:29:56 +0100 | [diff] [blame] | 96 | |
willy tarreau | 0174f31 | 2005-12-18 01:02:42 +0100 | [diff] [blame] | 97 | # if small memory footprint is required, you can reduce the buffer size. There |
| 98 | # are 2 buffers per concurrent session, so 16 kB buffers will eat 32 MB memory |
willy tarreau | 64a3cc3 | 2005-12-18 01:13:11 +0100 | [diff] [blame] | 99 | # with 1000 concurrent sessions. Putting it slightly lower than a page size |
willy tarreau | d38e72d | 2006-03-19 20:56:52 +0100 | [diff] [blame] | 100 | # will avoid the additionnal paramters to overflow a page. 8030 bytes is |
| 101 | # exactly 5.5 TCP segments of 1460 bytes. |
| 102 | #SMALL_OPTS = -DBUFSIZE=8030 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=1024 |
willy tarreau | 0174f31 | 2005-12-18 01:02:42 +0100 | [diff] [blame] | 103 | SMALL_OPTS = |
| 104 | |
willy tarreau | 1c2ad21 | 2005-12-18 01:11:29 +0100 | [diff] [blame] | 105 | # redefine this if you want to add some special PATH to include/libs |
| 106 | ADDINC = |
| 107 | ADDLIB = |
| 108 | |
| 109 | # set some defines when needed. |
willy tarreau | d38e72d | 2006-03-19 20:56:52 +0100 | [diff] [blame] | 110 | # - use -DTPROXY to compile with transparent proxy support. |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 111 | DEFINE = -DTPROXY |
willy tarreau | 0174f31 | 2005-12-18 01:02:42 +0100 | [diff] [blame] | 112 | |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 113 | # Now let's determine the version, sub-version and release date. |
| 114 | # If we're in the GIT tree, we can use the last commit's version and date. |
Willy Tarreau | 6620dbb | 2007-01-02 00:44:53 +0100 | [diff] [blame] | 115 | ifeq ($(IGNOREGIT),) |
Willy Tarreau | ec69256 | 2007-09-09 23:31:11 +0200 | [diff] [blame] | 116 | VERSION := $(shell [ -d .git/. ] && ref=`(git-describe --tags) 2>/dev/null` && ref=$${ref%-g*} && echo "$${ref\#v}") |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 117 | ifneq ($(VERSION),) |
| 118 | # OK git is there and works. |
Willy Tarreau | a1973c4 | 2007-04-09 22:07:11 +0200 | [diff] [blame] | 119 | SUBVERS := $(shell comms=`git-log --no-merges v$(VERSION).. 2>/dev/null |grep -c ^commit `; [ $$comms -gt 0 ] && echo "-$$comms" ) |
| 120 | VERDATE := $(shell date +%Y/%m/%d -d "`git-log HEAD^.. 2>/dev/null | grep -m 1 ^Date: | cut -f2- -d: | cut -f1 -d+`" ) |
Willy Tarreau | ec69256 | 2007-09-09 23:31:11 +0200 | [diff] [blame] | 121 | endif |
| 122 | endif |
| 123 | |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 124 | # Otherwise, use the hard-coded version of last tag, number of changes |
| 125 | # since last tag, and release date. |
Willy Tarreau | ec69256 | 2007-09-09 23:31:11 +0200 | [diff] [blame] | 126 | ifeq ($(VERSION),) |
| 127 | VERSION := $(shell cat VERSION 2>/dev/null || touch VERSION) |
| 128 | endif |
| 129 | ifeq ($(SUBVERS),) |
| 130 | SUBVERS := $(shell cat SUBVERS 2>/dev/null || touch SUBVERS) |
| 131 | endif |
| 132 | ifeq ($(VERDATE),) |
| 133 | VERDATE := $(shell cat VERDATE 2>/dev/null || touch VERDATE) |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 134 | endif |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 135 | |
| 136 | #### build options |
| 137 | |
| 138 | # do not change this one, enable USE_* variables instead. |
| 139 | OPTIONS = |
Willy Tarreau | b38651a | 2007-03-24 17:24:39 +0100 | [diff] [blame] | 140 | OPT_OBJS = |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 141 | |
Willy Tarreau | 6d1a988 | 2007-01-07 02:03:04 +0100 | [diff] [blame] | 142 | ifneq ($(USE_TCPSPLICE),) |
| 143 | OPTIONS += -DCONFIG_HAP_TCPSPLICE |
| 144 | endif |
| 145 | |
Willy Tarreau | b38651a | 2007-03-24 17:24:39 +0100 | [diff] [blame] | 146 | # - set USE_CTTPROXY to enable full transparent proxy support |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 147 | ifneq ($(USE_CTTPROXY),) |
| 148 | OPTIONS += -DCONFIG_HAP_CTTPROXY |
Willy Tarreau | b38651a | 2007-03-24 17:24:39 +0100 | [diff] [blame] | 149 | OPT_OBJS += src/cttproxy.o |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 150 | endif |
| 151 | |
| 152 | ifneq ($(USE_TPROXY),) |
| 153 | OPTIONS += -DTPROXY |
| 154 | endif |
| 155 | |
| 156 | ifneq ($(USE_POLL),) |
| 157 | OPTIONS += -DENABLE_POLL |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 158 | OPT_OBJS += src/ev_poll.o |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 159 | endif |
| 160 | |
| 161 | ifneq ($(USE_EPOLL),) |
| 162 | OPTIONS += -DENABLE_EPOLL |
Willy Tarreau | 4f60f16 | 2007-04-08 16:39:58 +0200 | [diff] [blame] | 163 | OPT_OBJS += src/ev_epoll.o |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 164 | endif |
| 165 | |
Willy Tarreau | de99e99 | 2007-04-16 00:53:59 +0200 | [diff] [blame] | 166 | ifneq ($(USE_SEPOLL),) |
| 167 | OPTIONS += -DENABLE_SEPOLL |
| 168 | OPT_OBJS += src/ev_sepoll.o |
| 169 | endif |
| 170 | |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 171 | ifneq ($(USE_MY_EPOLL),) |
| 172 | OPTIONS += -DUSE_MY_EPOLL |
| 173 | endif |
| 174 | |
| 175 | ifneq ($(USE_NETFILTER),) |
| 176 | OPTIONS += -DNETFILTER |
| 177 | endif |
| 178 | |
| 179 | ifneq ($(USE_EPOLL_WORKAROUND),) |
| 180 | OPTIONS += -DEPOLL_CTL_MOD_WORKAROUND |
| 181 | endif |
| 182 | |
| 183 | ifneq ($(USE_GETSOCKNAME),) |
| 184 | OPTIONS += -DUSE_GETSOCKNAME |
| 185 | endif |
| 186 | |
| 187 | ifneq ($(USE_REGPARM),) |
| 188 | OPTIONS += -DCONFIG_HAP_USE_REGPARM |
| 189 | endif |
| 190 | |
Willy Tarreau | f2ef8c5 | 2007-07-11 09:19:31 +0200 | [diff] [blame] | 191 | ifneq ($(DLMALLOC_SRC),) |
| 192 | # May be changed to patch PAGE_SIZE on every platform |
| 193 | DLMALLOC_THRES=4096 |
| 194 | OPT_OBJS += src/dlmalloc.o |
| 195 | endif |
| 196 | |
Willy Tarreau | 79b34bf | 2006-12-22 15:28:43 +0100 | [diff] [blame] | 197 | ifneq ($(VERSION),) |
| 198 | OPTIONS += -DCONFIG_HAPROXY_VERSION=\"$(VERSION)$(SUBVERS)\" |
| 199 | endif |
| 200 | |
| 201 | ifneq ($(VERDATE),) |
| 202 | OPTIONS += -DCONFIG_HAPROXY_DATE=\"$(VERDATE)\" |
| 203 | endif |
| 204 | |
Willy Tarreau | 77074d5 | 2006-11-12 23:57:19 +0100 | [diff] [blame] | 205 | #### end of build options |
| 206 | |
| 207 | |
willy tarreau | eedaa9f | 2005-12-17 14:08:03 +0100 | [diff] [blame] | 208 | # global options |
| 209 | TARGET_OPTS=$(COPTS.$(TARGET)) |
| 210 | REGEX_OPTS=$(COPTS.$(REGEX)) |
| 211 | CPU_OPTS=$(COPTS.$(CPU)) |
| 212 | |
Willy Tarreau | 6d1a988 | 2007-01-07 02:03:04 +0100 | [diff] [blame] | 213 | COPTS = -Iinclude $(CPU_OPTS) $(TARGET_OPTS) $(REGEX_OPTS) $(SMALL_OPTS) $(DEFINE) $(OPTIONS) |
| 214 | LIBS=$(LIBS.$(TARGET)) $(LIBS.$(REGEX)) |
| 215 | |
| 216 | ifneq ($(USE_TCPSPLICE),) |
| 217 | COPTS += -I$(TCPSPLICEDIR) |
| 218 | LIBS += -L$(TCPSPLICEDIR) -ltcpsplice |
| 219 | endif |
| 220 | |
| 221 | COPTS += $(ADDINC) |
| 222 | LIBS += $(ADDLIB) |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 223 | |
willy tarreau | d38e72d | 2006-03-19 20:56:52 +0100 | [diff] [blame] | 224 | CFLAGS = -Wall $(COPTS) $(DEBUG) |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 225 | LDFLAGS = -g |
| 226 | |
| 227 | all: haproxy |
| 228 | |
Willy Tarreau | dd81598 | 2007-10-16 12:25:14 +0200 | [diff] [blame^] | 229 | OBJS = src/haproxy.o src/sessionhash.o src/base64.o src/protocols.o \ |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 230 | src/uri_auth.o src/standard.o src/buffers.o src/log.o src/task.o \ |
| 231 | src/time.o src/fd.o src/regex.o src/cfgparse.o src/server.o \ |
Willy Tarreau | 086b3b4 | 2007-05-13 21:45:51 +0200 | [diff] [blame] | 232 | src/checks.o src/queue.o src/client.o src/proxy.o \ |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 233 | src/proto_http.o src/stream_sock.o src/appsession.o src/backend.o \ |
Willy Tarreau | 50e608d | 2007-05-13 18:26:08 +0200 | [diff] [blame] | 234 | src/session.o src/hdr_idx.o src/ev_select.o src/acl.o src/memory.o |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 235 | |
Willy Tarreau | b38651a | 2007-03-24 17:24:39 +0100 | [diff] [blame] | 236 | haproxy: $(OBJS) $(OPT_OBJS) |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 237 | $(LD) $(LDFLAGS) -o $@ $^ $(LIBS) |
| 238 | |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 239 | objsize: haproxy |
| 240 | @objdump -t $^|grep ' g '|grep -F '.text'|awk '{print $$5 FS $$6}'|sort |
| 241 | |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 242 | %.o: %.c |
| 243 | $(CC) $(CFLAGS) -c -o $@ $< |
| 244 | |
Willy Tarreau | f2ef8c5 | 2007-07-11 09:19:31 +0200 | [diff] [blame] | 245 | src/dlmalloc.o: $(DLMALLOC_SRC) |
| 246 | $(CC) $(CFLAGS) -DDEFAULT_MMAP_THRESHOLD=$(DLMALLOC_THRES) -c -o $@ $< |
| 247 | |
willy tarreau | 0f7af91 | 2005-12-17 12:21:26 +0100 | [diff] [blame] | 248 | clean: |
Willy Tarreau | 1a58749 | 2006-10-15 23:40:58 +0200 | [diff] [blame] | 249 | rm -f *.[oas] src/*.[oas] core haproxy test |
| 250 | for dir in . src include/* doc; do rm -f $$dir/*~ $$dir/*.rej;done |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 251 | rm -f haproxy-$(VERSION).tar.gz haproxy-$(VERSION)$(SUBVERS).tar.gz |
| 252 | rm -f haproxy-$(VERSION) nohup.out gmon.out |
willy tarreau | efae184 | 2005-12-17 12:51:03 +0100 | [diff] [blame] | 253 | |
willy tarreau | e114bf9 | 2006-03-19 21:30:14 +0100 | [diff] [blame] | 254 | tar: clean |
willy tarreau | cee272f | 2006-03-19 21:16:26 +0100 | [diff] [blame] | 255 | ln -s . haproxy-$(VERSION) |
Willy Tarreau | baaee00 | 2006-06-26 02:48:02 +0200 | [diff] [blame] | 256 | tar --exclude=haproxy-$(VERSION)/.git \ |
| 257 | --exclude=haproxy-$(VERSION)/haproxy-$(VERSION) \ |
| 258 | --exclude=haproxy-$(VERSION)/haproxy-$(VERSION).tar.gz \ |
| 259 | -cf - haproxy-$(VERSION)/* | gzip -c9 >haproxy-$(VERSION).tar.gz |
willy tarreau | cee272f | 2006-03-19 21:16:26 +0100 | [diff] [blame] | 260 | rm -f haproxy-$(VERSION) |
| 261 | |
Willy Tarreau | 9f0a901 | 2006-10-15 14:24:14 +0200 | [diff] [blame] | 262 | git-tar: clean |
Willy Tarreau | 9bf6c6e | 2006-12-23 11:12:04 +0100 | [diff] [blame] | 263 | git-tar-tree HEAD haproxy-$(VERSION) | gzip -9 > haproxy-$(VERSION)$(SUBVERS).tar.gz |
Willy Tarreau | ec69256 | 2007-09-09 23:31:11 +0200 | [diff] [blame] | 264 | |
| 265 | version: |
| 266 | @echo "VERSION: $(VERSION)" |
| 267 | @echo "SUBVERS: $(SUBVERS)" |
| 268 | @echo "VERDATE: $(VERDATE)" |
| 269 | |
| 270 | # never use this one if you don't know what it is used for. |
| 271 | update-version: |
| 272 | @echo "Ready to update the following versions :" |
| 273 | @echo "VERSION: $(VERSION)" |
| 274 | @echo "SUBVERS: $(SUBVERS)" |
| 275 | @echo "VERDATE: $(VERDATE)" |
| 276 | @echo "Press [ENTER] to continue or Ctrl-C to abort now.";read |
| 277 | echo "$(VERSION)" > VERSION |
| 278 | echo "$(SUBVERS)" > SUBVERS |
| 279 | echo "$(VERDATE)" > VERDATE |