Subversion Repositories eduke32

Rev

Rev 4817 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1739 helixhorne 1
 
4547 hendricks2 2
PACKAGE_REPOSITORY ?= 0
3
4
 
5
PRETTY_OUTPUT ?= 1
1791 helixhorne 6
1739 helixhorne 7
 
3096 hendricks2 8
CROSS=
3972 hendricks2 9
ifneq ($(CROSS),)
4547 hendricks2 10
    undefine CC
11
    undefine CXX
12
    undefine AR
13
    undefine RC
14
    undefine RANLIB
15
    undefine STRIP
16
endif
17
3096 hendricks2 18
 
4647 hendricks2 19
CXX=$(CROSS)g++
20
AR=$(CROSS)ar
21
RC=$(CROSS)windres
22
RANLIB=$(CROSS)ranlib
23
STRIP=$(CROSS)strip
24
AS=nasm
25
PKG_CONFIG=pkg-config
26
4547 hendricks2 27
 
4807 hendricks2 28
DONT_FAIL = ; exit 0
29
30
 
4547 hendricks2 31
ifeq ($(CC),cc)
32
    override CC=gcc
33
endif
34
ifeq ($(AS),as)
35
    override AS=nasm
36
endif
37
38
 
4644 hendricks2 39
L_CC=$(CC)
3122 hendricks2 40
L_CXX=$(CXX)
41
42
 
4543 hendricks2 43
3278 hendricks2 44
 
45
    ifeq ($(strip $(DEVKITPPC)),)
46
        $(error "Please set DEVKITPPC in your environment. export DEVKITPPC=<path to>devkitPPC")
47
    endif
48
49
 
50
51
 
4543 hendricks2 52
53
 
4647 hendricks2 54
    RANLIB=powerpc-eabi-ranlib
3278 hendricks2 55
    STRIP=powerpc-eabi-strip
56
    ELF2DOL=elf2dol
4824 hendricks2 57
    DOLSUFFIX=.dol
58
endif
3278 hendricks2 59
60
 
4644 hendricks2 61
62
 
63
64
 
65
    override CLANG=1
66
endif
67
# detect clang symlinked as gcc, as in OS X
68
ifeq ($(findstring clang,$(CLANG_POTENTIAL_VERSION)),clang)
69
    override CLANG=1
70
endif
71
72
 
73
    override CC=clang -x c
74
    override CXX=clang -x c++
75
    override COMPILER_OBJC=clang -x objective-c
76
    override L_CC=clang
77
    override L_CXX=clang
78
endif
79
80
 
3096 hendricks2 81
ifndef GCC_MAJOR
3278 hendricks2 82
    GCC_MAJOR    := $(shell $(CCFULLPATH) -dumpversion 2>&1 | cut -d'.' -f1)
4543 hendricks2 83
endif
3278 hendricks2 84
ifeq ($(GCC_MAJOR),)
85
    GCC_MAJOR    := 4
86
endif
87
ifndef GCC_MINOR
88
    GCC_MINOR    := $(shell $(CCFULLPATH) -dumpversion 2>&1 | cut -d'.' -f2)
4543 hendricks2 89
endif
3278 hendricks2 90
ifeq ($(GCC_MINOR),)
91
    GCC_MINOR    := 8
4543 hendricks2 92
endif
3278 hendricks2 93
3096 hendricks2 94
 
95
ifndef SYSARCH
3278 hendricks2 96
    SYSARCH:=$(strip $(shell uname -m))
97
endif
98
SYSBITS=32
4543 hendricks2 99
3096 hendricks2 100
 
101
# the outside world. This allows cross-compilation by overriding
102
# CC and giving us PLATFORM specifically.
103
#
104
ifndef HOST
4807 hendricks2 105
    uname:=$(strip $(shell uname -s))
3278 hendricks2 106
    HOST=UNKNOWN
4807 hendricks2 107
    ifeq ($(findstring Linux,$(uname)),Linux)
3096 hendricks2 108
        HOST=LINUX
4807 hendricks2 109
    endif
3096 hendricks2 110
    ifeq ($(findstring BSD,$(uname)),BSD)
111
        HOST=BSD
4807 hendricks2 112
    endif
3096 hendricks2 113
    ifeq ($(findstring MINGW,$(uname)),MINGW)
114
        HOST=WINDOWS
4807 hendricks2 115
    endif
3096 hendricks2 116
    ifeq ($(findstring Darwin,$(uname)),Darwin)
117
        HOST=DARWIN
4807 hendricks2 118
    endif
3096 hendricks2 119
    ifeq ($(findstring BeOS,$(uname)),BeOS)
120
        HOST=BEOS
4807 hendricks2 121
    endif
3096 hendricks2 122
    ifeq ($(findstring skyos,$(uname)),skyos)
123
        HOST=SKYOS
4807 hendricks2 124
    endif
3096 hendricks2 125
    ifeq ($(findstring QNX,$(uname)),QNX)
126
        HOST=QNX
4807 hendricks2 127
    endif
3096 hendricks2 128
    ifeq ($(findstring SunOS,$(uname)),SunOS)
129
        HOST=SUNOS
4807 hendricks2 130
    endif
3096 hendricks2 131
    ifeq ($(findstring syllable,$(uname)),syllable)
132
        HOST=SYLLABLE
4807 hendricks2 133
    endif
3096 hendricks2 134
endif
135
ifndef PLATFORM
4807 hendricks2 136
    PLATFORM=$(HOST)
137
endif
138
3096 hendricks2 139
 
3272 hendricks2 140
    SUBPLATFORM=
141
    ifeq ($(PLATFORM),LINUX)
142
        SUBPLATFORM=LINUX
143
    endif
144
    ifeq ($(PLATFORM),DINGOO)
145
        SUBPLATFORM=LINUX
146
        CROSS=mipsel-linux-
3972 hendricks2 147
    endif
3272 hendricks2 148
    ifeq ($(PLATFORM),GCW)
149
        SUBPLATFORM=LINUX
150
        CROSS=mipsel-linux-
3972 hendricks2 151
    endif
3272 hendricks2 152
    ifeq ($(PLATFORM),CAANOO)
153
        SUBPLATFORM=LINUX
154
    endif
155
endif
156
157
 
2476 hendricks2 158
EXESUFFIX_OVERRIDE ?=
159
160
 
4023 helixhorne 161
SYNTHESIS ?= 0
162
163
 
