Trying to detect whether 'gperf' is installed, and if not, abort build.

This commit is contained in:
William Kendrick 2011-01-11 17:49:16 +00:00
parent f4b906181b
commit 1b6769f6a5

View file

@ -1,10 +1,10 @@
# Tux Paint - A simple drawing program for children.
# Copyright (c) 2002-2010 by Bill Kendrick and others
# Copyright (c) 2002-2011 by Bill Kendrick and others
# bill@newbreedsoftware.com
# http://www.tuxpaint.org/
# June 14, 2002 - April 27, 2010
# June 14, 2002 - January 11, 2011
# The version number, for release:
@ -960,12 +960,17 @@ obj/tuxpaint.o: src/tuxpaint.c \
obj/parse.c: obj/parse_step1.c
@echo
@echo "...Generating the command-line and config file parser (STEP 2)..."
sed -r -e 's/^const struct/static const struct/' -e 's/_GNU/_TUX/' obj/parse_step1.c > obj/parse.c
@sed -r -e 's/^const struct/static const struct/' -e 's/_GNU/_TUX/' obj/parse_step1.c > obj/parse.c
obj/parse_step1.c: src/parse.gperf
@echo
@echo "...Generating the command-line and config file parser (STEP 1)..."
@gperf src/parse.gperf > obj/parse_step1.c
@if [ -x /usr/bin/gperf ] ; then \
gperf src/parse.gperf > obj/parse_step1.c ; \
else \
echo "Please install 'gperf' and try again!" ; \
false ; \
fi
obj/parse.o: obj/parse.c src/parse.h src/compiler.h
@echo