-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile.ut.in
80 lines (74 loc) · 2.25 KB
/
Makefile.ut.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#
# Utilities sub-Makefile
#
# Copyright (C) 2020-2024 Gabriele Galeotti
#
# This work is licensed under the terms of the MIT License.
# Please consult the LICENSE.txt file located in the top-level directory.
#
#
# Environment variables:
# OSTYPE
# EXEEXT
# SCREXT
# SCREXT_cmd
# SCREXT_unx
#
ifeq ($(OSTYPE),cmd)
ELFTOOL := elftool-win$(EXEEXT)
GCC_WRAPPER := gcc-wrapper-win$(EXEEXT)
GNAT_WRAPPER := gnat-wrapper-win$(EXEEXT)
else ifeq ($(OSTYPE),msys)
ELFTOOL := elftool-win$(EXEEXT)
GCC_WRAPPER := gcc-wrapper-win$(EXEEXT)
GNAT_WRAPPER := gnat-wrapper-win$(EXEEXT)
else ifeq ($(OSTYPE),darwin)
ELFTOOL := elftool-osx$(EXEEXT)
GCC_WRAPPER := gcc-wrapper-osx$(EXEEXT)
GNAT_WRAPPER := gnat-wrapper-osx$(EXEEXT)
else ifeq ($(OSTYPE),linux)
ELFTOOL := elftool-lnx$(EXEEXT)
GCC_WRAPPER := gcc-wrapper-lnx$(EXEEXT)
GNAT_WRAPPER := gnat-wrapper-lnx$(EXEEXT)
else
$(error Error: no valid executables for OSTYPE '$(OSTYPE)')
endif
ifeq ($(OSTYPE),msys)
CREATECONFIGUREGPR := createconfiguregpr$(SCREXT_cmd)
CREATEGNATADC := creategnatadc$(SCREXT_cmd)
CREATESYMLINK := createsymlink$(SCREXT_cmd)
DOS2UNIX := dos2unix$(SCREXT_cmd)
FILEPAD := filepad$(SCREXT_cmd)
FILEPATCH := filepatch$(SCREXT_cmd)
GCCDEFINES := gccdefines$(SCREXT_cmd)
GPRBINDFILT := gprbindfilt$(SCREXT_cmd)
GPRDEPS := gprdeps$(SCREXT_cmd)
PROCESSCFG := processcfg$(SCREXT_cmd)
RMSYMLINK := rmsymlink$(SCREXT_cmd)
UPDATETM := updatetm$(SCREXT_cmd)
else
CREATECONFIGUREGPR := createconfiguregpr$(SCREXT)
CREATEGNATADC := creategnatadc$(SCREXT)
CREATESYMLINK := createsymlink$(SCREXT)
FILEPAD := filepad$(SCREXT)
FILEPATCH := filepatch$(SCREXT)
GCCDEFINES := gccdefines$(SCREXT)
GPRBINDFILT := gprbindfilt$(SCREXT)
GPRDEPS := gprdeps$(SCREXT)
PROCESSCFG := processcfg$(SCREXT)
RMSYMLINK := rmsymlink$(SCREXT)
ifeq ($(OSTYPE),cmd)
DOS2UNIX := dos2unix$(SCREXT)
UPDATETM := updatetm$(SCREXT)
endif
endif
# needed by GPRbuild
export GCC_WRAPPER
# needed by RTS Makefile
export PROCESSCFG
# needed by Makefile.lb.in
export UPDATETM
# useful utilities in user scripts
export FILEPAD FILEPATCH
# useful utility
export DOS2UNIX