2398 hendricks2 164
# Like above, use absolute paths.
165
APPLE_FRAMEWORKS ?=/Library/Frameworks
166
# Without the resource files packaged in the .app bundle, the startupwindow produces errors, so give it an off switch.
3368 hendricks2 167
OSX_STARTUPWINDOW ?= 1
3278 hendricks2 168
2398 hendricks2 169
 
1739 helixhorne 170
#  USE_OPENGL     - enables basic OpenGL Polymost renderer
1820 terminx 171
#  POLYMER        - enables fancy Polymer renderer
172
#  NOASM          - disables the use of inline assembly pragmas
1739 helixhorne 173
#  LINKED_GTK     - enables compile-time linkage to GTK
174
#
175
POLYMER = 1
176
USE_OPENGL = 1
177
NOASM = 0
178
LINKED_GTK = 0
179
BUILD32_ON_64 ?= 0
1907 helixhorne 180
USE_LIBPNG ?= 1
2843 helixhorne 181
USE_LIBVPX ?= 1
2076 helixhorne 182
HAVE_VORBIS ?= 1
4713 terminx 183
HAVE_FLAC ?= 1
184
NETCODE ?= 1
3260 helixhorne 185
4107 helixhorne 186
 
3957 helixhorne 187
USE_LUAJIT_2_1 ?= 0
4107 helixhorne 188
1739 helixhorne 189
 
4066 helixhorne 190
USE_ASM64 ?= 0
191
192
 
1739 helixhorne 193
    POLYMER = 0
194
    USE_LIBVPX = 0
1933 helixhorne 195
endif
1739 helixhorne 196
197
 
198
#  CPLUSPLUS - 1 = enable C++ building
3116 hendricks2 199
#  RELEASE - 1 = no debugging
1739 helixhorne 200
#  DEBUGANYWAY:
4756 helixhorne 201
#    1 = Include debug symbols even when generating release code.
202
#    2 = Also enable sanitizers with Clang. On the C side, make 'sprite' etc. be real arrays.
203
#  DISABLEINLINING - 1 = compile inline functions as extern __fastcall instead of static inline
4247 hendricks2 204
#  KRANDDEBUG - 1 = include logging of krand() calls for debugging the demo system
1739 helixhorne 205
#  MEMMAP - 1 = produce .memmap file when linking
4543 hendricks2 206
#  EFENCE  - 1 = compile with Electric Fence for malloc() debugging
1739 helixhorne 207
#  OPTLEVEL	- 0..3 = GCC optimization strategy
208
#  LTO - 1 = enable link-time optimization, for GCC 4.5 and up
1856 helixhorne 209
#
1739 helixhorne 210
CPLUSPLUS?=1
4704 terminx 211
RELEASE?=1
1739 helixhorne 212
DEBUGANYWAY?=0
213
KRANDDEBUG?=0
214
MEMMAP?=0
4543 hendricks2 215
DISABLEINLINING?=0
3116 hendricks2 216
EFENCE?=0
1739 helixhorne 217
DMALLOC?=0
2254 helixhorne 218
PROFILER?=0
1739 helixhorne 219
MUDFLAP?=0
1850 terminx 220
1739 helixhorne 221
 
4298 helixhorne 222
# allocache()-allocated memory accesses with e.g. Valgrind.
223
# For debugging with Valgrind + GDB, see
224
# http://valgrind.org/docs/manual/manual-core-adv.html#manual-core-adv.gdbserver
225
ALLOCACHE_AS_MALLOC?=0
226
227
 
3725 helixhorne 228
ifeq ($(RELEASE),0)
3728 Plagman 229
    OPTLEVEL?=0
3725 helixhorne 230
else
231
    OPTLEVEL?=2
232
endif
233
234
 
3422 helixhorne 235
    override STRIP=
3423 helixhorne 236
endif
3422 helixhorne 237
ifneq ($(DEBUGANYWAY),0)
238
    override STRIP=
3423 helixhorne 239
endif
3422 helixhorne 240
241
 
3957 helixhorne 242
    # FIXME: Lunatic builds with LTO don't start up properly as the required
243
    # symbol names are apparently not exported.
244
    override LTO=0
245
endif
246
247
 
3122 hendricks2 248
    LTO=1
249
    ifneq (0,$(CLANG))
250
        ifeq ($(PLATFORM), WINDOWS)
251
            LTO=0
252
        endif
253
    endif
254
endif
255
256
 
4547 hendricks2 257
COMPILERFLAGS=
4543 hendricks2 258
259
 
4547 hendricks2 260
    COMMONFLAGS += $(OPTIMIZATIONS)
261
endif
4543 hendricks2 262
263
 
4547 hendricks2 264
4543 hendricks2 265
 
4547 hendricks2 266
ifeq (0,$(CLANG))
4768 hendricks2 267
    ifneq ($(PLATFORM),WII)
4547 hendricks2 268
        DEBUGFLAG=-ggdb -fno-omit-frame-pointer
4817 helixhorne 269
    endif
4547 hendricks2 270
endif
271
ifneq ($(RELEASE)$(DEBUGANYWAY),10)
4543 hendricks2 272
    # debug build or DEBUGANYWAY=1 --> -g flag
273
    OPTIMIZATIONS += $(DEBUGFLAG)
4547 hendricks2 274
endif
4543 hendricks2 275
276
 
4762 hendricks2 277
CPPONLYFLAGS= -fno-exceptions -fno-rtti -Wno-write-strings
4547 hendricks2 278
ASFORMAT=elf$(SYSBITS)
4543 hendricks2 279
ASFLAGS=-s -f $(ASFORMAT) #-g
280
LINKERFLAGS=
281
LIBS=-lm
282
LIBDIRS=
283
284
 
3278 hendricks2 285
    F_NO_STACK_PROTECTOR := -fno-stack-protector
3096 hendricks2 286
    # there are some link-time issues with stack protectors, so make it possible to override
287
    F_STACK_PROTECTOR_ALL ?= -fstack-protector-all
288
    ifeq (0,$(CLANG))
289
        F_JUMP_TABLES := -fjump-tables
290
    endif
291
    M_TUNE_GENERIC := -mtune=generic
292
    M_STACKREALIGN := -mstackrealign
293
    W_STRICT_OVERFLOW := -Wno-strict-overflow
3963 helixhorne 294
endif
3096 hendricks2 295
296
 
4807 hendricks2 297
    DONT_PRINT = > NUL 2>&1
298
endif
299
300
 
