Use bash in Makefile targets

This commit is contained in:
Raul Ochoa 2015-02-26 17:00:50 +01:00
parent f006d09f31
commit cbd44192c9
3 changed files with 15 additions and 10 deletions

View File

@ -1,5 +1,10 @@
SHELL=/bin/bash
pre-install:
@$(SHELL) ./scripts/check-node-canvas.sh
all:
@sh ./scripts/install.sh
@$(SHELL) ./scripts/install.sh
clean:
rm -rf node_modules/*
@ -15,13 +20,13 @@ config/environments/test.js: config.status--test
test: config/environments/test.js
@echo "***tests***"
./run_tests.sh ${RUNTESTFLAGS} \
test/unit/cartodb/*.js \
test/unit/cartodb/cache/model/*.js \
test/integration/*.js \
test/acceptance/*.js \
test/acceptance/cache/*.js
@$(SHELL) ./run_tests.sh ${RUNTESTFLAGS} \
test/unit/cartodb/*.js \
test/unit/cartodb/cache/model/*.js \
test/integration/*.js \
test/acceptance/*.js \
test/acceptance/cache/*.js
check: test
.PHONY: test
.PHONY: pre-install test

View File

@ -43,7 +43,7 @@
"semver": "~1.1.4"
},
"scripts": {
"preinstall": "sh ./scripts/check-node-canvas.sh",
"preinstall": "make pre-install",
"test": "make test"
},
"engines": {

View File

@ -11,7 +11,7 @@ if [[ "$OSTYPE" == "darwin"* ]]; then
echo "# #"
echo "# node-canvas install error: some packages required by 'cairo' are not found #"
echo "# #"
echo "# Use '\033[1mmake all\033[0m', it will take care of common/known issues #"
echo -e "# Use '\033[1mmake all\033[0m', it will take care of common/known issues #"
echo "# #"
echo "# As an alternative try: #"
echo "# Try to 'export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/opt/X11/lib/pkgconfig' #"