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
|
#----------------------------------------------------------------------------
# $Id$
#
# Top-level Makefile for the TAO IDL compiler
#----------------------------------------------------------------------------
ifndef TAO_ROOT
TAO_ROOT = $(ACE_ROOT)/TAO
endif # ! TAO_ROOT
MAKEFILE = Makefile
#----------------------------------------------------------------------------
# Include macros
#----------------------------------------------------------------------------
include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU
ifeq ($(CROSS-COMPILE),)
include $(ACE_ROOT)/include/makeinclude/macros.GNU
include $(TAO_ROOT)/rules.tao.GNU
endif # ! CROSS-COMPILE
#----------------------------------------------------------------------------
# Define local rules and targets
#---------------------------------------------------------------------------
ifneq ($(CROSS-COMPILE),)
all default_embedded:
@echo The IDL compiler won\'t run or build on CROSS-COMPILE platforms.
clean realclean:
@echo Nothing to clean in TAO_IDL on CROSS-COMPILE platforms.
else # ! CROSS-COMPILE
MKLIST = \
Makefile.FE \
Makefile.BE \
Makefile.EXE \
Makefile.dependencies
all debug profile optimize install deinstall clean realclean clobber depend:
ifeq (Windows,$(findstring Windows,$(OS)))
@cmd /c "FOR /D %m IN ($(MKLIST)) DO $(MAKE) -f %m MAKEFILE=$$m $(@:.nested=)"
else # ! Windows
@for m in $(MKLIST); do \
echo $$m; \
$(MAKE) -f $$m MAKEFILE=$$m $(@:.nested=); \
done
endif # ! Windows
endif # ! CROSS-COMPILE
fe/fe_lookup.cpp: fe/keywords.dat
$(RM) fe/fe_lookup.cpp
echo "// \$$Id\$$" > fe/fe_lookup.cpp
echo "#include \"idl.h\"" >> fe/fe_lookup.cpp
echo "#include \"idl_extern.h\"" >> fe/fe_lookup.cpp
echo "#include \"fe_private.h\"" >> fe/fe_lookup.cpp
$(ACE_ROOT)/bin/gperf -M -J -c -C -D -E -T -f 0 -a -o -t -p -K keyword_ \
-L C++ -Z TAO_IDL_CPP_Keyword_Table -N lookup -k1,2,$$ fe/keywords.dat \
>> fe/fe_lookup.cpp
fe/lex.yy.cpp: fe/idl.ll
@echo "WARNING: Potentially outdated fe/lex.yy.cpp"
@echo " either touch(1) the file or explicitly"
@echo " generate it using:"
@echo " make lex.yy.cpp.target"
.PHONY: lex.yy.cpp.target
# For DOC group use
YACC = /home/cs/faculty/schmidt/bin/SunOS5/yacc
lex.yy.cpp.target:
$(LEX) -t fe/idl.ll | \
sed -e "s/yy/tao_yy/g" \
-e "s/YY/TAO_YY/g" \
-e "s@#include <unistd\.h>@#include \"ace/OS.h\"@" \
-e "/#include </d" \
-e "s@ECHO@TAO_YY_ECHO@" \
-e 's/\$$Hea''der.*\$$/$$I''d$$/' > fe/lex.yy.cpp
(cd fe ; patch < lex.yy.cpp.diff)
fe/y.tab.cpp: fe/idl.yy
@echo "WARNING: Potentially outdated fe/y.tab.cpp"
@echo " either touch(1) the file or explicitly"
@echo " generate it using:"
@echo " make y.tab"
.PHONY: y.tab
y.tab: fe/idl.yy
$(YACC) -d fe/idl.yy
sed -e 's/char \*getenv/char *ace_foo/g' \
-e 's/= getenv/= ACE_OS::getenv/g' \
-e 's/int yynew_state,/int,/g' \
-e 's/int yyold_state,/int,/g' \
-e 's/int yyrule_num,/int,/g' \
-e 's/\(YYDEBUG_DISCARD_TOKEN.*int\) yytoken_num/\1/g' \
-e 's/yynewerror://g' \
-e 's/yy/tao_yy/g' \
-e 's/YY/TAO_YY/g' \
-e 's/y\.tab\.c/y.tab.cpp/g' \
-e 's%\(#pragma ident\)%// \1%' < y.tab.c > /tmp/$(USER).Y
sed -e 's/yy/tao_yy/g' \
-e 's/YY/TAO_YY/g' < y.tab.h > /tmp/$(USER).YH
echo '// $$I''d$$' > fe/y.tab.cpp
cat /tmp/$(USER).Y >> fe/y.tab.cpp
echo '// $$I''d$$' > fe/y.tab.h
cat /tmp/$(USER).YH >> fe/y.tab.h
$(RM) /tmp/$(USER).Y /tmp/$(USER).YH y.tab.c y.tab.h
(cd fe ; patch < y.tab.cpp.diff)
tags:
$(RM) TAGS
find . -name "*.h" -print | etags -a --c++ -
find . -name "*.cpp" -print | etags -a -
#----------------------------------------------------------------------------
# Dependencies
#----------------------------------------------------------------------------
# DO NOT DELETE THIS LINE -- g++dep uses it.
# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
|