diff --git a/Makefile b/Makefile index 935642f..fb78e9a 100644 --- a/Makefile +++ b/Makefile @@ -32,7 +32,7 @@ ifeq ($(shell which apt-get),) $(warning Cannot install build dependencies without apt.) $(warning Cannot install build dependencies on non-linux platforms.) else ifeq ($(wildcard /usr/include/libxml2/libxml/xpath.h),) - sudo apt-get install libxml2-dev libxslt1-dev + sudo $(APT) install libxml2-dev libxslt1-dev else ifeq ($(wildcard /usr/include/libxslt/xslt.h),) - sudo apt-get install libxslt1-dev + sudo $(APT) install libxslt1-dev endif diff --git a/common.mk b/common.mk index abbe100..4e6b0a9 100644 --- a/common.mk +++ b/common.mk @@ -7,6 +7,11 @@ DOCS=docs ifneq ($(OS),Windows_NT) OS := $(shell uname) endif +ifdef CI + APT := apt-get --yes +else + APT := apt-get +endif .DEFAULT_GOAL := help