3278 hendricks2 301
    ifndef COMPILERTARGET
302
        COMPILERTARGET:=$(strip $(shell $(CC) -dumpmachine))
303
    endif
304
305
 
306
        SYSARCH:=x86_64
307
        SYSBITS=64
4552 hendricks2 308
    endif
3278 hendricks2 309
310
 
4543 hendricks2 311
else
4552 hendricks2 312
ifneq (1,$(BUILD32_ON_64))
313
    ifeq ($(findstring x86_64,$(ARCH)),x86_64)
314
        SYSBITS=64
315
    endif
316
    ifeq ($(ARCH),)
317
        ifeq ($(findstring x86_64,$(SYSARCH)),x86_64)
318
            SYSBITS=64
319
        endif
320
    endif
321
endif
3278 hendricks2 322
endif
4552 hendricks2 323
3278 hendricks2 324
 
3096 hendricks2 325
    ifndef DARWINVERSION
3278 hendricks2 326
        DARWINVERSION:=$(strip $(shell uname -r | cut -d . -f 1))
327
    endif
328
4644 hendricks2 329
 
330
	DARWIN10 ?= 0
331
    ifeq (1,$(strip $(shell expr $(DARWINVERSION) \< 10)))
3096 hendricks2 332
        override DARWIN9 := 1
4644 hendricks2 333
    endif
3096 hendricks2 334
    ifeq (1,$(strip $(shell expr $(DARWINVERSION) \< 11)))
4644 hendricks2 335
        override DARWIN10 := 1
336
    endif
337
3096 hendricks2 338
 
4543 hendricks2 339
3096 hendricks2 340
 
341
        F_JUMP_TABLES :=
342
        W_STRICT_OVERFLOW :=
343
    endif
344
345
 
346
        COMMONFLAGS += $(F_NO_STACK_PROTECTOR)
4543 hendricks2 347
    else
3096 hendricks2 348
        ifeq ($(findstring ppc,$(ARCH)),ppc)
349
            COMMONFLAGS += $(F_NO_STACK_PROTECTOR)
4543 hendricks2 350
        endif
3096 hendricks2 351
    endif
352
    ifneq (0,$(OSX_STARTUPWINDOW))
3334 hendricks2 353
        COMPILERFLAGS+= -DOSX_STARTUPWINDOW
4543 hendricks2 354
    endif
3334 hendricks2 355
endif
3096 hendricks2 356
357
 
4543 hendricks2 358
 
4555 hendricks2 359
    # Debugging disabled
360
    COMMONFLAGS += $(F_NO_STACK_PROTECTOR)
361
else
362
    # Debugging enabled
363
    ifneq (0,$(KRANDDEBUG))
364
        COMMONFLAGS += -fno-inline -fno-inline-functions -fno-inline-functions-called-once
365
    endif
366
    ifeq (1,$(SDL_TARGET))
367
        COMPILERFLAGS += -DNOSDLPARACHUTE
368
    endif
369
endif
370
371
 
3096 hendricks2 372
    ifeq ($(PLATFORM), WII)
373
        OPTOPT=
374
    else
375
        OPTOPTARCH=$(ARCH)
376
        ifeq (,$(OPTOPTARCH))
377
            OPTOPTARCH=$(SYSARCH)
378
        endif
379
380
 
381
            OPTOPT=-march=pentium3 $(M_TUNE_GENERIC) -mmmx
382
            # -msse2 -mfpmath=sse,387 -malign-double $(M_STACKREALIGN)
383
        else
384
            OPTOPT=
385
        endif
386
    endif
387
endif
388
389
 
1739 helixhorne 390
    RELEASE=0
391
endif
392
ifneq (0,$(PROFILER))
393
    # XXX: Why?
4756 helixhorne 394
    DEBUGANYWAY=1
1739 helixhorne 395
endif
396
397
 
398
 
399
 
2520 hendricks2 400
 
3278 hendricks2 401
    ifeq (1,$(strip $(shell expr $(GCC_MINOR) \>= 1)))
402
        COMPILERFLAGS+= -Wno-attributes
4543 hendricks2 403
    endif
3278 hendricks2 404
endif
405
406
 
2685 hendricks2 407
    override USE_LIBVPX = 0
408
    override NETCODE = 0
4390 terminx 409
    override HAVE_FLAC = 0
4713 terminx 410
endif
2685 hendricks2 411
ifeq ($(PLATFORM),GCW)
3972 hendricks2 412
    override USE_LIBVPX = 0
413
endif
414
ifeq ($(PLATFORM),DINGOO)
415
    override USE_LIBVPX = 0
416
endif
417
2685 hendricks2 418
 
1933 helixhorne 419
    # On Windows, we link statically to libvpx
2038 helixhorne 420
    LIBS+= -lvpx
4543 hendricks2 421
endif
1933 helixhorne 422
1852 helixhorne 423
 
2292 helixhorne 424
 
4298 helixhorne 425
    COMPILERFLAGS += -DDEBUG_ALLOCACHE_AS_MALLOC
4543 hendricks2 426
endif
4298 helixhorne 427
428
 
4020 helixhorne 429
# for a list of possible UBSan options.
430
# Clang 3.2 does only supports -fsanitize=address for the AddressSanitizer
431
CLANG_DEBUG_FLAGS := -fsanitize=address -fsanitize=bounds,enum,float-cast-overflow,object-size
4756 helixhorne 432
#CLANG_DEBUG_FLAGS := $(CLANG_DEBUG_FLAGS),signed-integer-overflow
433
#CLANG_DEBUG_FLAGS := $(CLANG_DEBUG_FLAGS),unsigned-integer-overflow
434
#CLANG_DEBUG_FLAGS := $(CLANG_DEBUG_FLAGS) -fsanitize-undefined-trap-on-error
435
4020 helixhorne 436
 
1739 helixhorne 437
    ## Debugging disabled
4756 helixhorne 438
439
 
2672 helixhorne 440
        COMMONFLAGS += -funswitch-loops
4543 hendricks2 441
        ifeq (1,$(strip $(shell expr $(GCC_MAJOR) \< 4)))
3278 hendricks2 442
            override LTO=0
4684 hendricks2 443
        endif
3278 hendricks2 444
        ifeq (1,$(strip $(shell expr $(GCC_MAJOR) = 4)))
445
            ifeq ($(PLATFORM),WII)
4684 hendricks2 446
                ifeq (1,$(strip $(shell expr $(GCC_MINOR) \< 8)))
