OLD | NEW |
1 HOST_ARCH :=$(shell python third_party/detect_v8_host_arch.py) | 1 HOST_ARCH :=$(shell python third_party/detect_v8_host_arch.py) |
2 | 2 |
3 ifndef HOST_OS | 3 ifndef HOST_OS |
4 raw_OS = $(shell uname -s) | 4 raw_OS = $(shell uname -s) |
5 ifeq (${raw_OS},Linux) | 5 ifeq (${raw_OS},Linux) |
6 HOST_OS=linux | 6 HOST_OS=linux |
| 7 TRAVIS_OS_NAME=linux |
7 else ifeq (${raw_OS},Darwin) | 8 else ifeq (${raw_OS},Darwin) |
8 HOST_OS=mac | 9 HOST_OS=mac |
| 10 TRAVIS_OS_NAME=osx |
9 endif | 11 endif |
10 endif | 12 endif |
11 | 13 |
| 14 # Default V8 directories |
| 15 LIBV8_INCLUDE_DIR ?= $(shell pwd -L)/third_party/prebuilt-v8/include |
| 16 LIBV8_LIB_DIR ?= $(shell pwd -L)/third_party/prebuilt-v8/ |
| 17 |
12 TARGET_OS ?= ${HOST_OS} | 18 TARGET_OS ?= ${HOST_OS} |
13 TARGET_ARCH ?= ${HOST_ARCH} | 19 TARGET_ARCH ?= ${HOST_ARCH} |
14 Configuration ?= debug | 20 Configuration ?= debug |
15 | 21 |
16 BUILD_DIR ?=$(shell pwd -L)/build | 22 BUILD_DIR ?=$(shell pwd -L)/build |
17 | 23 |
18 ifeq (${TARGET_OS},android) | 24 ifeq (${TARGET_OS},android) |
19 Configuration ?= release | 25 Configuration ?= release |
20 ANDROID_PLATFORM_LEVEL=android-16 | 26 ANDROID_PLATFORM_LEVEL=android-16 |
21 ANDROID_FIXES= | 27 ANDROID_FIXES= |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 test: all | 65 test: all |
60 ifdef FILTER | 66 ifdef FILTER |
61 $(TEST_EXECUTABLE) --gtest_filter=$(FILTER) | 67 $(TEST_EXECUTABLE) --gtest_filter=$(FILTER) |
62 else | 68 else |
63 $(TEST_EXECUTABLE) | 69 $(TEST_EXECUTABLE) |
64 endif | 70 endif |
65 | 71 |
66 docs: | 72 docs: |
67 doxygen | 73 doxygen |
68 | 74 |
| 75 get-prebuilt-v8: |
| 76 URL_PREFIX="https://v8.eyeofiles.com/v8-4fc9a2fe7f8a7ef1e7966185b39b3b54
1792669a/" \ |
| 77 TARGET_OS=${TARGET_OS} TARGET_ARCH=${TARGET_ARCH} \ |
| 78 TRAVIS_OS_NAME=${TRAVIS_OS_NAME} Configuration=${Configuration} \ |
| 79 bash .travis/prepare-prebuilt-v8.sh |
| 80 |
69 clean: | 81 clean: |
70 $(RM) -r ${BUILD_DIR} docs | 82 $(RM) -r ${BUILD_DIR} docs |
71 | 83 |
72 ifeq ($(TARGET_OS),android) | 84 ifeq ($(TARGET_OS),android) |
73 all: ensure_dependencies | 85 all: ensure_dependencies |
74 GYP_DEFINES="${GYP_PARAMETERS}" \ | 86 GYP_DEFINES="${GYP_PARAMETERS}" \ |
75 python ./make_gyp_wrapper.py --depth=. -f make-android -Ilibadblockplus.
gypi --generator-output=${BUILD_DIR} -Gandroid_ndk_version=r16b libadblockplus.g
yp | 87 python ./make_gyp_wrapper.py --depth=. -f make-android -Ilibadblockplus.
gypi --generator-output=${BUILD_DIR} -Gandroid_ndk_version=r16b libadblockplus.g
yp |
76 $(ANDROID_NDK_ROOT)/ndk-build -C ${BUILD_DIR} installed_modules \ | 88 $(ANDROID_NDK_ROOT)/ndk-build -C ${BUILD_DIR} installed_modules \ |
77 BUILDTYPE=Release \ | 89 BUILDTYPE=Release \ |
78 APP_ABI=$(ANDROID_ABI) \ | 90 APP_ABI=$(ANDROID_ABI) \ |
79 APP_PLATFORM=${ANDROID_PLATFORM_LEVEL} \ | 91 APP_PLATFORM=${ANDROID_PLATFORM_LEVEL} \ |
80 APP_PIE=true \ | 92 APP_PIE=true \ |
81 APP_STL=c++_shared \ | 93 APP_STL=c++_shared \ |
82 APP_BUILD_SCRIPT=Makefile \ | 94 APP_BUILD_SCRIPT=Makefile \ |
83 NDK_PROJECT_PATH=. \ | 95 NDK_PROJECT_PATH=. \ |
84 NDK_OUT=. \ | 96 NDK_OUT=. \ |
85 ${ANDROID_FIXES} \ | 97 ${ANDROID_FIXES} \ |
86 NDK_APP_DST_DIR=android-$(TARGET_ARCH).release | 98 NDK_APP_DST_DIR=android-$(TARGET_ARCH).release |
87 else | 99 else |
88 all: ensure_dependencies | 100 all: ensure_dependencies |
89 GYP_DEFINES="${GYP_PARAMETERS}" third_party/gyp/gyp --depth=. -f make -I
libadblockplus.gypi --generator-output=${BUILD_DIR} libadblockplus.gyp | 101 GYP_DEFINES="${GYP_PARAMETERS}" third_party/gyp/gyp --depth=. -f make -I
libadblockplus.gypi --generator-output=${BUILD_DIR} libadblockplus.gyp |
90 $(MAKE) -C ${BUILD_DIR} | 102 $(MAKE) -C ${BUILD_DIR} |
91 | 103 |
92 endif | 104 endif |
OLD | NEW |