summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2020-02-11 21:41:24 -0500
committerSolomon Peachy <pizza@shaftnet.org>2020-02-11 21:41:24 -0500
commitad6e6cb24c29f86956f70b77f48d35e6f81f27a9 (patch)
tree63dddcfdbdebff69bca30a9853161c245e963e1e
parent7f52b370ba9233e34a99c87b9576603119786cb1 (diff)
downloadselphy_print-ad6e6cb24c29f86956f70b77f48d35e6f81f27a9.tar.gz
selphy_print-ad6e6cb24c29f86956f70b77f48d35e6f81f27a9.tar.bz2
selphy_print-ad6e6cb24c29f86956f70b77f48d35e6f81f27a9.zip
build: Handle a lack of gutenprint headers a little more gracefully
-rw-r--r--Makefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 34246d9..1e995ea 100644
--- a/Makefile
+++ b/Makefile
@@ -43,10 +43,12 @@ endif
# Figure out what the backend name needs to be
ifeq ($(NO_GUTENPRINT),)
GUTENPRINT_INCLUDE := $(shell pkg-config --variable=includedir gutenprint)/gutenprint
+ifneq (,$(GUTENPRINT_INCLUDE))
GUTENPRINT_MAJOR := $(shell grep 'define STP_MAJOR' $(GUTENPRINT_INCLUDE)/gutenprint-version.h | tr -d '()\t' | cut -c33- )
GUTENPRINT_MINOR := $(shell grep 'define STP_MINOR' $(GUTENPRINT_INCLUDE)/gutenprint-version.h | tr -d '()\t' | cut -c33- )
BACKEND_NAME ?= gutenprint$(GUTENPRINT_MAJOR)$(GUTENPRINT_MINOR)+usb
endif
+endif
# For Gutenprint 5.2, use old URI scheme
ifneq ($(GUTENPRINT_MINOR),3)