447
                    override LTO=0
448
                endif
449
            else
450
                ifeq (1,$(strip $(shell expr $(GCC_MINOR) \< 6)))
451
                    override LTO=0
452
                endif
453
            endif
3278 hendricks2 454
        endif
455
    endif
2182 helixhorne 456
4756 helixhorne 457
 
2040 helixhorne 458
        COMMONFLAGS += -fomit-frame-pointer
4543 hendricks2 459
        COMPILERFLAGS += -DNDEBUG
460
    else
3138 Plagman 461
        # Our $(DEBUGANYWAY) -> DEBUGGINGAIDS #define
4756 helixhorne 462
        COMPILERFLAGS += -DDEBUGGINGAIDS=$(DEBUGANYWAY)
463
        ifneq (0,$(CLANG))
464
            ifeq (2,$(DEBUGANYWAY))
465
                COMMONFLAGS += $(CLANG_DEBUG_FLAGS)
466
            endif
467
        endif
468
    endif
2040 helixhorne 469
4756 helixhorne 470
 
1856 helixhorne 471
        COMPILERFLAGS += -DUSING_LTO
4543 hendricks2 472
        COMMONFLAGS += -flto
473
    endif
1856 helixhorne 474
else
1739 helixhorne 475
    ## Debugging enabled
4756 helixhorne 476
477
 
478
    COMPILERFLAGS += -DDEBUGGINGAIDS=$(DEBUGANYWAY)
479
    ifneq (0,$(CLANG))
480
        ifeq (2,$(DEBUGANYWAY))
481
            COMMONFLAGS += $(CLANG_DEBUG_FLAGS)
482
        endif
483
    endif
2270 helixhorne 484
485
 
3272 hendricks2 486
        LIBS+=-rdynamic
4543 hendricks2 487
    endif
1770 plagman 488
4756 helixhorne 489
 
1850 terminx 490
        LIBS+= -lmudflapth
4543 hendricks2 491
        COMMONFLAGS += -fmudflapth
492
    endif
1850 terminx 493
    ifneq (0,$(PROFILER))
1739 helixhorne 494
        ifneq ($(PLATFORM),DARWIN)
3278 hendricks2 495
            LIBS+= -lprofiler
4543 hendricks2 496
        endif
3278 hendricks2 497
        COMMONFLAGS += -pg
4543 hendricks2 498
    endif
1739 helixhorne 499
    ifneq (0,$(KRANDDEBUG))
500
        COMPILERFLAGS += -DKRANDDEBUG=1
4543 hendricks2 501
    endif
1739 helixhorne 502
endif
503
504
 
3278 hendricks2 505
ifeq (0,$(CLANG))
2672 helixhorne 506
#    W_NO_UNUSED_RESULT := $(shell echo '' | $(CC) -E -Wno-unused-result - 2>/dev/null && echo -Wno-unused-result)
2972 hendricks2 507
#    W_NO_UNUSED_RESULT := $(findstring -Wno-unused-result,$(W_NO_UNUSED_RESULT))
508
    ifeq (1,$(strip $(shell expr $(GCC_MAJOR) \>= 4)))
3278 hendricks2 509
        ifeq (1,$(strip $(shell expr $(GCC_MINOR) \>= 4)))
510
            W_NO_UNUSED_RESULT := -Wno-unused-result
511
        endif
512
    endif
513
endif
2159 helixhorne 514
1791 helixhorne 515
 
4762 hendricks2 516
    -Wpointer-arith \
2797 helixhorne 517
    -Wextra \
518
    -Wno-char-subscripts \
4543 hendricks2 519
    #-Wstrict-prototypes \
2797 helixhorne 520
    #-Waggregate-return \
521
    #-Wwrite-strings \
522
    #-Wcast-qual -Wcast-align \
523
    #-Waddress -Wlogical-op
524
525
 
2672 helixhorne 526
    CWARNS+= -Wno-unused-value -Wno-parentheses
4543 hendricks2 527
endif
2159 helixhorne 528
529
 
4543 hendricks2 530
531
 
4750 terminx 532
4543 hendricks2 533
 
3260 helixhorne 534
    COMPILERFLAGS+= -DNETCODE_DISABLE
4543 hendricks2 535
endif
3260 helixhorne 536
3148 helixhorne 537
 
3260 helixhorne 538
 
3957 helixhorne 539
# LuaJIT standalone interpreter executable:
540
LUAJIT:=luajit
4000 helixhorne 541
# Options to "luajit -b" for synthesis. Since it runs on Linux, we need to tell
4023 helixhorne 542
# the native LuaJIT to emit PE object files.
543
ifeq ($(PLATFORM),WINDOWS)
4319 hendricks2 544
    LUAJIT_BCOPTS := -o windows
545
    ifeq (32,$(SYSBITS))
4543 hendricks2 546
        LUAJIT_BCOPTS += -a x86
4319 hendricks2 547
    endif
548
    ifeq (64,$(SYSBITS))
4543 hendricks2 549
        LUAJIT_BCOPTS += -a x64
4319 hendricks2 550
    endif
551
endif
4023 helixhorne 552
3148 helixhorne 553
 
554
    # FIXME: Lunatic doesn't build with inlining because of wacky include
555
    # chains!
556
    override DISABLEINLINING=1
557
558
 
4286 helixhorne 559
        # FIXME: Lunatic C++ doesn't build because otherwise it doesn't find
560
        # INT32_MIN and the like.
561
        COMPILERFLAGS+= -D__STDC_LIMIT_MACROS
4543 hendricks2 562
    endif
4286 helixhorne 563
564
 
4543 hendricks2 565
    ifneq ($(USE_LUAJIT_2_1),0)
4107 helixhorne 566
        COMPILERFLAGS+= -DUSE_LUAJIT_2_1
4543 hendricks2 567
    endif
4107 helixhorne 568
3148 helixhorne 569
 
3785 helixhorne 570
    ifndef DEFS_BC_SIZE
571
        DEFS_BC_SIZE := $(shell $(LUAJIT) -bg -t h source/lunatic/defs.ilua -)
4543 hendricks2 572
        DEFS_BC_SIZE := $(word 3, $(DEFS_BC_SIZE))
3785 helixhorne 573
        # Pass it to the sub-makes, too.
4238 helixhorne 574
        export DEFS_BC_SIZE
3785 helixhorne 575
    endif
576
    # Determine size of defs_m32.ilua bytecode once.
