-
-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathMakefile
60 lines (47 loc) · 1.73 KB
/
Makefile
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
# Copyright 2014 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.
export NACL_ARCH ?= pnacl
export TOOLCHAIN ?= pnacl
TOP_SRCDIR = $(CURDIR)/..
include $(TOP_SRCDIR)/third-party/settings.mk
ifndef WEBPORTS_PATH
export WEBPORTS_PATH = $(CURDIR)/webports
ifeq ($(wildcard $(WEBPORTS_PATH)/src),)
$(error WEBPORTS_PATH is not set. Install webports and set WEBPORTS_PATH)
endif
endif
LOCAL_WEBPORTS_LIBS = lz4 lzo zstd
.PHONY: libarchive-fork
libarchive-fork: local-webports-libs
$(WEBPORTS_PATH)/src/bin/webports -f install libarchive-fork
.PHONY: local-webports-libs
local-webports-libs:
$(WEBPORTS_PATH)/src/bin/webports -f install $(LOCAL_WEBPORTS_LIBS)
.PHONY: $(LOCAL_WEBPORTS_LIBS)
$(LOCAL_WEBPORTS_LIBS):
$(WEBPORTS_PATH)/src/bin/webports -f install $@
.PHONY: polymer
polymer:
cd polymer; `npm bin`/bower update -F
nacl_sdk: nacl_sdk/$(NACL_SDK_PEPPER_VERSION)
nacl_sdk/$(NACL_SDK_PEPPER_VERSION):
mkdir -p nacl_sdk
wget -c \
-O nacl_sdk/naclsdk_linux-$(NACL_SDK_VERSION).tar.bz2 \
https://storage.googleapis.com/nativeclient-mirror/nacl/nacl_sdk/$(NACL_SDK_VERSION)/naclsdk_linux.tar.bz2
tar xf nacl_sdk/naclsdk_linux-$(NACL_SDK_VERSION).tar.bz2 -C nacl_sdk
GCLIENT ?= $(abspath $(CURDIR)/depot_tools/gclient)
webports:
mkdir -p webports
cd webports && \
$(GCLIENT) config --unmanaged --name=src https://chromium.googlesource.com/webports.git && \
$(GCLIENT) sync -r src@$(NACL_SDK_PEPPER_VERSION)
depot_tools:
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
.PHONY: clean
clean:
$(WEBPORTS_PATH)/src/bin/webports clean libarchive-fork
rm -rf polymer/bower_components
.PHONY: all
all: libarchive-fork polymer