modified: pixi.toml
[GalaxyCodeBases.git] / etc / Windows / vlmcsd_old_vancepym / GNUmakefile
blobd98cadf4194b09e40e5ddd655113446bc8589258
1 ################################################################################
3 .PHONY: clean
5 PROGRAM_NAME ?= vlmcsd
6 CLIENT_NAME ?= vlmcs
7 MULTI_NAME ?= vlmcsdmulti
8 CONFIG ?= config.h
10 # crypto library to use for standard algos, could save ~1-2kb ;)
11 # can be either 'openssl', 'polarssl' or anything other for internal impl
12 CRYPTO ?= internal
14 # use DNS_PARSER=internal if your OS doesn't supply the DNS parser routines
15 DNS_PARSER ?= OS
17 # You should supply your own version string here
19 VLMCSD_VERSION ?= $(shell test -d .svn && echo svn`svnversion`)
21 FEATURES ?= full
22 VERBOSE ?= NO
24 ################################################################################
26 CC ?= gcc
27 TARGETPLATFORM := $(shell LANG=en_US.UTF-8 $(CC) -v 2>&1 | grep '^Target: ' | cut -f 2 -d ' ')
29 ifneq (,$(findstring darwin,$(TARGETPLATFORM)))
30 DARWIN := 1
31 UNIX := 1
32 endif
34 ifneq (,$(findstring androideabi,$(TARGETPLATFORM)))
35 ANDROID := 1
36 UNIX := 1
37 endif
39 ifneq (,$(findstring minix,$(TARGETPLATFORM)))
40 MINIX := 1
41 UNIX := 1
42 endif
44 ifneq (,$(findstring mingw,$(TARGETPLATFORM)))
45 MINGW := 1
46 WIN := 1
47 endif
49 ifneq (,$(findstring cygwin,$(TARGETPLATFORM)))
50 CYGWIN := 1
51 WIN := 1
52 endif
54 ifneq (,$(findstring freebsd,$(TARGETPLATFORM)))
55 FREEBSD := 1
56 UNIX := 1
57 BSD := 1
58 endif
60 ifneq (,$(findstring netbsd,$(TARGETPLATFORM)))
61 NETBSD := 1
62 UNIX := 1
63 BSD := 1
64 endif
66 ifneq (,$(findstring openbsd,$(TARGETPLATFORM)))
67 OPENBSD := 1
68 UNIX := 1
69 BSD := 1
70 endif
72 ifneq (,$(findstring solaris,$(TARGETPLATFORM)))
73 SOLARIS := 1
74 UNIX := 1
75 endif
77 ifneq (,$(findstring linux,$(TARGETPLATFORM)))
78 LINUX := 1
79 UNIX := 1
80 endif
82 ifeq ($(CYGWIN),1)
83 DLL_NAME ?= cygkms.dll
84 else ifeq ($(WIN),1)
85 DLL_NAME ?= libkms.dll
86 else ifeq ($(DARWIN),1)
87 DLL_NAME ?= libkms.dylib
88 else
89 DLL_NAME ?= libkms.so
90 endif
92 BASECFLAGS = -DCONFIG=\"$(CONFIG)\" -DBUILD_TIME=$(shell date '+%s') -g -Os -fno-strict-aliasing -fomit-frame-pointer -ffunction-sections -fdata-sections
93 BASELDFLAGS =
94 STRIPFLAGS =
95 CLIENTLDFLAGS =
96 SERVERLDFLAGS =
98 ifeq ($(NOLIBS),1)
99 NOLRESOLV=1
100 NOLPTHREAD=1
101 endif
103 ifneq ($(NO_DNS),1)
104 ifneq ($(ANDROID),1)
105 ifneq ($(NOLRESOLV),1)
107 ifeq ($(MINGW),1)
108 BASELDFLAGS += -ldnsapi
109 endif
111 ifeq ($(LINUX),1)
112 BASELDFLAGS += -lresolv
113 endif
115 ifeq ($(DARWIN),1)
116 BASELDFLAGS += -lresolv
117 endif
119 ifeq ($(CYGWIN),1)
120 DNS_PARSER := internal
121 BASELDFLAGS += -lresolv
122 endif
124 ifeq ($(OPENBSD),1)
125 DNS_PARSER := internal
126 endif
128 ifeq ($(SOLARIS),1)
129 BASELDFLAGS += -lresolv
130 endif
132 endif
133 endif
134 else
135 BASECFLAGS += -DNO_DNS
136 endif
138 ifneq ($(CAT),2)
139 BASECFLAGS += "-Wall"
140 endif
142 ifeq ($(DARWIN), 1)
143 STRIPFLAGS += -Wl,-S -Wl,-x
144 BASECFLAGS += -Wno-deprecated-declarations
145 else ifeq ($(shell uname), SunOS)
146 STRIPFLAGS += -s
147 ifeq ($(notdir $(LD_ALTEXEC)),gld)
148 BASELDFLAGS += -Wl,--gc-sections
149 endif
150 BASELDFLAGS += -lsocket
151 else
152 ifneq ($(CC),tcc)
153 BASELDFLAGS += -Wl,--gc-sections
154 endif
155 STRIPFLAGS += -s
156 endif
158 ifeq ($(FEATURES), embedded)
159 BASECFLAGS += -DNO_HELP -DNO_USER_SWITCH -DNO_BASIC_PRODUCT_LIST -DNO_CUSTOM_INTERVALS -DNO_PID_FILE -DNO_VERBOSE_LOG
160 else ifeq ($(FEATURES), autostart)
161 BASECFLAGS += -DNO_HELP
162 else ifeq ($(FEATURES), minimum)
163 BASECFLAGS += -DNO_TIMEOUT -DNO_SIGHUP -DNO_CL_PIDS -DNO_EXTENDED_PRODUCT_LIST -DNO_BASIC_PRODUCT_LIST -DNO_LOG -DNO_RANDOM_EPID -DNO_INI_FILE -DNO_INI_FILE -DNO_HELP -DNO_CUSTOM_INTERVALS -DNO_PID_FILE -DNO_USER_SWITCH -DNO_VERBOSE_LOG -DNO_LIMIT
164 else ifeq ($(FEATURES), most)
165 BASECFLAGS += -DNO_SIGHUP -DNO_PID_FILE -DNO_LIMIT
166 else ifeq ($(FEATURES), inetd)
167 BASECFLAGS += -DNO_SIGHUP -DNO_SOCKETS -DNO_PID_FILE -DNO_LIMIT
168 else ifeq ($(FEATURES), fixedepids)
169 BASECFLAGS += -DNO_SIGHUP -DNO_CL_PIDS -DNO_RANDOM_EPID -DNO_INI_FILE
170 endif
172 ifdef INI
173 BASECFLAGS += -DINI_FILE=\"$(INI)\"
174 endif
176 ifeq ($(THREADS), 1)
177 BASECFLAGS += -DUSE_THREADS
178 endif
180 ifeq ($(CHILD_HANDLER), 1)
181 BASECFLAGS += -DCHILD_HANDLER
182 endif
184 ifeq ($(NO_TIMEOUT), 1)
185 BASECFLAGS += -DNO_TIMEOUT
186 endif
188 ifdef WINDOWS
189 BASECFLAGS += -DEPID_WINDOWS=\"$(WINDOWS)\"
190 endif
192 ifdef OFFICE2010
193 BASECFLAGS += -DEPID_OFFICE2010=\"$(OFFICE2010)\"
194 endif
196 ifdef OFFICE2013
197 BASECFLAGS += -DEPID_OFFICE2013=\"$(OFFICE2013)\"
198 endif
200 ifdef HWID
201 BASECFLAGS += -DHWID=$(HWID)
202 endif
204 ifdef TERMINAL_WIDTH
205 BASECFLAGS += -DTERMINAL_FIXED_WIDTH=$(TERMINAL_WIDTH)
206 endif
208 ifeq ($(NOPROCFS), 1)
209 BASECFLAGS += -DNO_PROCFS
210 endif
212 ifeq ($(AUXV), 1)
213 BASECFLAGS += -DUSE_AUXV
214 endif
216 ifneq ($(ANDROID), 1)
217 ifneq ($(MINIX), 1)
218 ifneq ($(NOLPTHREAD), 1)
219 ifeq ($(findstring NO_LIMIT,$(CFLAGS) $(BASECFLAGS)),)
220 BASELDFLAGS += -lpthread
221 endif
223 ifneq ($(findstring USE_THREADS,$(BASECFLAGS)),)
224 BASELDFLAGS += -lpthread
225 endif
226 endif
227 endif
228 endif
230 $(MULTI_NAME): BASECFLAGS += -DMULTI_CALL_BINARY=1
232 all: $(CLIENT_NAME) $(PROGRAM_NAME)
234 ifdef CAT
235 allmulti: $(CLIENT_NAME) $(PROGRAM_NAME) $(MULTI_NAME)
236 endif
238 ifneq ($(strip $(VLMCSD_VERSION)),)
239 BASECFLAGS += -DVERSION=\"$(VLMCSD_VERSION),\ built\ $(shell date -u '+%Y-%m-%d %H:%M:%S' | sed -e 's/ /\\ /g')\ UTC\"
240 endif
242 ifdef CAT
243 BASECFLAGS += -DONE_FILE
244 endif
246 SRCS = crypto.c kms.c endian.c output.c shared_globals.c helpers.c
247 HEADERS = $(CONFIG) types.h rpc.h vlmcsd.h endian.h crypto.h kms.h network.h output.h shared_globals.h vlmcs.h helpers.h
248 DEPS = $(MULTI_SRCS:.c=.d)
250 VLMCSD_SRCS = vlmcsd.c $(SRCS)
251 VLMCSD_OBJS = $(VLMCSD_SRCS:.c=.o)
253 VLMCS_SRCS = vlmcs.c $(SRCS)
254 VLMCS_OBJS = $(VLMCS_SRCS:.c=.o)
256 MULTI_SRCS = vlmcsd.c vlmcs.c vlmcsdmulti.c $(SRCS)
257 MULTI_OBJS = $(MULTI_SRCS:.c=.o)
259 DLL_SRCS = libkms.c $(SRCS)
260 DLL_OBJS = $(DLL_SRCS:.c=.o)
262 PDFDOCS = vlmcs.1.pdf vlmcsd.7.pdf vlmcsd.8.pdf vlmcsdmulti.1.pdf vlmcsd.ini.5.pdf
263 HTMLDOCS = $(PDFDOCS:.pdf=.html)
264 UNIXDOCS = $(PDFDOCS:.pdf=.unix.txt)
265 DOSDOCS = $(PDFDOCS:.pdf=.dos.txt)
267 ifneq ($(NO_DNS),1)
269 VLMCS_SRCS += dns_srv.c
270 MULTI_SRCS += dns_srv.c
272 ifeq ($(DNS_PARSER),internal)
273 ifneq ($(MINGW),1)
274 VLMCS_SRCS += ns_parse.c ns_name.c
275 MULTI_SRCS += ns_parse.c ns_name.c
276 BASECFLAGS += "-DDNS_PARSER_INTERNAL"
277 endif
278 endif
280 endif
282 ifeq ($(MSRPC),1)
283 VLMCSD_SRCS += msrpc-server.c
284 VLMCS_SRCS += msrpc-client.c
285 MULTI_SRCS += msrpc-server.c msrpc-client.c
286 BASECFLAGS += -DUSE_MSRPC -Wno-unknown-pragmas
287 BASELDFLAGS += -lrpcrt4
288 else
289 SRCS += network.c rpc.c
290 endif
292 ifeq "$(WIN)" "1"
293 VLMCSD_SRCS += ntservice.c
294 MULTI_SRCS += ntservice.c
295 endif
297 ifeq ($(CRYPTO), openssl_with_aes)
298 BASECFLAGS += -D_CRYPTO_OPENSSL -D_USE_AES_FROM_OPENSSL
299 BASELDFLAGS += -lcrypto
300 SRCS += crypto_openssl.c
301 else ifeq ($(CRYPTO), openssl_with_aes_soft)
302 BASECFLAGS += -D_CRYPTO_OPENSSL -D_USE_AES_FROM_OPENSSL -D_OPENSSL_SOFTWARE
303 BASELDFLAGS += -lcrypto
304 SRCS += crypto_openssl.c
305 else ifeq ($(CRYPTO), openssl)
306 BASECFLAGS += -D_CRYPTO_OPENSSL
307 BASELDFLAGS += -lcrypto
308 SRCS += crypto_openssl.c
309 else ifeq ($(CRYPTO), polarssl)
310 BASECFLAGS += -D_CRYPTO_POLARSSL
311 BASELDFLAGS += -lpolarssl
312 else ifeq ($(CRYPTO), windows)
313 BASECFLAGS += -D_CRYPTO_WINDOWS
314 SRCS += crypto_windows.c
315 #BASELDFLAGS += -lpolarssl
316 else
317 BASECFLAGS += -D_CRYPTO_INTERNAL
318 SRCS += crypto_internal.c
319 endif
321 ifneq ($(STRIP),0)
322 BASELDFLAGS += $(STRIPFLAGS)
323 endif
325 ifeq ($(OPENSSL_HMAC),0)
326 BASECFLAGS += -D_OPENSSL_NO_HMAC
327 endif
329 ifeq ($(DEPENDENCIES),2)
330 BASECFLAGS += -MMD
331 endif
333 ifeq ($(VERBOSE),3)
334 COMPILER := $(shell printf "%-40s" $(notdir $(CC)))
335 endif
337 ifeq ($(CAT),2)
338 LDCMD := CC/LD
339 else
340 LDCMD := LD
341 endif
343 -include $(MULTI_SRCS:.c=.d)
345 %.o: %.c
346 ifeq ($(VERBOSE),1)
347 $(CC) $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(PLATFORMFLAGS) -c $<
348 ifeq ($(DEPENDENCIES),1)
349 $(CC) $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(PLATFORMFLAGS) -MM -MF $*.d $<
350 endif
351 else
352 @echo "$(COMPILER) CC $@ <- $<"
353 @$(CC) $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(PLATFORMFLAGS) -c $<
354 ifeq ($(DEPENDENCIES),1)
355 @echo "$(COMPILER) DEP $*.d <- $<"
356 @$(CC) $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(PLATFORMFLAGS) -MM -MF $*.d $<
357 endif
358 endif
360 vlmcsd_all.c: $(VLMCSD_SRCS)
361 ifeq ($(VERBOSE),1)
362 cat $^ > $@
363 else
364 @echo "$(COMPILER) CAT $@ <- $^"
365 @cat $^ > $@
366 endif
368 vlmcs_all.c: $(VLMCS_SRCS)
369 ifeq ($(VERBOSE),1)
370 cat $^ > $@
371 else
372 @echo "$(COMPILER) CAT $@ <- $^"
373 @cat $^ > $@
374 endif
376 vlmcsdmulti_all.c: $(MULTI_SRCS)
377 ifeq ($(VERBOSE),1)
378 cat $^ > $@
379 else
380 @echo "$(COMPILER) CAT $@ <- $^"
381 @cat $^ > $@
382 endif
384 ifdef CAT
385 ifeq ($(CAT),2)
386 $(PROGRAM_NAME): vlmcsd_all.c
387 else
388 $(PROGRAM_NAME): vlmcsd_all.o
389 endif
390 else
391 $(PROGRAM_NAME): $(VLMCSD_OBJS)
392 endif
393 ifeq ($(VERBOSE),1)
394 +$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
395 else
396 +@echo "$(COMPILER) $(LDCMD) $@ <- $^"
397 +@$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
398 endif
400 ifdef CAT
401 ifeq ($(CAT),2)
402 $(CLIENT_NAME): vlmcs_all.c
403 else
404 $(CLIENT_NAME): vlmcs_all.o
405 endif
406 else
407 $(CLIENT_NAME): $(VLMCS_OBJS)
408 endif
409 ifeq ($(VERBOSE),1)
410 +$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
411 else
412 +@echo "$(COMPILER) $(LDCMD) $@ <- $^"
413 +@$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
414 endif
416 ifdef CAT
417 ifeq ($(CAT),2)
418 $(MULTI_NAME): vlmcsdmulti_all.c
419 else
420 $(MULTI_NAME): vlmcsdmulti_all.o
421 endif
422 else
423 $(MULTI_NAME): $(MULTI_OBJS)
424 endif
425 ifeq ($(VERBOSE),1)
426 +$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
427 else
428 +@echo "$(COMPILER) $(LDCMD) $@ <- $^"
429 +@$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS)
430 endif
432 $(DLL_NAME): $(DLL_SRCS)
433 ifeq ($(VERBOSE),1)
434 +$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS) -shared -DIS_LIBRARY=1 -UNO_SOCKETS -UUSE_MSRPC
435 else
436 +@echo "$(COMPILER) $(LDCMD) $@ <- $^"
437 +@$(CC) -o $@ $^ $(PLATFORMFLAGS) $(BASECFLAGS) $(CFLAGS) $(BASELDFLAGS) $(LDFLAGS) -shared -DIS_LIBRARY=1 -UNO_SOCKETS -UUSE_MSRPC
438 endif
441 %.pdf : %
442 ifeq ($(shell uname), Darwin)
443 groff -Tps -mandoc -c $< | pstopdf -i -o $@
444 else
445 groff -Tpdf -mandoc -c $< > $@
446 endif
448 %.html : %
449 groff -Thtml -mandoc -c $< > $@
451 %.unix.txt : %
452 groff -P -c -Tutf8 -mandoc -c $< | col -bx > $@
454 %.dos.txt : %.unix.txt
455 # unix2dos -n $< $@
456 # sed -e 's/$$/\r/' $< > $@
457 awk 'sub("$$", "\r")' $< > $@
459 pdfdocs : $(PDFDOCS)
461 dosdocs : $(DOSDOCS)
463 unixdocs : $(UNIXDOCS)
465 htmldocs : $(HTMLDOCS)
467 alldocs : $(UNIXDOCS) $(HTMLDOCS) $(PDFDOCS) $(DOSDOCS)
469 clean:
470 rm -f *.o *.d *_all.c $(PROGRAM_NAME) $(MULTI_NAME) $(DLL_NAME) $(CLIENT_NAME) $(PDFDOCS) $(DOSDOCS) $(UNIXDOCS) $(HTMLDOCS)
472 help:
473 @echo "Type:"
474 @echo " ${MAKE} - to build $(PROGRAM_NAME) and $(CLIENT_NAME)"
475 @echo " ${MAKE} clean - to remove $(PROGRAM_NAME) and $(CLIENT_NAME)"
476 @echo " ${MAKE} help - to see this help"
477 @echo " ${MAKE} pdfdocs - Create PDF versions of the documentation (Requires groff with PDF support)."
478 @echo " ${MAKE} htmldocs - Create HTML versions of the documentation."
479 @echo " ${MAKE} unixdocs - Create Unix TXT versions of the documentation."
480 @echo " ${MAKE} dosdocs - Create DOS/Windows TXT versions of the documentation."
481 @echo " ${MAKE} alldocs - Create all versions of the documentation."
482 @echo " ${MAKE} -j <x> - Use <x> parallel tasks (SMP support) when compiling $(PROGRAM_NAME) and $(CLIENT_NAME)"
483 @echo ""
484 @echo " ${MAKE} $(PROGRAM_NAME) - to build the server only."
485 @echo " ${MAKE} $(CLIENT_NAME) - to build the client only."
486 @echo " ${MAKE} $(MULTI_NAME) - to build $(PROGRAM_NAME) and $(CLIENT_NAME) in a single multi-call binary"
487 @echo " ${MAKE} $(DLL_NAME) - to build the shared library $(DLL_NAME)"
488 @echo ""
489 @echo "Options:"
490 @echo " CONFIG=<x> Compile <x> as instead of config.h."
491 @echo " INI=<x> Compile $(PROGRAM_NAME) with default ini file <x>"
492 @echo " PROGRAM_NAME=<x> Use <x> as output file name for the KMS server. Defaults to vlmcsd."
493 @echo " CLIENT_NAME=<x> Use <x> as output file name for the KMS client. Defaults to vlmcs."
494 @echo " MULTI_NAME=<x> Use <x> as output file name for the multi-call binary. Defaults to vlmcsdmulti."
495 @echo " DEPENDENCIES=1 Create dependency files."
496 @echo " CRYPTO=openssl Use openssl for SHA256/HMAC calculations."
497 @echo " CRYPTO=openssl_with_aes EXPERIMENTAL: Use openssl for SHA256/HMAC and AES calculations (hardware, e.g. AES-NI on x86)."
498 @echo " CRYPTO=openssl_with_aes_soft EXPERIMENTAL: Use openssl for SHA256/HMAC and AES calculations (software)."
499 @echo " CRYPTO=polarssl Use polarssl instead of internal crypto code for SHA256/HMAC calculations."
500 @echo " CRYPTO=windows Use Windows CryptoAPI instead of internal crypto code for SHA256/HMAC calculations."
501 @echo " CC=<x> Use compiler <x>. Supported compilers are gcc, icc, tcc and clang. Others may or may not work."
502 @echo " TERMINAL_WIDTH=<x> Assume a fixed terminal width of <x> columns. Use in case of problems only."
503 @echo " VLMCSD_VERSION=<x> Sets <x> as your version identifier. Defaults to \"private build\"."
504 @echo " CFLAGS=<x> Pass <x> as additional arguments to the compiler."
505 @echo " LDFLAGS=<x> Pass <x> as additional arguments to the linker."
506 @echo " PLATFORMFLAGS=<x> Pass <x> as additional arguments to the compiler and the linker."
507 @echo " BASECFLAGS=<x> Pass only <x> as arguments to the compiler (advanced users only)."
508 @echo " BASELDFLAGS=<x> Pass only <x> as arguments to the linker (advanced users only)."
509 @echo " STRIP=0 Don't strip debug information from $(PROGRAM_NAME) and $(CLIENT_NAME) (for developers)."
510 @echo " VERBOSE=1 Be verbose when making targets."
511 @echo " VERBOSE=3 Show name of compiler."
512 @echo " THREADS=1 Use threads instead of fork(). Automatically set for native Windows. Recommended for Cygwin."
513 @echo " WINDOWS=<x> Use <x> as the default ePID for Windows (when using $(PROGRAM_NAME) with -r 0)."
514 @echo " OFFICE2010=<x> Use <x> as the default ePID for Office2010 (when using $(PROGRAM_NAME) with -r 0)."
515 @echo " OFFICE2013=<x> Use <x> as the default ePID for Office2013 (when using $(PROGRAM_NAME) with -r 0)."
516 @echo " HWID=<x> Use <x> as the default HWID (when it can't be found in an ini file)."
517 @echo " FEATURES=full Compile $(PROGRAM_NAME) with all features (default)."
518 @echo " FEATURES=most Compile $(PROGRAM_NAME) without rarely used features."
519 @echo " FEATURES=embedded Compile $(PROGRAM_NAME) with typical features for embedded systems."
520 @echo " FEATURES=autostart Removes features typically not needed if you place $(PROGRAM_NAME) in an autostart script."
521 @echo " FEATURES=inetd Compile $(PROGRAM_NAME) for running through an internet superserver only."
522 @echo " FEATURES=minimum Compiles only basic features of $(PROGRAM_NAME)."
523 @echo " FEATURES=fixedepids $(PROGRAM_NAME) only uses bultin internal ePIDs."
524 @echo ""
525 @echo "Useful CFLAGS to save memory when running $(PROGRAM_NAME) on very small embedded devices (finer control than FEATURES=):"
526 @echo " -DNO_EXTENDED_PRODUCT_LIST Don't compile the detailed product list."
527 @echo " -DNO_BASIC_PRODUCT_LIST Don't compile the basic product list."
528 @echo " -DNO_VERBOSE_LOG Don't support verbose logging. Removes -v option."
529 @echo " -DNO_LOG Don't add support for logging. Implies -DNO_VERBOSE_LOG -DNO_EXTENDED_PRODUCT_LIST and -DNO_BASIC_PRODUCT_LIST."
530 @echo " -DNO_RANDOM_EPID Don't support random ePIDs."
531 @echo " -DNO_INI_FILE Don't support reading ePIDs/HWIDs from a file."
532 @echo " -DNO_PID_FILE Don't support writing a PID file. Removes -p option."
533 @echo " -DNO_USER_SWITCH Don't support changing uid/gid after program start. Removes -u and -g options."
534 @echo " -DNO_HELP Don't support command line help."
535 @echo " -DNO_CUSTOM_INTERVALS Don't support custom intervals for retry and refresh activation. Removes -A and -R options."
536 @echo " -DNO_SOCKETS Don't support standalone operation. Requires an internet superserver to start $(PROGRAM_NAME)."
537 @echo " -DNO_CL_PIDS Don't support specifying ePIDs and HwId from the command line in $(PROGRAM_NAME)."
538 @echo " -DNO_LIMIT Don't support limiting concurrent clients in $(PROGRAM_NAME)."
539 @echo " -DNO_SIGHUP Don't support SIGHUP handling in $(PROGRAM_NAME)."
540 @echo ""
541 @echo "Troubleshooting options"
542 @echo " CAT=1 Combine all sources in a single file."
543 @echo " CAT=2 Combine all sources in a single file and don't create a *.o file."
544 @echo " NOPROCFS=1 Don't rely on a properly mounted proc filesystem in /proc."
545 @echo " AUXV=1 Use /proc/self/auxv (requires Linux with glibc >= 2.16 or musl.)"
546 @echo " NOLPTHREAD=1 Disable detection if -lpthread is required (for use with Android NDK)."
547 @echo " NOLRESOLV=1 Disable detection if -lresolv is requires (for use with Android NDK)."
548 @echo " NOLIBS=1 Do not attempt to autodetect any library dependencies."
549 @echo " OPENSSL_HMAC=0 Compile for openssl versions that don't have HMAC support (required on some embedded devices)."
550 @echo " NO_TIMEOUT=1 Do not set timeouts for sockets (for systems that don't support it)."
551 @echo " CHILD_HANDLER=1 Install a handler for SIGCHLD (for systems that don't support SA_NOCLDWAIT)."
552 @echo " NO_DNS=1 Compile vlmcs without support for detecting KMS servers via DNS."
553 @echo " DNS_PARSER=internal Use $(CLIENT_NAME) internal DNS parsing routines. No effect on MingW (native Windows)."
554 @echo ""
555 @echo "Other useful CFLAGS:"
556 @echo " -DSUPPORT_WINE Add code that the Windows version of $(PROGRAM_NAME) runs on Wine if MSRPC=1"
557 @echo " -D_PEDANTIC Report rare error/warning conditions instead of silently ignoring them."
558 @echo " -DINCLUDE_BETAS Include SKU / activation IDs for obsolete beta/preview products."
559 @echo " -DFD_SETSIZE=<x> Allow <x> -L statements in $(PROGRAM_NAME) (default: 64 on Windows, 1024 on most Unixes)."
560 @echo " -flto Use link time optimization. Not supported by old compilers (gcc < 4.7). Use whenever supported."
561 @echo " -flto=jobserver Utilize all CPUs during link time optimization. Requires ${MAKE} -j <cpus>"
562 @echo " -fno-stack-protector No stack checking. Smaller binaries."
563 @echo " -pipe Use pipes instead of temporary files (faster compilation, extends the life of your SSD)."