4238 helixhorne 577
    ifndef DEFS_M32_BC_SIZE
578
        DEFS_M32_BC_SIZE := $(shell $(LUAJIT) -bg -t h source/lunatic/defs_m32.ilua -)
4543 hendricks2 579
        DEFS_M32_BC_SIZE := $(word 3, $(DEFS_M32_BC_SIZE))
4238 helixhorne 580
        export DEFS_M32_BC_SIZE
581
    endif
582
    COMPILERFLAGS+= -DLUNATIC_DEFS_BC_SIZE=$(DEFS_BC_SIZE) -DLUNATIC_DEFS_M32_BC_SIZE=$(DEFS_M32_BC_SIZE)
4543 hendricks2 583
3517 helixhorne 584
 
3148 helixhorne 585
        LIBS+= -lluajit
4543 hendricks2 586
    else
3148 helixhorne 587
        LIBS+= -lluajit-5.1
4543 hendricks2 588
    endif
3148 helixhorne 589
endif
590
591
 
592
593
 
3116 hendricks2 594
    COMPILERFLAGS+= -DDISABLE_INLINING
4543 hendricks2 595
endif
3116 hendricks2 596
597
 
2718 helixhorne 598
ifdef EDUKE32_MY_DEVELOPER_ID
599
    COMPILERFLAGS+= -DMY_DEVELOPER_ID=$(EDUKE32_MY_DEVELOPER_ID)
4543 hendricks2 600
endif
2718 helixhorne 601
602
 
1852 helixhorne 603
    COMPILERFLAGS+= -DUSE_LIBPNG
4543 hendricks2 604
endif
1852 helixhorne 605
ifneq (0,$(USE_LIBVPX))
1933 helixhorne 606
    COMPILERFLAGS+= -DUSE_LIBVPX
4543 hendricks2 607
endif
1933 helixhorne 608
1739 helixhorne 609
 
4713 terminx 610
    COMPILERFLAGS+= -DHAVE_VORBIS
611
endif
612
ifneq (0,$(HAVE_FLAC))
613
    COMPILERFLAGS+= -DHAVE_FLAC
614
endif
615
ifneq (0,$(EFENCE))
2059 hendricks2 616
    LIBS+= -lefence
4543 hendricks2 617
    COMPILERFLAGS+= -DEFENCE
618
endif
2059 hendricks2 619
ifneq (0,$(DMALLOC))
2254 helixhorne 620
    LIBS+= -ldmalloc
4543 hendricks2 621
    COMPILERFLAGS+= -DDMALLOC
622
endif
2254 helixhorne 623
2059 hendricks2 624
 
4543 hendricks2 625
EXESUFFIX=
1739 helixhorne 626
DLLSUFFIX=.so
4543 hendricks2 627
4513 hendricks2 628
 
629
 
4543 hendricks2 630
SDL_FRAMEWORK ?= 0
4644 hendricks2 631
4543 hendricks2 632
 
633
    L_SSP := -lssp
634
endif
635
636
 
637
# Search for STDCPPLIB below and change it to -lsupc++.
638
639
 
640
SDL_LIB=-l$(SDLNAME)
641
SDL_MIXER_LIB=-l$(SDLNAME)_mixer
642
643
 
644
    RENDERTYPE=SDL
645
    MIXERTYPE=SDL
646
    COMPILERFLAGS+= -DHAVE_INTTYPES
647
    GTKCOMPAT32=0
648
    SDL_FRAMEWORK=0
649
650
 
651
    # presumably take care for us.
652
    STDCPPLIB:=
653
654
 
655
        override USE_OPENGL=0
656
        override NOASM=1
657
    endif
658
    ifeq ($(PLATFORM),DINGOO)
659
        override USE_OPENGL=0
660
        override NOASM=1
661
    endif
662
663
 
664
        ifeq (1,$(BUILD32_ON_64))
665
            # On my 64bit Gentoo these are the 32bit emulation libs
666
            LIBS+= -m32
667
            LIBDIRS+= -L/emul/linux/x86/usr/lib
668
            COMMONFLAGS+= -m32
669
            # Override WITHOUT_GTK=0
670
            GTKCOMPAT32=1
671
        else
672
            override NOASM=1
673
        endif
674
    endif
675
4555 hendricks2 676
 
677
    ifeq (0,$(CLANG))
678
        COMMONFLAGS	+= -fno-pic
679
    endif
680
endif
4543 hendricks2 681
ifeq ($(PLATFORM),DARWIN)
682
    COMPILERFLAGS+= -DUNDERSCORES
683
    ASFORMAT=macho$(SYSBITS)
684
    ASFLAGS+= -DUNDERSCORES
685
    # ASM on OS X crashes in mmxoverlay()
4768 hendricks2 686
    override NOASM=1
687
4543 hendricks2 688
 
4646 hendricks2 689
    # COMPILERFLAGS+= -Iplatform/Apple/include
690
4543 hendricks2 691
 
4644 hendricks2 692
        LIBDIRS+= -L/opt/local/lib
693
        COMPILERFLAGS+= -I/opt/local/include
694
    endif
695
    ifneq ($(shell brew --version &>/dev/null; echo $$?),127)
696
        LIBDIRS+= -L/usr/local/lib
697
        COMPILERFLAGS+= -I/usr/local/include
698
    endif
699
    ifneq ($(shell fink --version &>/dev/null; echo $$?),127)
700
        LIBDIRS+= -L/sw/lib
701
        COMPILERFLAGS+= -I/sw/include
702
    endif
703
704
 
4543 hendricks2 705
    MIXERTYPE     = SDL
706
    STDCPPLIB:=-lstdc++
707
    COMPILERFLAGS    += -DHAVE_INTTYPES
708
    DLLSUFFIX=.dylib
4644 hendricks2 709
    GTKCOMPAT32    = 0
4543 hendricks2 710
    WITHOUT_GTK   ?= 1
4548 hendricks2 711
4543 hendricks2 712
 
713
        SDL_INCLUDES=-I$(APPLE_FRAMEWORKS)/SDL.framework/Headers -I$(APPLE_FRAMEWORKS)/SDL_mixer.framework/Headers
714
        SDL_LIB=-l$(SDLNAME)main -Wl,-framework,SDL -Wl,-rpath -Wl,"@loader_path/../Frameworks"
715
        SDL_MIXER_LIB=-Wl,-framework,SDL_mixer
716
    endif
717
718
 
719
        COMPILERFLAGS += -DDARWIN9
