Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(250)

Unified Diff: Makefile

Issue 6508016: vpn-manager: Add l2tp/ipsec vpn manager (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/vpn-manager.git@master
Patch Set: respond to petkov Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LICENSE ('k') | bin/pluto_updown » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Makefile
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000000000000000000000000000000000000..c2f44e411da79d93fd07e58e8cf1e52a3fa1634a
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,47 @@
+# Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+BINS = l2tpipsec_vpn
+IPSEC_STARTER = /usr/libexec/ipsec/starter
+IPSEC_WHACK = /usr/libexec/ipsec/whack
+IPSEC_UPDOWN = /usr/libexec/l2tpipsec_vpn/pluto_updown
+L2TPD = /usr/sbin/xl2tpd
+L2TPIPSEC_OBJS = \
+ ipsec_manager.o \
+ l2tp_manager.o \
+ service_manager.o
+TEST_OBJS = $(L2TPIPSEC_OBJS)
+TEST_BINS = \
+ ipsec_manager_test \
+ l2tp_manager_test \
+ service_manager_test
+
+LDCONFIG = $(shell $(PKG_CONFIG) --libs libpcrecpp)
+
+# -lglib-2.0 is needed by libbase.a now.
+COMMON_LIBS = -lchromeos -lbase -lpthread -lglib-2.0 -lgflags -lrt $(LDCONFIG)
+
+TEST_LIBS = $(COMMON_LIBS) -lgtest -lgmock
+INCLUDE_DIRS = -I..
+
+CXXFLAGS += -Wall -Werror -DIPSEC_STARTER=\"$(IPSEC_STARTER)\" \
+ -DIPSEC_WHACK=\"$(IPSEC_WHACK)\" \
+ -DIPSEC_UPDOWN=\"$(IPSEC_UPDOWN)\" \
+ -DL2TPD=\"$(L2TPD)\"
+
+all: $(BINS)
+
+l2tpipsec_vpn: l2tpipsec_vpn.o $(L2TPIPSEC_OBJS)
+ $(CXX) $(CXXFLAGS) $^ $(COMMON_LIBS) -o $@
+
+tests: $(TEST_BINS)
+
+%_test: %_test.o $(TEST_OBJS)
+ $(CXX) $(CXXFLAGS) $(LIB_DIRS) $^ $(TEST_LIBS) -o $@
+
+.cc.o:
+ $(CXX) $(CXXFLAGS) $(INCLUDE_DIRS) -c $< -o $@
+
+clean:
+ rm -rf *.o $(BINS) $(TEST_BINS)
« no previous file with comments | « LICENSE ('k') | bin/pluto_updown » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698