blob: b22fd27ffe55bed1ed9e3a0e0284132d96646f28 [file] [log] [blame]
jat@google.com134be542009-08-03 15:30:11 +00001# Copyright 2009 Google Inc.
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may not
4# use this file except in compliance with the License. You may obtain a copy of
5# the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations under
13# the License.
14
15include ../config.mk
16
17HDRS= HostChannel.h InvokeMessage.h LoadModuleMessage.h Message.h \
18 ReturnMessage.h Value.h BrowserChannel.h Debug.h DebugLevel.h \
19 SessionHandler.h ServerMethods.h Socket.h AllowedConnections.h \
20 LoadJsniMessage.h InvokeSpecialMessage.h FreeValueMessage.h \
21 ByteOrder.h
22
23SRCS= HostChannel.cpp LoadModuleMessage.cpp InvokeMessage.cpp \
24 ReturnMessage.cpp ServerMethods.cpp Debug.cpp Socket.cpp \
25 AllowedConnections.cpp LoadJsniMessage.cpp InvokeSpecialMessage.cpp \
26 FreeValueMessage.cpp
27
28LIBCOMMON= libcommon$(FLAG32BIT).a
29OBJDIR= obj$(FLAG32BIT)
30OBJS= $(patsubst %.cpp,$(OBJDIR)/%.o,$(SRCS))
31
32all:: $(OBJDIR) $(LIBCOMMON)
33
34$(OBJDIR):
35 -mkdir $@
36
37$(LIBCOMMON): $(OBJS)
38 $(AR) $(ARFLAGS) $@ $(OBJS)
39
40$(OBJDIR)/%.o: %.cpp
41 $(CXX) $(CXXFLAGS) -c $< -o $@
42
43.PHONY: clean depend testdebug
44
45testdebug:
46 (cd testing; CXX=$(CXX) CXXFLAGS="$(CFLAGS) -m32" ./testdebug)
47 (cd testing; CXX=$(CXX) CXXFLAGS="$(CFLAGS) -m64" ./testdebug)
48
49clean:
50 rm -rf obj32 obj64 libcommon32.a libcommon64.a
51
52depend:
53 g++ -MM $(CFLAGS) $(SRCS) >>Makefile
54# makedepend -- $(CFLAGS) -- $(SRCS)
55
56# DO NOT DELETE
57HostChannel.o: HostChannel.cpp Debug.h Platform.h DebugLevel.h \
58 ByteOrder.h FreeValueMessage.h Message.h BrowserChannel.h HostChannel.h \
59 Socket.h AllowedConnections.h ReturnMessage.h Value.h SessionHandler.h \
60 LoadJsniMessage.h InvokeMessage.h InvokeSpecialMessage.h QuitMessage.h \
61 scoped_ptr/scoped_ptr.h
62LoadModuleMessage.o: LoadModuleMessage.cpp Debug.h Platform.h \
63 DebugLevel.h LoadModuleMessage.h Message.h BrowserChannel.h \
64 HostChannel.h ByteOrder.h Socket.h AllowedConnections.h ReturnMessage.h \
65 Value.h SessionHandler.h scoped_ptr/scoped_ptr.h
66InvokeMessage.o: InvokeMessage.cpp InvokeMessage.h Message.h \
67 BrowserChannel.h Value.h Debug.h Platform.h DebugLevel.h HostChannel.h \
68 ByteOrder.h Socket.h AllowedConnections.h ReturnMessage.h \
69 SessionHandler.h scoped_ptr/scoped_ptr.h
70ReturnMessage.o: ReturnMessage.cpp ReturnMessage.h Message.h \
71 BrowserChannel.h Value.h Debug.h Platform.h DebugLevel.h HostChannel.h \
72 ByteOrder.h Socket.h AllowedConnections.h SessionHandler.h
73ServerMethods.o: ServerMethods.cpp Debug.h Platform.h DebugLevel.h \
74 FreeValueMessage.h Message.h BrowserChannel.h HostChannel.h ByteOrder.h \
75 Socket.h AllowedConnections.h ReturnMessage.h Value.h SessionHandler.h \
76 InvokeMessage.h InvokeSpecialMessage.h ServerMethods.h \
77 scoped_ptr/scoped_ptr.h
78Debug.o: Debug.cpp Debug.h Platform.h DebugLevel.h
79Socket.o: Socket.cpp Platform.h Socket.h Debug.h DebugLevel.h
80AllowedConnections.o: AllowedConnections.cpp Debug.h Platform.h \
81 DebugLevel.h AllowedConnections.h
82LoadJsniMessage.o: LoadJsniMessage.cpp LoadJsniMessage.h Message.h \
83 BrowserChannel.h HostChannel.h Debug.h Platform.h DebugLevel.h \
84 ByteOrder.h Socket.h AllowedConnections.h ReturnMessage.h Value.h \
85 SessionHandler.h
86InvokeSpecialMessage.o: InvokeSpecialMessage.cpp InvokeSpecialMessage.h \
87 Message.h BrowserChannel.h SessionHandler.h Value.h Debug.h Platform.h \
88 DebugLevel.h HostChannel.h ByteOrder.h Socket.h AllowedConnections.h \
89 ReturnMessage.h scoped_ptr/scoped_ptr.h
90FreeValueMessage.o: FreeValueMessage.cpp FreeValueMessage.h Message.h \
91 BrowserChannel.h HostChannel.h Debug.h Platform.h DebugLevel.h \
92 ByteOrder.h Socket.h AllowedConnections.h ReturnMessage.h Value.h \
93 SessionHandler.h scoped_ptr/scoped_ptr.h