720
    endif
721
722
 
723
        ARCH=-arch i386
724
    endif
725
726
 
727
        ifeq (,$(ARCH))
728
            ifneq ($(findstring x86_64,$(SYSARCH)),x86_64)
729
                LINKERFLAGS += -read_only_relocs suppress
730
            endif
731
        else
732
            LINKERFLAGS += -read_only_relocs suppress
733
        endif
734
    endif
735
4555 hendricks2 736
 
4768 hendricks2 737
        COMMONFLAGS	+= -fno-pic
738
    endif
739
endif
4543 hendricks2 740
ifeq ($(PLATFORM),WINDOWS)
741
    COMPILERFLAGS+= -DUNDERSCORES -DHAVE_INTTYPES -Iplatform/Windows/include
742
    LINKERFLAGS+= -static-libgcc
743
    ASFORMAT=win$(SYSBITS)
744
    ASFLAGS+= -DUNDERSCORES
745
746
 
747
    RENDERTYPE?=SDL
748
    MIXERTYPE?=WIN
749
    ifneq ($(RENDERTYPE),SDL)
750
        ifeq ($(MIXERTYPE),SDL)
751
            MIXERTYPE:=WIN
752
        endif
753
    endif
754
755
 
756
    ifeq ($(SDL_TARGET),1)
757
        SDL_MIXER_LIB=platform/Windows/lib$(WINLIB)/SDL_mixer.lib
758
    endif
759
760
 
761
    SDLCONFIG=
762
    SDL_FRAMEWORK=1
763
    EXESUFFIX=.exe
764
    DLLSUFFIX=.dll
765
    LIBDIRS+= -Lplatform/Windows/lib$(WINLIB)
4553 hendricks2 766
    LIBS+= -Wl,--enable-auto-import -lmingwex -lgdi32 -lcomctl32 -lwinmm $(L_SSP) -lwsock32 -lws2_32 -lshlwapi
4543 hendricks2 767
    ifeq (0,$(CLANG))
768
        LIBS+= -mwindows
769
    endif
770
    #-lshfolder
771
    STDCPPLIB:=-lstdc++
772
    ifeq ($(findstring x86_64,$(SYSARCH)),x86_64)
773
        ifneq (1,$(BUILD32_ON_64))
774
            override NOASM=1
775
        endif
776
    endif
777
4555 hendricks2 778
 
779
endif
4543 hendricks2 780
ifeq ($(PLATFORM),BSD)
781
    COMPILERFLAGS+= -I/usr/X11R6/include
782
783
 
784
    MIXERTYPE=SDL
785
    COMPILERFLAGS+= -DHAVE_INTTYPES
786
    ifneq ($(findstring i386,$(SYSARCH)),i386)
787
        override NOASM=1
788
    endif
789
    STDCPPLIB:=-lstdc++
790
endif
791
ifeq ($(PLATFORM),BEOS)
792
    override NOASM=1
793
794
 
795
    MIXERTYPE=SDL
796
    STDCPPLIB:=-lstdc++
797
endif
798
ifeq ($(PLATFORM),SKYOS)
799
    RENDERTYPE=SDL
800
    MIXERTYPE=SDL
801
    EXESUFFIX=.app
802
    override NOASM=1
803
    COMPILERFLAGS+= -DUNDERSCORES -I/boot/programs/sdk/include/sdl
804
    SDLCONFIG=
805
    LIBS+= -lSDL -lnet
806
endif
807
ifeq ($(PLATFORM),WII)
808
    RENDERTYPE=SDL
809
    MIXERTYPE=SDL
810
    SDL_INCLUDES=
811
    EXESUFFIX=.elf
812
    override USE_OPENGL=0
813
    override POLYMER=0
814
    override NOASM=1
815
    override WITHOUT_GTK=1
816
    # -msdata=eabi
817
    COMMONFLAGS+= -g -mtune=750 -meabi -mhard-float
818
    COMPILERFLAGS+= -DGEKKO -DHAVE_INTTYPES -D__POWERPC__ -I$(LIBOGC_INC) -I$(PORTLIBS)/include -Iplatform/Wii/include
819
    SDLCONFIG=
820
    SDL_TARGET=1
821
    SDL_FRAMEWORK=1
822
    LIBDIRS += -L$(LIBOGC_LIB) -L$(PORTLIBS)/lib -Lplatform/Wii/lib
4553 hendricks2 823
endif
4543 hendricks2 824
ifeq ($(PLATFORM),QNX)
825
    RENDERTYPE=SDL
826
    MIXERTYPE=SDL
827
    override USE_OPENGL=0
828
    override NOASM=1
829
    STDCPPLIB:=-lstdc++
830
    LIBS+= -lsocket
831
endif
832
ifeq ($(PLATFORM),SUNOS)
833
    RENDERTYPE=SDL
834
    MIXERTYPE=SDL
835
    override USE_OPENGL=0
836
    override NOASM=1
837
    STDCPPLIB:=-lstdc++
838
    LIBS+= -lsocket -lnsl
839
endif
840
ifeq ($(PLATFORM),SYLLABLE)
841
    RENDERTYPE=SDL
842
    MIXERTYPE=SDL
843
    override USE_OPENGL=0
844
    override NOASM=1
845
endif
846
ifeq ($(PLATFORM),GCW)
847
    COMPILERFLAGS += -D__OPENDINGUX__
848
endif
849
ifeq ($(PLATFORM),DINGOO)
850
    COMPILERFLAGS += -D__OPENDINGUX__
851
endif
852
853
 
854
    EXESUFFIX=$(EXESUFFIX_OVERRIDE)
855
endif
856
857
 
858
    ifneq (,$(STDCPPLIB))
859
        STDCPPLIB:=-Xlinker $(STDCPPLIB)
860
    endif
861
endif
862
863
 
864
    SDLCONFIG ?= sdl2-config
865
    SDLNAME ?= SDL2
866
endif
867
ifeq ($(SDL_TARGET),1)
868
    SDLCONFIG ?= sdl-config
869
    SDLNAME ?= SDL
870
endif
871
872
 
873
    SDLVERSION:=$(strip $(shell $(SDLCONFIG) --version))
874
    ifneq ($(SDLVERSION),)
875
        SDLROOT:=$(strip $(shell $(SDLCONFIG) --prefix))
876
    endif
877
endif
878
879
 
880
881
 
882
    COMPILERFLAGS += -DSDL_TARGET=$(SDL_TARGET)
