blob: f77c493b803c7ff15c539841526969074ae218d9 [file] [log] [blame]
Mark Slee8d7e1f62006-06-07 06:48:56 +00001# Makefile for Thrift C++ library. Generates a shared object that can be
2# installed to /usr/local/lib
3#
4# TODO(mcslee): Add the ability to compile separate statis modules that can
5# be compiled directly into Thrift applications instead of dynamic runtime
6# loading of the full libs
Mark Sleee8540632006-05-30 09:24:40 +00007#
8# Author:
9# Mark Slee <mcslee@facebook.com>
10
11target: libthrift
12
13# Tools
14LD = g++
15LDFL = -shared -Wall -I. -fPIC -Wl,-soname=libthrift.so
16
17# Source files
Mark Slee8d7e1f62006-06-07 06:48:56 +000018SRCS = protocol/TBinaryProtocol.cc \
19 transport/TBufferedTransport.cc \
Mark Sleee8540632006-05-30 09:24:40 +000020 transport/TSocket.cc \
Mark Slee8d7e1f62006-06-07 06:48:56 +000021 transport/TServerSocket.cc \
22 server/TSimpleServer.cc
Mark Sleee8540632006-05-30 09:24:40 +000023
24# Linked library
25libthrift:
26 $(LD) -o libthrift.so $(LDFL) $(SRCS)
27
Mark Slee8d7e1f62006-06-07 06:48:56 +000028# Clean it up
Mark Sleee8540632006-05-30 09:24:40 +000029clean:
30 rm -f libthrift.so
31
32# Install
33install: libthrift
34 sudo install libthrift.so /usr/local/lib