forked from RipcordSoftware/libstringintern
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
29 lines (25 loc) · 1 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
GTEST_VER=1.7.0
.PHONY: build all test clean .googletest
.NOTPARALLEL: test
build all clean : .googletest
cd src/libstringintern && $(MAKE) $@
cd src/testlibstringintern && $(MAKE) $@
test : .googletest
cd src/libstringintern && $(MAKE) $@
.googletest:
if [[ "${CI}" = "true" && "${TRAVIS_OS_NAME}" == "linux" ]]; then \
curl ftp://ftp.ripcordsoftware.com/pub/gtest-${GTEST_VER}-travis-ci-externals-installed.tar.xz -O && \
tar xfJ gtest-*; \
elif [ ! -d externals/gtest-${GTEST_VER}/lib/.libs ]; then \
mkdir -p externals && \
cd externals && \
if [ ! -f gtest-${GTEST_VER}.zip ]; then curl ftp://ftp.ripcordsoftware.com/pub/gtest-${GTEST_VER}.zip -O; fi && \
unzip gtest-${GTEST_VER}.zip && \
cd gtest-${GTEST_VER} && \
./configure && \
$(MAKE) && \
if [ ! -d "../installed/include" ]; then mkdir -p ../installed/include; fi && \
if [ ! -d "../installed/lib" ]; then mkdir -p ../installed/lib; fi && \
cp -Rf include/* ../installed/include && \
cp -Rf lib/.libs/* ../installed/lib; \
fi