883
884
 
885
        COMPILERFLAGS += -DSDL_FRAMEWORK
886
    endif
887
888
 
889
        ifeq ($(SDL_FRAMEWORK),1)
890
            ifeq ($(PLATFORM),DARWIN)
891
                LIBS        += -Wl,-framework,SDL
892
                COMPILERFLAGS+= -I$(APPLE_FRAMEWORKS)/SDL.framework/Headers \
893
                                -I$(APPLE_FRAMEWORKS)/SDL_mixer.framework/Headers
894
            endif
895
        else
896
            ifneq ($(SDLCONFIG),)
897
                SDLCONFIG_COMMONFLAGS:=$(subst -Dmain=SDL_main,,$(strip $(shell $(SDLCONFIG) --cflags)))
898
                SDLCONFIG_LIBS:=$(strip $(shell $(SDLCONFIG) --libs))
899
900
 
901
                COMMONFLAGS+= $(SDLCONFIG_COMMONFLAGS)
902
            endif
903
        endif
904
    else
905
        COMPILERFLAGS += -D_GNU_SOURCE=1
906
        ifneq ($(SDL_STATIC),0)
907
            ifneq ($(SDL_TARGET),1) # Since SDL2 is under the zlib license, link statically if possible.
908
                LIBS+= -static
909
            endif
910
        endif
911
        LIBS+= -l$(SDLNAME)main -l$(SDLNAME) -lmingw32 -lgdi32 -limm32 -lole32 -loleaut32 -lwinmm -lversion
912
    endif
913
914
 
915
        HAVE_GTK2=0
916
    else
917
        ifneq (No,$(shell $(PKG_CONFIG) --exists gtk+-2.0 || echo No))
4547 hendricks2 918
            HAVE_GTK2=1
4543 hendricks2 919
            # On my 64bit Gentoo box I have Cairo enabled which means the libs list includes
920
            # -lpangocairo-1.0 and -lcairo, however the 32bit compatibility libraries don't
921
            # include cairo, so we need to filter out those -l switches in order to link
922
            ifneq ($(LINKED_GTK),0)
923
                ifeq ($(GTKCOMPAT32),1)
924
                    LIBS+= $(shell $(PKG_CONFIG) --libs gtk+-2.0 | sed 's/\s-l\(pango\)\{0,1\}cairo\S*\s/ /g')
4547 hendricks2 925
                else
4543 hendricks2 926
                    LIBS+= $(shell $(PKG_CONFIG) --libs gtk+-2.0)
4547 hendricks2 927
                endif
4543 hendricks2 928
            endif
929
            COMPILERFLAGS += -DHAVE_GTK2 $(shell $(PKG_CONFIG) --cflags gtk+-2.0)
4547 hendricks2 930
        else
4543 hendricks2 931
            HAVE_GTK2=0
932
        endif
933
    endif
934
935
 
936
    ifneq ($(MIXERTYPE),WIN)
937
        LIBS += $(SDL_MIXER_LIB)
938
    endif
939
    LIBS += $(SDL_LIB)
940
endif
941
ifeq ($(RENDERTYPE),WIN)
942
    LIBS+= -ldxguid
943
endif
944
945
 
946
ifeq ($(PLATFORM),WINDOWS)
947
    ifeq ($(RENDERTYPE),SDL)
948
    SDL_LIB:=-l$(SDLNAME)main $(SDL_LIB)
949
        ifeq ($(MIXERTYPE),WIN)
950
            LIBS+= -ldxguid_sdl
951
        endif
952
    endif
953
endif
954
ifeq ($(PLATFORM),WII)
955
    LIBS+= -laesnd_tueidj -lpng -lfat -lwiiuse -lbte -logc -lm -lwiikeyboard
956
endif
957
958
 
959
960
 
961
    COMPILERFLAGS+= -DUSE_OPENGL
962
endif
963
ifneq (0,$(NOASM))
964
    COMPILERFLAGS+= -DNOASM
965
endif
966
ifneq (0,$(USE_ASM64))
967
    COMPILERFLAGS+= -DUSE_ASM64
968
endif
969
ifneq (0,$(LINKED_GTK))
970
    COMPILERFLAGS+= -DLINKED_GTK
971
endif
972
973
 
974
 ifneq (0,$(USE_OPENGL))
975
  COMPILERFLAGS+= -DPOLYMER
976
 endif
977
endif
978
979
 
980
ifeq (1,$(STATICSTDCPP))
981
    STATICSTDCPP= -static
982
endif
983
ifeq (0,$(STATICSTDCPP))
984
    STATICSTDCPP= -shared
985
endif
986
987
 
988
 
989
    ifneq ($(PLATFORM),WII)
990
        LIBS+= -ldl
991
        ifneq ($(PLATFORM),DARWIN)
4684 hendricks2 992
            LIBS+= -pthread
993
        endif
994
    endif
4543 hendricks2 995
endif
996
997
 
998
    ifneq ($(USE_LIBPNG),0)
999
        LIBS+= -lpng_mini -lz_mini
1000
    endif
1001
else
1002
    ifeq ($(PLATFORM),DARWIN)
1003
        ifneq ($(USE_LIBPNG),0)
1004
            LIBS+= -lpng # -lz
1005
        endif
1006
    else
1007
        ifneq ($(USE_LIBPNG),0)
1008
            LIBS+= -lpng -lz
1009
        endif
1010
    endif
1011
endif
1012
1013
 
1014
 
1015
    ifneq ($(findstring x86_64,$(COMPILERTARGET)),x86_64)
1016
        LINKERFLAGS+= -Wl,--large-address-aware
1017
    endif
1018
endif
1019
1020
 
1021
ifeq ($(PLATFORM),DARWIN)
1022
    LINKERFLAGS+=-Wl,-map -Wl,$@.memmap
1023
else
1024
    LINKERFLAGS+=-Wl,-Map=$@.memmap
1025
endif
1026
endif
1027
1028
 
1029
    LINKERFLAGS+=-pg
1030
endif
1031
ifeq ($(PLATFORM),WII)
1032
    LINKERFLAGS+= -mrvl -meabi -mhard-float -Wl,--gc-sections
1033
    # -msdata=eabi
1034
endif
1035
1036
 
4565 hendricks2 1037
ifeq (,$(VC_REV))
1038
    ifneq (,$(wildcard EDUKE32_REVISION))
1039
        VC_REV    := $(shell cat EDUKE32_REVISION)
