Resync
[CMakeLuaTailorHgBridge.git] / CMakeLua / Utilities / cmcurl-7.19.0 / packages / DOS / common.dj
blobd81de29184486689eed57b00af874d098ffd836b
2 # Common defines for curl (djgpp/Watt-32)
4 # Assumes you've unpacked cURL with short-file names
5 # I.e use "set LFN=n" before untaring on Win9x/XP.
6 # Requires sed, yacc, rm and the usual stuff.
8 # Define TOPDIR before including this file.
10 .SUFFIXES: .exe .y
12 MAKEFILE = Makefile.dj
13 OBJ_DIR = djgpp
16 # OpenSSL is available from www.openssl.org and builds okay
17 # with djgpp/Watt-32. Set to 0 if you don't need https URLs
18 # (reduces curl.exe with approx 700 kB)
20 USE_SSL = 0
23 # Use zlib for contents encoding
25 USE_ZLIB = 0
28 # Use libidn for international domain names
30 USE_IDNA = 0
33 # Use Watt-32 IPv6 stack (only IPv6 name resolution working at the moment)
35 USE_IPV6 = 0
38 # Use C-Ares resolver library
39 # This conflicts with USE_IPV6=1
41 USE_ARES = 0
44 # Enable debug code in libcurl/curl
46 USE_DEBUG = 0
48 default: all
51 # Root directory for Waterloo tcp/ip etc. Change to suite.
52 # WATT_ROOT should be set during Watt-32 install.
54 WATT32_ROOT  = $(subst \,/,$(WATT_ROOT))
55 OPENSSL_ROOT = e:/net/openssl.099
56 ZLIB_ROOT    = $(DJDIR)/contrib/zlib
57 LIBIDN_ROOT  = $(TOPDIR)/../IDN/libidn
58 ARES_ROOT    = $(TOPDIR)/ares
60 CC   = gcc
61 YACC = bison -y
63 CFLAGS = -g -gcoff -O2 -I. -I$(TOPDIR)/include -I$(TOPDIR)/lib \
64          -I$(WATT32_ROOT)/inc -Wall -DHAVE_CONFIG_H
66 ifeq ($(USE_SSL),1)
67   CFLAGS += -DUSE_SSLEAY -DUSE_OPENSSL -I$(OPENSSL_ROOT)
68 endif
70 ifeq ($(USE_ZLIB),1)
71   CFLAGS += -DUSE_ZLIB -I$(ZLIB_ROOT)
72 endif
74 ifeq ($(USE_IPV6),1)
75   CFLAGS += -DENABLE_IPV6
76 endif
78 ifeq ($(USE_ARES),1)
79   CFLAGS += -DUSE_ARES -I$(ARES_ROOT)
80 endif
82 ifeq ($(USE_IDNA),1)
83   CFLAGS += -DHAVE_LIBIDN -DHAVE_IDN_FREE_H -DHAVE_IDN_FREE -DHAVE_TLD_H \
84             -DHAVE_TLD_STRERROR -I$(LIBIDN_ROOT)/lib
85 endif
87 ifeq ($(USE_DEBUG),1)
88   CFLAGS += -DDEBUG=1 -DCURLDEBUG # -DDPRINTF_DEBUG2=1
89 endif
91 $(OBJ_DIR):
92         mkdir $(OBJ_DIR)
94 $(OBJ_DIR)/%.o: %.c
95         $(CC) $(CFLAGS) -o $@ -c $<
96         @echo
98 depend: $(DEPEND_PREREQ) $(MAKEFILE)
99         $(CC) -MM $(CFLAGS) $(CSOURCES) | \
100         sed -e 's/^\([a-zA-Z0-9_-]*\.o:\)/$$(OBJ_DIR)\/\1/' > depend.dj