Makefile.netware 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429
  1. #################################################################
  2. # $Id$
  3. #
  4. ## Makefile for building libcares (NetWare version - gnu make)
  5. ## Use: make -f Makefile.netware
  6. ##
  7. ## Comments to: Guenter Knauf http://www.gknw.de/phpbb
  8. #
  9. #################################################################
  10. # Edit the path below to point to the base of your Novell NDK.
  11. ifndef NDKBASE
  12. NDKBASE = c:/novell
  13. endif
  14. ifndef INSTDIR
  15. INSTDIR = ../ares-$(LIBCARES_VERSION_STR)-bin-nw
  16. endif
  17. # Edit the vars below to change NLM target settings.
  18. TARGETS = adig.nlm ahost.nlm acountry.nlm
  19. LTARGET = libcares.$(LIBEXT)
  20. VERSION = $(LIBCARES_VERSION)
  21. COPYR = Copyright (C) 1996 - 2008, Daniel Stenberg, <daniel@haxx.se>
  22. DESCR = cURL $(subst .def,,$(notdir $@)) $(LIBCARES_VERSION_STR) - http://curl.haxx.se
  23. MTSAFE = YES
  24. STACK = 64000
  25. SCREEN = none
  26. #EXPORTS =
  27. # Comment the line below if you dont want to load protected automatically.
  28. #LDRING = 3
  29. # Edit the var below to point to your lib architecture.
  30. ifndef LIBARCH
  31. LIBARCH = LIBC
  32. endif
  33. # must be equal to NDEBUG or DEBUG, CURLDEBUG
  34. ifndef DB
  35. DB = NDEBUG
  36. endif
  37. # Optimization: -O<n> or debugging: -g
  38. ifeq ($(DB),NDEBUG)
  39. OPT = -O2
  40. OBJDIR = release
  41. else
  42. OPT = -g
  43. OBJDIR = debug
  44. endif
  45. # Include the version info retrieved from curlver.h
  46. -include $(OBJDIR)/version.inc
  47. # The following lines defines your compiler.
  48. ifdef CWFolder
  49. METROWERKS = $(CWFolder)
  50. endif
  51. ifdef METROWERKS
  52. # MWCW_PATH = $(subst \,/,$(METROWERKS))/Novell Support
  53. MWCW_PATH = $(subst \,/,$(METROWERKS))/Novell Support/Metrowerks Support
  54. CC = mwccnlm
  55. else
  56. CC = gcc
  57. endif
  58. # a native win32 awk can be downloaded from here:
  59. # http://www.gknw.net/development/prgtools/awk-20070501.zip
  60. AWK = awk
  61. YACC = bison -y
  62. CP = cp -afv
  63. MKDIR = mkdir
  64. # RM = rm -f
  65. # if you want to mark the target as MTSAFE you will need a tool for
  66. # generating the xdc data for the linker; here's a minimal tool:
  67. # http://www.gknw.net/development/prgtools/mkxdc.zip
  68. MPKXDC = mkxdc
  69. # Global flags for all compilers
  70. CFLAGS += $(OPT) -D$(DB) -DNETWARE -DHAVE_CONFIG_H -nostdinc
  71. ifeq ($(CC),mwccnlm)
  72. LD = mwldnlm
  73. LDFLAGS = -nostdlib $(PRELUDE) $(OBJEXE) $(<:.def=.o) -o $@ -commandfile
  74. AR = mwldnlm
  75. ARFLAGS = -nostdlib -type library -o
  76. LIBEXT = lib
  77. #RANLIB =
  78. CFLAGS += -msgstyle gcc -gccinc -inline off -opt nointrinsics -proc 586
  79. CFLAGS += -relax_pointers
  80. #CFLAGS += -w on
  81. ifeq ($(LIBARCH),LIBC)
  82. PRELUDE = $(SDK_LIBC)/imports/libcpre.o
  83. CFLAGS += -align 4
  84. else
  85. # PRELUDE = $(SDK_CLIB)/imports/clibpre.o
  86. # to avoid the __init_* / __deinit_* whoes dont use prelude from NDK
  87. PRELUDE = "$(MWCW_PATH)/libraries/runtime/prelude.obj"
  88. # CFLAGS += -include "$(MWCW_PATH)/headers/nlm_clib_prefix.h"
  89. CFLAGS += -align 1
  90. endif
  91. else
  92. LD = nlmconv
  93. LDFLAGS = -T
  94. AR = ar
  95. ARFLAGS = -cq
  96. LIBEXT = a
  97. RANLIB = ranlib
  98. CFLAGS += -fno-builtin -fpcc-struct-return -fno-strict-aliasing
  99. CFLAGS += -Wall -Wno-format -Wno-uninitialized # -pedantic
  100. ifeq ($(LIBARCH),LIBC)
  101. PRELUDE = $(SDK_LIBC)/imports/libcpre.gcc.o
  102. else
  103. # PRELUDE = $(SDK_CLIB)/imports/clibpre.gcc.o
  104. # to avoid the __init_* / __deinit_* whoes dont use prelude from NDK
  105. # http://www.gknw.net/development/mk_nlm/gcc_pre.zip
  106. PRELUDE = $(NDK_ROOT)/pre/prelude.o
  107. CFLAGS += -include $(NDKBASE)/nlmconv/genlm.h
  108. endif
  109. endif
  110. NDK_ROOT = $(NDKBASE)/ndk
  111. SDK_CLIB = $(NDK_ROOT)/nwsdk
  112. SDK_LIBC = $(NDK_ROOT)/libc
  113. ifeq ($(LIBARCH),LIBC)
  114. INCLUDES += -I$(SDK_LIBC)/include
  115. # INCLUDES += -I$(SDK_LIBC)/include/nks
  116. # INCLUDES += -I$(SDK_LIBC)/include/winsock
  117. CFLAGS += -D_POSIX_SOURCE
  118. else
  119. INCLUDES += -I$(SDK_CLIB)/include/nlm
  120. # INCLUDES += -I$(SDK_CLIB)/include/nlm/obsolete
  121. # INCLUDES += -I$(SDK_CLIB)/include
  122. endif
  123. ifeq ($(DB),CURLDEBUG)
  124. INCLUDES += -I../include
  125. endif
  126. CFLAGS += -I. $(INCLUDES)
  127. ifeq ($(MTSAFE),YES)
  128. XDCOPT = -n
  129. endif
  130. ifeq ($(MTSAFE),NO)
  131. XDCOPT = -u
  132. endif
  133. ifeq ($(findstring linux,$(OSTYPE)),linux)
  134. DL = '
  135. #-include $(NDKBASE)/nlmconv/ncpfs.inc
  136. endif
  137. # Makefile.inc provides the CSOURCES and HHEADERS defines
  138. include Makefile.inc
  139. OBJLIB := $(patsubst %.c,$(OBJDIR)/%.o,$(strip $(CSOURCES)))
  140. OBJEXE = $(OBJLIB) $(OBJDIR)/ares_getopt.o
  141. .PHONY: lib nlm prebuild dist install clean
  142. lib: prebuild $(LTARGET)
  143. nlm: prebuild $(TARGETS)
  144. prebuild: $(OBJDIR) ares_build.h $(OBJDIR)/version.inc config.h
  145. install: $(INSTDIR) all
  146. @$(CP) *.nlm $(INSTDIR)
  147. @$(CP) ../CHANGES $(INSTDIR)
  148. @$(CP) ../COPYING $(INSTDIR)
  149. @$(CP) ../README $(INSTDIR)
  150. @$(CP) ../RELEASE-NOTES $(INSTDIR)
  151. clean:
  152. -$(RM) $(LTARGET) $(TARGETS) config.h
  153. -$(RM) -r $(OBJDIR)
  154. -$(RM) -r arpa
  155. %.$(LIBEXT): $(OBJLIB)
  156. @echo Creating $@
  157. @-$(RM) $@
  158. @$(AR) $(ARFLAGS) $@ $^
  159. ifdef RANLIB
  160. @$(RANLIB) $@
  161. endif
  162. %.nlm: $(OBJDIR)/%.def $(OBJDIR)/%.o $(OBJDIR)/%.xdc $(OBJEXE)
  163. @echo Linking $@
  164. @-$(RM) $@
  165. @$(LD) $(LDFLAGS) $<
  166. $(OBJDIR) $(INSTDIR):
  167. @$(MKDIR) $@
  168. $(OBJDIR)/%.o: %.c
  169. # @echo Compiling $<
  170. $(CC) $(CFLAGS) -c $< -o $@
  171. $(OBJDIR)/version.inc: ares_version.h $(OBJDIR)
  172. @echo Creating $@
  173. @$(AWK) -f get_ver.awk $< > $@
  174. $(OBJDIR)/%.xdc: Makefile.netware
  175. @echo Creating $@
  176. @$(MPKXDC) $(XDCOPT) $@
  177. $(OBJDIR)/%.def: Makefile.netware
  178. @echo Creating $@
  179. @echo $(DL)# DEF file for linking with $(LD)$(DL) > $@
  180. @echo $(DL)# Do not edit this file - it is created by make!$(DL) >> $@
  181. @echo $(DL)# All your changes will be lost!!$(DL) >> $@
  182. @echo $(DL)#$(DL) >> $@
  183. @echo $(DL)copyright "$(COPYR)"$(DL) >> $@
  184. @echo $(DL)description "$(DESCR)"$(DL) >> $@
  185. @echo $(DL)version $(VERSION)$(DL) >> $@
  186. ifdef NLMTYPE
  187. @echo $(DL)type $(NLMTYPE)$(DL) >> $@
  188. endif
  189. ifdef STACK
  190. @echo $(DL)stack $(STACK)$(DL) >> $@
  191. endif
  192. ifdef SCREEN
  193. @echo $(DL)screenname "$(SCREEN)"$(DL) >> $@
  194. else
  195. @echo $(DL)screenname "DEFAULT"$(DL) >> $@
  196. endif
  197. ifeq ($(DB),DEBUG)
  198. @echo $(DL)debug$(DL) >> $@
  199. endif
  200. @echo $(DL)threadname "$^"$(DL) >> $@
  201. ifdef XDCOPT
  202. @echo $(DL)xdcdata $(@:.def=.xdc)$(DL) >> $@
  203. endif
  204. ifeq ($(LDRING),0)
  205. @echo $(DL)flag_on 16$(DL) >> $@
  206. endif
  207. ifeq ($(LDRING),3)
  208. @echo $(DL)flag_on 512$(DL) >> $@
  209. endif
  210. ifeq ($(LIBARCH),CLIB)
  211. @echo $(DL)start _Prelude$(DL) >> $@
  212. @echo $(DL)exit _Stop$(DL) >> $@
  213. @echo $(DL)import @$(SDK_CLIB)/imports/clib.imp$(DL) >> $@
  214. @echo $(DL)import @$(SDK_CLIB)/imports/threads.imp$(DL) >> $@
  215. @echo $(DL)import @$(SDK_CLIB)/imports/nlmlib.imp$(DL) >> $@
  216. @echo $(DL)import @$(SDK_CLIB)/imports/socklib.imp$(DL) >> $@
  217. @echo $(DL)module clib$(DL) >> $@
  218. else
  219. @echo $(DL)flag_on 64$(DL) >> $@
  220. @echo $(DL)pseudopreemption$(DL) >> $@
  221. @echo $(DL)start _LibCPrelude$(DL) >> $@
  222. @echo $(DL)exit _LibCPostlude$(DL) >> $@
  223. @echo $(DL)check _LibCCheckUnload$(DL) >> $@
  224. @echo $(DL)import @$(SDK_LIBC)/imports/libc.imp$(DL) >> $@
  225. @echo $(DL)import @$(SDK_LIBC)/imports/netware.imp$(DL) >> $@
  226. @echo $(DL)module libc$(DL) >> $@
  227. endif
  228. ifdef MODULES
  229. @echo $(DL)module $(MODULES)$(DL) >> $@
  230. endif
  231. ifdef EXPORTS
  232. @echo $(DL)export $(EXPORTS)$(DL) >> $@
  233. endif
  234. ifdef IMPORTS
  235. @echo $(DL)import $(IMPORTS)$(DL) >> $@
  236. endif
  237. ifeq ($(LD),nlmconv)
  238. @echo $(DL)input $(PRELUDE)$(DL) >> $@
  239. @echo $(DL)input $(OBJEXE)$(DL) >> $@
  240. @echo $(DL)input $(@:.def=.o)$(DL) >> $@
  241. @echo $(DL)output $(notdir $(@:.def=.nlm))$(DL) >> $@
  242. endif
  243. config.h: Makefile.netware
  244. @echo Creating $@
  245. @echo $(DL)/* $@ for NetWare target.$(DL) > $@
  246. @echo $(DL)** Do not edit this file - it is created by make!$(DL) >> $@
  247. @echo $(DL)** All your changes will be lost!!$(DL) >> $@
  248. @echo $(DL)*/$(DL) >> $@
  249. @echo $(DL)#ifndef NETWARE$(DL) >> $@
  250. @echo $(DL)#error This $(notdir $@) is created for NetWare platform!$(DL) >> $@
  251. @echo $(DL)#endif$(DL) >> $@
  252. @echo $(DL)#define VERSION "$(LIBCARES_VERSION_STR)"$(DL) >> $@
  253. @echo $(DL)#define PACKAGE_BUGREPORT "a suitable curl mailing list => http://curl.haxx.se/mail/"$(DL) >> $@
  254. ifeq ($(LIBARCH),CLIB)
  255. @echo $(DL)#define OS "i586-pc-clib-NetWare"$(DL) >> $@
  256. @echo $(DL)#define HAVE_STRICMP 1$(DL) >> $@
  257. @echo $(DL)#define HAVE_STRNICMP 1$(DL) >> $@
  258. @echo $(DL)#define NETDB_USE_INTERNET 1$(DL) >> $@
  259. @echo $(DL)#define RECV_TYPE_ARG1 int$(DL) >> $@
  260. @echo $(DL)#define RECV_TYPE_ARG2 char *$(DL) >> $@
  261. @echo $(DL)#define RECV_TYPE_ARG3 int$(DL) >> $@
  262. @echo $(DL)#define RECV_TYPE_ARG4 int$(DL) >> $@
  263. @echo $(DL)#define RECV_TYPE_RETV int$(DL) >> $@
  264. @echo $(DL)#define RECVFROM_TYPE_ARG1 int$(DL) >> $@
  265. @echo $(DL)#define RECVFROM_TYPE_ARG2 char$(DL) >> $@
  266. @echo $(DL)#define RECVFROM_TYPE_ARG3 int$(DL) >> $@
  267. @echo $(DL)#define RECVFROM_TYPE_ARG4 int$(DL) >> $@
  268. @echo $(DL)#define RECVFROM_TYPE_ARG5 struct sockaddr$(DL) >> $@
  269. @echo $(DL)#define RECVFROM_TYPE_ARG6 int$(DL) >> $@
  270. @echo $(DL)#define RECVFROM_TYPE_RETV int$(DL) >> $@
  271. @echo $(DL)#define SEND_QUAL_ARG2$(DL) >> $@
  272. @echo $(DL)#define SEND_TYPE_ARG1 int$(DL) >> $@
  273. @echo $(DL)#define SEND_TYPE_ARG2 char *$(DL) >> $@
  274. @echo $(DL)#define SEND_TYPE_ARG3 int$(DL) >> $@
  275. @echo $(DL)#define SEND_TYPE_ARG4 int$(DL) >> $@
  276. @echo $(DL)#define SEND_TYPE_RETV int$(DL) >> $@
  277. else
  278. @echo $(DL)#define OS "i586-pc-libc-NetWare"$(DL) >> $@
  279. @echo $(DL)#define HAVE_DLFCN_H 1$(DL) >> $@
  280. @echo $(DL)#define HAVE_DLOPEN 1$(DL) >> $@
  281. @echo $(DL)#define HAVE_FTRUNCATE 1$(DL) >> $@
  282. @echo $(DL)#define HAVE_GETTIMEOFDAY 1$(DL) >> $@
  283. @echo $(DL)#define HAVE_INTTYPES_H 1$(DL) >> $@
  284. @echo $(DL)#define HAVE_LONGLONG 1$(DL) >> $@
  285. @echo $(DL)#define HAVE_STDINT_H 1$(DL) >> $@
  286. @echo $(DL)#define HAVE_STRCASECMP 1$(DL) >> $@
  287. @echo $(DL)#define HAVE_STRLCAT 1$(DL) >> $@
  288. @echo $(DL)#define HAVE_STRLCPY 1$(DL) >> $@
  289. @echo $(DL)#define HAVE_STRTOLL 1$(DL) >> $@
  290. @echo $(DL)#define HAVE_SYS_PARAM_H 1$(DL) >> $@
  291. @echo $(DL)#define HAVE_SYS_SELECT_H 1$(DL) >> $@
  292. @echo $(DL)#define HAVE_TERMIOS_H 1$(DL) >> $@
  293. @echo $(DL)#define HAVE_AF_INET6 1$(DL) >> $@
  294. @echo $(DL)#define HAVE_PF_INET6 1$(DL) >> $@
  295. @echo $(DL)#define HAVE_FREEADDRINFO 1$(DL) >> $@
  296. @echo $(DL)#define HAVE_GETADDRINFO 1$(DL) >> $@
  297. @echo $(DL)#define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1$(DL) >> $@
  298. @echo $(DL)#define HAVE_STRUCT_IN6_ADDR 1$(DL) >> $@
  299. @echo $(DL)#define HAVE_STRUCT_SOCKADDR_IN6 1$(DL) >> $@
  300. @echo $(DL)#define RECV_TYPE_ARG1 int$(DL) >> $@
  301. @echo $(DL)#define RECV_TYPE_ARG2 void *$(DL) >> $@
  302. @echo $(DL)#define RECV_TYPE_ARG3 size_t$(DL) >> $@
  303. @echo $(DL)#define RECV_TYPE_ARG4 int$(DL) >> $@
  304. @echo $(DL)#define RECV_TYPE_RETV ssize_t$(DL) >> $@
  305. @echo $(DL)#define RECVFROM_TYPE_ARG1 int$(DL) >> $@
  306. @echo $(DL)#define RECVFROM_TYPE_ARG2 void$(DL) >> $@
  307. @echo $(DL)#define RECVFROM_TYPE_ARG3 size_t$(DL) >> $@
  308. @echo $(DL)#define RECVFROM_TYPE_ARG4 int$(DL) >> $@
  309. @echo $(DL)#define RECVFROM_TYPE_ARG5 struct sockaddr$(DL) >> $@
  310. @echo $(DL)#define RECVFROM_TYPE_ARG6 size_t$(DL) >> $@
  311. @echo $(DL)#define RECVFROM_TYPE_RETV ssize_t$(DL) >> $@
  312. @echo $(DL)#define RECVFROM_TYPE_ARG2_IS_VOID 1$(DL) >> $@
  313. @echo $(DL)#define SEND_QUAL_ARG2$(DL) >> $@
  314. @echo $(DL)#define SEND_TYPE_ARG1 int$(DL) >> $@
  315. @echo $(DL)#define SEND_TYPE_ARG2 void *$(DL) >> $@
  316. @echo $(DL)#define SEND_TYPE_ARG3 size_t$(DL) >> $@
  317. @echo $(DL)#define SEND_TYPE_ARG4 int$(DL) >> $@
  318. @echo $(DL)#define SEND_TYPE_RETV ssize_t$(DL) >> $@
  319. @echo $(DL)#define SIZEOF_STRUCT_IN6_ADDR 16$(DL) >> $@
  320. endif
  321. @echo $(DL)#define HAVE_ARPA_INET_H 1$(DL) >> $@
  322. @echo $(DL)#define HAVE_ASSERT_H 1$(DL) >> $@
  323. @echo $(DL)#define HAVE_ERR_H 1$(DL) >> $@
  324. @echo $(DL)#define HAVE_FCNTL_H 1$(DL) >> $@
  325. @echo $(DL)#define HAVE_GETHOSTBYADDR 1$(DL) >> $@
  326. @echo $(DL)#define HAVE_GETHOSTBYNAME 1$(DL) >> $@
  327. @echo $(DL)#define HAVE_GETHOSTNAME 1$(DL) >> $@
  328. @echo $(DL)#define HAVE_GETPROTOBYNAME 1$(DL) >> $@
  329. @echo $(DL)#define HAVE_GMTIME_R 1$(DL) >> $@
  330. @echo $(DL)#define HAVE_INET_ADDR 1$(DL) >> $@
  331. @echo $(DL)#define HAVE_IOCTL 1$(DL) >> $@
  332. @echo $(DL)#define HAVE_IOCTL_FIONBIO 1$(DL) >> $@
  333. @echo $(DL)#define HAVE_LIMITS_H 1$(DL) >> $@
  334. @echo $(DL)#define HAVE_LL 1$(DL) >> $@
  335. @echo $(DL)#define HAVE_LOCALTIME_R 1$(DL) >> $@
  336. @echo $(DL)#define HAVE_MALLOC_H 1$(DL) >> $@
  337. @echo $(DL)#define HAVE_NETINET_IN_H 1$(DL) >> $@
  338. @echo $(DL)#define HAVE_RECV 1$(DL) >> $@
  339. @echo $(DL)#define HAVE_RECVFROM 1$(DL) >> $@
  340. @echo $(DL)#define HAVE_SELECT 1$(DL) >> $@
  341. @echo $(DL)#define HAVE_SEND 1$(DL) >> $@
  342. @echo $(DL)#define HAVE_SETJMP_H 1$(DL) >> $@
  343. @echo $(DL)#define HAVE_SIGNAL 1$(DL) >> $@
  344. @echo $(DL)#define HAVE_SIGNAL_H 1$(DL) >> $@
  345. @echo $(DL)#define HAVE_SIG_ATOMIC_T 1$(DL) >> $@
  346. @echo $(DL)#define HAVE_SOCKET 1$(DL) >> $@
  347. @echo $(DL)#define HAVE_STDLIB_H 1$(DL) >> $@
  348. @echo $(DL)#define HAVE_STRDUP 1$(DL) >> $@
  349. @echo $(DL)#define HAVE_STRFTIME 1$(DL) >> $@
  350. @echo $(DL)#define HAVE_STRING_H 1$(DL) >> $@
  351. @echo $(DL)#define HAVE_STRSTR 1$(DL) >> $@
  352. @echo $(DL)#define HAVE_STRUCT_ADDRINFO 1$(DL) >> $@
  353. @echo $(DL)#define HAVE_STRUCT_TIMEVAL 1$(DL) >> $@
  354. @echo $(DL)#define HAVE_SYS_IOCTL_H 1$(DL) >> $@
  355. @echo $(DL)#define HAVE_SYS_STAT_H 1$(DL) >> $@
  356. @echo $(DL)#define HAVE_SYS_TIME_H 1$(DL) >> $@
  357. @echo $(DL)#define HAVE_TIME_H 1$(DL) >> $@
  358. @echo $(DL)#define HAVE_UNAME 1$(DL) >> $@
  359. @echo $(DL)#define HAVE_UNISTD_H 1$(DL) >> $@
  360. @echo $(DL)#define HAVE_UTIME 1$(DL) >> $@
  361. @echo $(DL)#define HAVE_UTIME_H 1$(DL) >> $@
  362. @echo $(DL)#define HAVE_WRITEV 1$(DL) >> $@
  363. @echo $(DL)#define RETSIGTYPE void$(DL) >> $@
  364. @echo $(DL)#define SIZEOF_STRUCT_IN_ADDR 4$(DL) >> $@
  365. @echo $(DL)#define STDC_HEADERS 1$(DL) >> $@
  366. @echo $(DL)#define TIME_WITH_SYS_TIME 1$(DL) >> $@
  367. ifdef NW_WINSOCK
  368. @echo $(DL)#define HAVE_CLOSESOCKET 1$(DL) >> $@
  369. else
  370. @echo $(DL)#define HAVE_SYS_TYPES_H 1$(DL) >> $@
  371. @echo $(DL)#define HAVE_SYS_SOCKET_H 1$(DL) >> $@
  372. @echo $(DL)#define HAVE_SYS_SOCKIO_H 1$(DL) >> $@
  373. @echo $(DL)#define HAVE_NETDB_H 1$(DL) >> $@
  374. endif
  375. @echo $(DL)#ifdef __GNUC__$(DL) >> $@
  376. @echo $(DL)#define HAVE_VARIADIC_MACROS_GCC 1$(DL) >> $@
  377. @echo $(DL)#else$(DL) >> $@
  378. @echo $(DL)#define HAVE_VARIADIC_MACROS_C99 1$(DL) >> $@
  379. @echo $(DL)#endif$(DL) >> $@
  380. FORCE: ;
  381. ares_build.h: Makefile.netware FORCE
  382. @echo Creating $@
  383. @echo $(DL)/* $@ intended for NetWare target.$(DL) > $@
  384. @echo $(DL)** Do not edit this file - it is created by make!$(DL) >> $@
  385. @echo $(DL)** All your changes will be lost!!$(DL) >> $@
  386. @echo $(DL)*/$(DL) >> $@
  387. @echo $(DL)#ifndef __CARES_BUILD_H$(DL) >> $@
  388. @echo $(DL)#define __CARES_BUILD_H$(DL) >> $@
  389. ifeq ($(LIBARCH),CLIB)
  390. @echo $(DL)#define CARES_TYPEOF_ARES_SOCKLEN_T int$(DL) >> $@
  391. @echo $(DL)#define CARES_SIZEOF_ARES_SOCKLEN_T 4$(DL) >> $@
  392. else
  393. @echo $(DL)#define CARES_TYPEOF_ARES_SOCKLEN_T unsigned int$(DL) >> $@
  394. @echo $(DL)#define CARES_SIZEOF_ARES_SOCKLEN_T 4$(DL) >> $@
  395. endif
  396. @echo $(DL)#define CARES_SIZEOF_LONG 4$(DL) >> $@
  397. @echo $(DL)typedef CARES_TYPEOF_ARES_SOCKLEN_T ares_socklen_t;$(DL) >> $@
  398. @echo $(DL)#endif /* __CARES_BUILD_H */$(DL) >> $@