1040
    endif
1041
endif
1042
ifeq (,$(VC_REV))
1043
    VC_REV    := $(shell svn info 2>&1 | grep Revision | cut -d' ' -f2)
1044
endif
1045
ifeq (,$(VC_REV))
1046
    VC_REV    := $(shell git svn info 2>&1 | grep Revision | cut -d' ' -f2)
1047
endif
1048
ifneq (,$(VC_REV)$(VC_REV_CUSTOM))
1049
    REVFLAG += -DREV="\"r$(VC_REV)$(VC_REV_CUSTOM)\""
1050
endif
1051
1052
 
4543 hendricks2 1053
LINKER=$(L_CC)
1054
ifneq ($(CPLUSPLUS),0)
1055
    COMPILER=$(CXX) $(CPPONLYFLAGS)
4547 hendricks2 1056
    LINKER=$(L_CXX)
4543 hendricks2 1057
endif
1058
1059
 
4513 hendricks2 1060
    COMMONFLAGS+= $(CUSTOMOPT)
4543 hendricks2 1061
endif
4513 hendricks2 1062
ifneq (,$(CFLAGS))
4543 hendricks2 1063
    COMMONFLAGS+= $(CFLAGS)
1064
endif
1065
ifneq (,$(CXXFLAGS))
4547 hendricks2 1066
    CPPONLYFLAGS+= $(CXXFLAGS)
1067
endif
1068
ifneq (,$(LDFLAGS))
1069
    LINKERFLAGS+= $(LDFLAGS)
1070
endif
1071
4543 hendricks2 1072
 
1073
RECIPE_IF = if
1074
BUILD_SETTINGS_COMPILER = \033[1;36mcompiler: \033[0;36m\"$(COMPILER) $(COMMONFLAGS) $(COMPILERFLAGS)\"
1075
BUILD_SETTINGS_ASSEMBLER = \033[1;36massembler: \033[0;36m\"$(AS) $(ASFLAGS)\"
1076
BUILD_SETTINGS_LINKER = \033[1;36mlinker: \033[0;36m\"$(LINKER) $(COMMONFLAGS) $(LINKERFLAGS) $(LIBDIRS) $(LIBS) $(STATICSTDCPP) $(STDCPPLIB)\"
1077
ifeq (0,$(NOASM))
1078
    BUILD_SETTINGS = printf "$(BUILD_SETTINGS_COMPILER)\n$(BUILD_SETTINGS_ASSEMBLER)\n$(BUILD_SETTINGS_LINKER)\033[0m\n"
1079
else
1080
    BUILD_SETTINGS = printf "$(BUILD_SETTINGS_COMPILER)\n$(BUILD_SETTINGS_LINKER)\033[0m\n"
1081
endif
1082
BUILD_STARTED = printf "\033[K\033[1;36mBuild started using:\033[0m\n"; $(BUILD_SETTINGS)
1083
BUILD_ECHOFLAGS = printf "\033[K\033[1;36mEnded compilation in this directory using:\n$(BUILD_SETTINGS_COMPILER)\033[0m\n"
1084
BUILD_FINISHED = printf "\033[K\033[1;36mBuild successful:\033[0m\n"
1085
COMPILE_STATUS = printf "\033[K\033[0mBuilding object \033[1m$@\033[0m...\033[0m\r"
1086
COMPILE_OK = printf "\033[K\033[0;32mBuilt object \033[1;32m$@\033[0;32m \033[0m\n"
1087
COMPILE_FAILED = printf "\033[K\033[0;31mFailed building \033[1;31m$@\033[0;31m from\033[0m \033[1;31m$<\033[0;31m!\033[0m\n"; exit 1
1088
RECIPE_RESULT_COMPILE = ; then $(COMPILE_OK); else $(COMPILE_FAILED); fi
1089
ONESTEP_STATUS = printf "\033[K\033[0mBuilding executable \033[1m$@\033[0m...\033[0m\r"
1090
ONESTEP_OK = printf "\033[K\033[0;32mBuilt executable \033[1;32m$@\033[0;32m \033[0m\n"
1091
ONESTEP_FAILED = printf "\033[K\033[0;31mFailed building executable \033[1;31m$@\033[0;31m!\033[0m\n"; exit 1
1092
RECIPE_RESULT_ONESTEP = ; then $(ONESTEP_OK); else $(ONESTEP_FAILED); fi
1093
ARCHIVE_STATUS = printf "\033[K\033[0mCreating library archive \033[1m$@\033[0m...\033[0m\r"
1094
ARCHIVE_OK = printf "\033[K\033[0;32mCreated library archive \033[1;32m$@\033[0;32m \033[0m\n"
1095
ARCHIVE_FAILED = printf "\033[K\033[0;31mFailed creating library archive \033[1;31m$@\033[0;31m from\033[0m \033[1;31m$<\033[0;31m!\033[0m\n"; exit 1
1096
RECIPE_RESULT_ARCHIVE = ; then $(ARCHIVE_OK); else $(ARCHIVE_FAILED); fi
1097
LINK_STATUS = printf "\033[K\033[0;0mLinking executable \033[1m$@\033[0;0m...\033[0m\r"
1098
LINK_OK = printf "\033[K\033[0;32mLinked executable \033[1;32m$@\033[0;32m \033[0m\n"
1099
LINK_FAILED = printf "\033[K\033[0;31mFailed linking executable \033[1;31m$@\033[0;31m!\033[0m\n"; exit 1
1100
RECIPE_RESULT_LINK = ; then $(LINK_OK); else $(LINK_FAILED); fi
1101
else
1102
RECIPE_IF =
1103
BUILD_STARTED =
1104
BUILD_ECHOFLAGS =
1105
BUILD_FINISHED =
1106
COMPILE_STATUS =
1107
COMPILE_OK = true
1108
COMPILE_FAILED = false; exit 1
1109
RECIPE_RESULT_COMPILE =
1110
ONESTEP_STATUS =
1111
ONESTEP_OK = true
1112
ONESTEP_FAILED = false; exit 1
1113
RECIPE_RESULT_ONESTEP =
1114
ARCHIVE_STATUS =
1115
ARCHIVE_OK = true
1116
ARCHIVE_FAILED = false; exit 1
1117
RECIPE_RESULT_ARCHIVE =
1118
LINK_STATUS =
1119
LINK_OK = true
1120
LINK_FAILED = false; exit 1
1121
RECIPE_RESULT_LINK =
1122
endif
1123