From ab42c0cf936758192f384589e80b4c9693d1146d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Tue, 21 Oct 2014 12:49:19 +0200 Subject: [PATCH] cleanup makefile [skip ci] --- .travis.yml | 7 ++---- Makefile | 22 ++++++++----------- configure | 4 ++++ ...nstall.sh => travis_install_test_suite.sh} | 0 4 files changed, 15 insertions(+), 18 deletions(-) rename scripts/{travis_install.sh => travis_install_test_suite.sh} (100%) diff --git a/.travis.yml b/.travis.yml index 42cca837c..3e34bace7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,11 +28,8 @@ before_install: - ./scripts/travis_before_install.sh install: -- make setup -- ./scripts/travis_install.sh - -before_script: -- rm -rf mapnik-packaging/out/packages +- make config.gypi +- ./scripts/travis_install_test_suite.sh script: - ./scripts/travis_script.sh diff --git a/Makefile b/Makefile index a9c24ffdb..2e740f38e 100644 --- a/Makefile +++ b/Makefile @@ -2,15 +2,13 @@ BUILDTYPE ?= Release PYTHON ?= python V ?= 1 -all: setup +all: mbgl -setup: config.gypi +config.gypi: + ./configure -xlibs: - @./mapnik-packaging/osx/darwin_configure.sh osx - -ilibs: - MASON_PLATFORM=ios ./configure +config-ios.gypi: + MASON_PLATFORM=ios ./configure config-ios.gypi # Builds the regular library mbgl: config.gypi mapboxgl.gyp node @@ -74,14 +72,14 @@ clear_xcode_cache: fi # build Mac OS X project for Xcode -xproj-cli: config.gypi xlibs macosx/mapboxgl-app.gyp clear_xcode_cache node +xproj-cli: config.gypi macosx/mapboxgl-app.gyp clear_xcode_cache node deps/run_gyp macosx/mapboxgl-app.gyp --depth=. --generator-output=./build -f xcode xproj: xproj-cli open ./build/macosx/mapboxgl-app.xcodeproj # build iOS project for Xcode -iproj-cli: ilibs config.gypi ios/mapbox-gl-cocoa/app/mapboxgl-app.gyp clear_xcode_cache node +iproj-cli: config-ios.gypi ios/mapbox-gl-cocoa/app/mapboxgl-app.gyp clear_xcode_cache node deps/run_gyp ios/mapbox-gl-cocoa/app/mapboxgl-app.gyp --depth=. --generator-output=./build -f xcode iproj: iproj-cli @@ -98,12 +96,10 @@ lproj: config.gypi linux/mapboxgl-app.gyp clear_xcode_cache node clean: clear_xcode_cache -find ./deps/gyp -name "*.pyc" -exec rm {} \; -rm -rf ./build/ - -rm -rf ./config.gypi + -rm -rf ./config.gypi ./config-ios.gypi distclean: clean - -rm -rf ./mapnik-packaging/osx/out/build-* - -rm -rf ./mapnik-packaging/osx/out/universal - -find ./mapnik-packaging/osx/out/packages -type d ! -name 'packages' -maxdepth 1 -exec rm -rf {} \; + -rm -rf ./mason_packages .PHONY: mbgl test linux build/test/Makefile # DO NOT DELETE diff --git a/configure b/configure index dc32be135..e94369051 100755 --- a/configure +++ b/configure @@ -3,6 +3,8 @@ set -e set -o pipefail +CONFIG_FILE=${1:-config.gypi} + . ~/.nvm/nvm.sh nvm use 0.10 @@ -30,11 +32,13 @@ if [ -z "${BOOST_ROOT}" ]; then BOOST_ROOT='/usr' else >&2 echo -e "\033[1m\033[31mCannot find Boost\033[0m"; + exit 1 fi fi if [ ! -d "${BOOST_ROOT}/include/boost" ]; then >&2 echo -e "\033[1m\033[31mCannot find Boost at ${BOOST_ROOT}\033[0m"; + exit 1 else >&2 echo -e "\033[1m\033[32m* Using Boost installation at ${BOOST_ROOT}\033[0m"; fi diff --git a/scripts/travis_install.sh b/scripts/travis_install_test_suite.sh similarity index 100% rename from scripts/travis_install.sh rename to scripts/travis_install_test_suite.sh