Commit | Line | Data |
---|---|---|
d44e3c4f | 1 | ############################################################################## |
2 | # Copyright (c) 2000-2016 Ericsson Telecom AB | |
970ed795 EL |
3 | # All rights reserved. This program and the accompanying materials |
4 | # are made available under the terms of the Eclipse Public License v1.0 | |
5 | # which accompanies this distribution, and is available at | |
6 | # http://www.eclipse.org/legal/epl-v10.html | |
d44e3c4f | 7 | # |
8 | # Contributors: | |
9 | # > | |
10 | # Balasko, Jeno | |
11 | # Bene, Tamas | |
12 | # Delic, Adam | |
13 | # Forstner, Matyas | |
14 | # Gecse, Roland | |
15 | # Raduly, Csaba | |
16 | # Szabados, Kristof | |
17 | # Szabo, Janos Zoltan – initial implementation | |
18 | # | |
19 | ############################################################################## | |
970ed795 EL |
20 | # Makefile for the Command Line Interface of the TTCN-3 Main Controller |
21 | ||
22 | TOP := ../.. | |
23 | include $(TOP)/Makefile.cfg | |
24 | ||
25 | TARGETS := libcli.a | |
26 | ||
27 | ORIGINATORS := config_read.l config_read.y | |
28 | ||
29 | GENERATED_SOURCES := config_read.lex.cc config_read.tab.cc | |
30 | ||
31 | STATIC_SOURCES := Cli.cc | |
32 | ||
33 | SOURCES := $(STATIC_SOURCES) $(GENERATED_SOURCES) | |
34 | ||
35 | GENERATED_HEADERS := config_read.tab.hh | |
36 | ||
37 | GENERATED_OTHERS := config_read.output lex.backup | |
38 | ||
39 | OBJECTS := $(patsubst %.cc,%.o,$(patsubst %.c,%.o,$(SOURCES))) | |
40 | ||
41 | DEPFILES := $(patsubst %.cc,%.d,$(patsubst %.c,%.d,$(SOURCES))) | |
42 | ||
43 | CPPFLAGS += -D_REENTRANT | |
44 | ||
45 | ifdef OPENSSL_DIR | |
46 | ifneq ($(OPENSSL_DIR), default) | |
47 | CPPFLAGS += -I$(OPENSSL_DIR)/include | |
48 | LDFLAGS += -L$(OPENSSL_DIR)/lib | |
49 | endif | |
50 | endif | |
51 | ||
52 | ifeq ($(findstring g++, $(CXX)), g++) | |
53 | CXXFLAGS += -fno-exceptions | |
54 | endif | |
55 | ||
56 | all run: $(TARGETS) | |
57 | ||
58 | libcli.a: $(OBJECTS) | |
59 | $(AR) -r $@ $? | |
60 | ||
61 | config_read.lex.cc: config_read.l | |
62 | $(FLEX) $(FLEXFLAGS) -Pconfig_read_ -o$@ $< | |
63 | ||
64 | config_read.tab.cc config_read.tab.hh: config_read.y | |
65 | $(BISON) $(BISONFLAGS) -o config_read.tab.cc -p config_read_ $< | |
66 | ||
67 | include ../../Makefile.genrules |