freetype/configure
Werner Lemberg bd7e1c3ce0 Pass options from one configure script to another as-is (not
expanded).  This is needed for options like
--includedir='${prefix}/include'.

* builds/unix/detect.mk, configure: Prevent argument expansion in
call to the (real) `configure' script.



* src/truetype/ttgload.c (load_truetype_glyph): Fix compilation if
TT_USE_BYTECODE_INTERPRETER isn't defined.



There exist CFFs which contain opcodes for the Type 1 operators
`hsbw' and `closepath' which are both invalid in Type 2 charstrings.
However, it doesn't harm to support them.

* src/cff/cffgload.c (CFF_Operator): Add `cff_op_hsbw' and
`cff_op_closepath.'
(cff_argument_counts): Ditto.

(cff_decoder_parse_charstrings): Handle Type 1 opcodes 9 (closepath)
and 13 (hsbw) which are invalid in Type 2 charstrings.
2007-12-06 17:17:30 +00:00

101 lines
3.1 KiB
Bash

#!/bin/sh
#
# Copyright 2002, 2003, 2004, 2005, 2006 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
# and distributed under the terms of the FreeType project license,
# LICENSE.TXT. By continuing to use, modify, or distribute this file you
# indicate that you have read the license and understand and accept it
# fully.
#
#
# Call the `configure' script located in `builds/unix'.
#
rm -f config.mk builds/unix/unix-def.mk builds/unix/unix-cc.mk
if test "x$GNUMAKE" = x; then
GNUMAKE=make
fi
if test -z "`$GNUMAKE -v 2>/dev/null | grep GNU`"; then
if test -z "`$GNUMAKE -v 2>/dev/null | grep makepp`"; then
echo "GNU make (>= 3.79.1) or makepp (>= 1.19) is required to build FreeType2." >&2
echo "Please try" >&2
echo " \`GNUMAKE=<GNU make command name> $0'." >&2
echo "or >&2"
echo " \`GNUMAKE=\"makepp --norc-substitution\" $0'." >&2
exit 1
fi
fi
# Get `dirname' functionality. This is taken and adapted from autoconf's
# m4sh.m4 (_AS_EXPR_PREPARE, AS_DIRNAME_EXPR, and AS_DIRNAME_SED).
if expr a : '\(a\)' >/dev/null 2>&1; then
ft_expr=expr
else
ft_expr=false
fi
ft2_dir=`(dirname "$0") 2>/dev/null ||
$ft_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$0" : 'X\(//\)[^/]' \| \
X"$0" : 'X\(//\)$' \| \
X"$0" : 'X\(/\)' \| \
. : '\(.\)' 2>/dev/null ||
echo X"$0" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
}
/^X\(\/\/\)[^/].*/{
s//\1/
q
}
/^X\(\/\/\)$/{
s//\1/
q
}
/^X\(\/\).*/{
s//\1/
q
}
s/.*/./; q'`
abs_curr_dir=`pwd`
abs_ft2_dir=`cd "$ft2_dir" && pwd`
# build a dummy Makefile if we are not building in the source tree
if test "$abs_curr_dir" != "$abs_ft2_dir"; then
mkdir reference
echo "Copying \`modules.cfg'"
cp $abs_ft2_dir/modules.cfg $abs_curr_dir
echo "Generating \`Makefile'"
echo "TOP_DIR := $abs_ft2_dir" > Makefile
echo "OBJ_DIR := $abs_curr_dir" >> Makefile
echo "OBJ_BUILD := \$(OBJ_DIR)" >> Makefile
echo "DOC_DIR := \$(OBJ_DIR)/reference" >> Makefile
echo "LIBTOOL := \$(OBJ_DIR)/libtool" >> Makefile
echo "ifndef FT2DEMOS" >> Makefile
echo " include \$(TOP_DIR)/Makefile" >> Makefile
echo "else" >> Makefile
echo " TOP_DIR_2 := \$(TOP_DIR)/../ft2demos" >> Makefile
echo " PROJECT := freetype" >> Makefile
echo " CONFIG_MK := \$(OBJ_DIR)/config.mk" >> Makefile
echo " include \$(TOP_DIR_2)/Makefile" >> Makefile
echo "endif" >> Makefile
fi
# call make
CFG=
for x in ${1+"$@"}; do
CFG="$CFG '$x'"
done
CFG=$CFG $GNUMAKE setup unix
# eof