File: Makefile

package info (click to toggle)
eclipse-titan 6.5.0-1
  • links: PTS
  • area: main
  • in suites: buster
  • size: 101,128 kB
  • sloc: cpp: 259,139; ansic: 47,560; yacc: 22,554; makefile: 14,074; sh: 12,630; lex: 9,101; xml: 5,362; java: 4,849; perl: 3,784; awk: 48; php: 32; python: 13
file content (137 lines) | stat: -rw-r--r-- 3,673 bytes parent folder | download
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
##############################################################################
# Copyright (c) 2000-2018 Ericsson Telecom AB
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public License v2.0
# which accompanies this distribution, and is available at
# https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
#
# Contributors:
#   
#   Baji, Laszlo
#   Balasko, Jeno
#   Baranyi, Botond
#   Beres, Szabolcs
#   Csondes, Tibor
#   Delic, Adam
#   Forstner, Matyas
#   Kovacs, Ferenc
#   Ormandi, Matyas
#   Raduly, Csaba
#   Szabo, Janos Zoltan – initial implementation
#   Zalanyi, Balazs Andor
#
##############################################################################
# Makefile for the common directory of the TTCN-3 Test Executor

TOP := ..
include $(TOP)/Makefile.cfg

TARGETS :=

# The origin of GENERATED_SOURCES
ORIGINATORS := pattern_la.l  pattern_p.y  pattern_uni.y  config_preproc_la.l config_preproc_p.y

GENERATED_SOURCES := pattern_la.cc pattern_p.cc pattern_uni.cc config_preproc_la.cc config_preproc_p.tab.cc

# Sources in the CVS

STATIC_SOURCES := memory.c new.cc userinfo.c path.c config_preproc.cc Quadruple.cc \
		  Path2.cc ModuleVersion.cc JSON_Tokenizer.cc UnicharPattern.cc openssl_version.c

ifndef MINGW
STATIC_SOURCES += NetworkHandler.cc
endif

ifeq ($(USAGE_STATS), yes)
  STATIC_SOURCES += usage_stats.cc
endif

ifeq ($(LICENSING), yes)
  STATIC_SOURCES += license.c
  ifeq ($(PLATFORM), WIN32)
    STATIC_SOURCES += hostid.c
    TARGETS += hostid$(EXESUFFIX)
  endif
  ifeq ($(PLATFORM), INTERIX)
    STATIC_SOURCES += hostid.c
    TARGETS += hostid$(EXESUFFIX)
  endif
endif

SOURCES := $(STATIC_SOURCES) $(GENERATED_SOURCES)

GENERATED_HEADERS := pattern_p.hh pattern_uni.hh config_preproc_p.tab.hh

GENERATED_OTHERS := pattern_p.output pattern_uni.output lex.backup

OBJECTS := $(patsubst %.cc,%.o,$(patsubst %.c,%.o,$(SOURCES)))

DEPFILES := $(patsubst %.cc,%.d,$(patsubst %.c,%.d,$(SOURCES)))

SUBDIRS :=

CPPFLAGS += -D_REENTRANT

ifdef REGEX_DIR
  CPPFLAGS += -I$(REGEX_DIR)/include
endif

all run: $(OBJECTS) $(TARGETS)

install: $(OBJECTS) $(TARGETS)
ifdef MINGW
	@echo Skipped ${CURDIR} for MinGW
else
	mkdir -p $(INCDIR)
	cp version.h memory.h platform.h ttcn3float.hh pattern.hh CharCoding.hh JSON_Tokenizer.hh $(INCDIR)
ifeq ($(DEBUG), yes)
	cp dbgnew.hh $(INCDIR)
endif
ifneq ($(TARGETS), )
  ifeq ($(DEBUG), no)
	$(STRIP) $(TARGETS)
  endif
	mkdir -p $(BINDIR)
	cp $(TARGETS) $(BINDIR)
endif
endif

hostid$(EXESUFFIX): hostid.o license.o memory.o
	$(CC) $(LDFLAGS) -o $@ $^ $(LICENSE_LIBS) $(MINGW_LIBS)

pattern_la.cc: pattern_la.l
	$(FLEX) $(FLEXFLAGS) -o$@ $<

pattern_p.cc pattern_p.hh: pattern_p.y
	$(BISON) $(BISONFLAGS) $<

pattern_uni.cc pattern_uni.hh: pattern_uni.y
	$(BISON) $(BISONFLAGS) $<

config_preproc_la.cc: config_preproc_la.l
	$(FLEX) $(FLEXFLAGS) -o$@ $<

config_preproc_p.tab.cc config_preproc_p.tab.hh: config_preproc_p.y
	$(BISON) $(BISONFLAGS) -o config_preproc_p.tab.cc -p config_process_ $<

# Target-specific variable alteration
# Target-specific += causes make 3.79.1 to crash, hence this old style
ifdef OPENSSL_DIR
ifneq ($(OPENSSL_DIR), default)
license.o license.d: CPPFLAGS := $(CPPFLAGS) -I$(OPENSSL_DIR)/include
openssl_version.o openssl_version.d: CPPFLAGS := $(CPPFLAGS) -I$(OPENSSL_DIR)/include
endif
endif

include ../Makefile.genrules


#vpath pattern_la.l        $(ABS_SRC)
#vpath pattern_p.y         $(ABS_SRC)
#vpath pattern_uni_lex.l   $(ABS_SRC)
#vpath pattern_uni.y       $(ABS_SRC)
#vpath config_preproc_la.l $(ABS_SRC)
#vpath config_preproc_p.y  $(ABS_SRC)

# no vpath for GENERATED_SOURCES !