]> git.donarmstrong.com Git - lilypond.git/blobdiff - configure
Imported Upstream version 2.19.51
[lilypond.git] / configure
index fe4de2b53c8053504bc134b8689eb2932b2925c1..f45f4faade8cde231293078caa2cb51c0ae0429c 100755 (executable)
--- a/configure
+++ b/configure
@@ -692,6 +692,8 @@ CXXCPP
 ac_ct_CXX
 CXXFLAGS
 CXX
+URWOTF_FILES
+URWOTF_DIR
 TEXGYRE_FILES
 TEXGYRE_DIR
 FCLIST
@@ -790,6 +792,7 @@ enable_config
 enable_documentation
 enable_guile2
 with_texgyre_dir
+with_urwotf_dir
 enable_relocation
 enable_rpath
 enable_static_gxx
@@ -1457,6 +1460,7 @@ Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
   --with-texgyre-dir=DIR  location of TeX Gyre fonts.
+  --with-urwotf-dir=DIR   location of URW++ OTF fonts.
   --with-localedir=DIR    location of locales. Default: PREFIX/share/locale
   --with-lang=LANG        use LANG as language to emit messages
   --with-python-include=DIR
@@ -3081,6 +3085,15 @@ else
 fi
 
 
+
+# Check whether --with-urwotf-dir was given.
+if test "${with_urwotf_dir+set}" = set; then
+  withval=$with_urwotf_dir; URWOTF_DIR=$withval
+else
+  URWOTF_DIR=""
+fi
+
+
 reloc_b=no
 # Check whether --enable-relocation was given.
 if test "${enable_relocation+set}" = set; then
@@ -4334,6 +4347,81 @@ else
   { $as_echo "$as_me:$LINENO: result: yes" >&5
 $as_echo "yes" >&6; }
 fi
+{ $as_echo "$as_me:$LINENO: checking for URW++ OTF files" >&5
+$as_echo_n "checking for URW++ OTF files... " >&6; }
+
+
+if test "$URWOTF_DIR" = ""; then
+  if test "$FCLIST" != ""; then
+    URWOTF_FILE=`$FCLIST "C059:fontformat=CFF" file | head -n 1`
+    if test "$URWOTF_FILE" != ""; then
+      URWOTF_FILE=`echo $URWOTF_FILE | sed 's/\(:.*\)$//g'`
+      URWOTF_FILE=`$PYTHON "$srcdir/scripts/auxiliar/readlink.py" $URWOTF_FILE`
+      URWOTF_DIR=`$as_dirname -- $URWOTF_FILE ||
+$as_expr X$URWOTF_FILE : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+        X$URWOTF_FILE : 'X\(//\)[^/]' \| \
+        X$URWOTF_FILE : 'X\(//\)$' \| \
+        X$URWOTF_FILE : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X$URWOTF_FILE |
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+           s//\1/
+           q
+         }
+         /^X\(\/\/\)[^/].*/{
+           s//\1/
+           q
+         }
+         /^X\(\/\/\)$/{
+           s//\1/
+           q
+         }
+         /^X\(\/\).*/{
+           s//\1/
+           q
+         }
+         s/.*/./; q'`
+    fi
+  fi
+fi
+if test "$URWOTF_DIR" != "" ;  then
+  for f in C059-BdIta.otf C059-Bold.otf \
+           C059-Italic.otf C059-Roman.otf \
+           NimbusMonoPS-Bold.otf NimbusMonoPS-BoldItalic.otf \
+           NimbusMonoPS-Italic.otf NimbusMonoPS-Regular.otf \
+           NimbusSans-Bold.otf NimbusSans-BoldOblique.otf \
+           NimbusSans-Oblique.otf NimbusSans-Regular.otf; do
+    if test ! -f "$URWOTF_DIR/$f"; then
+      MISSING_URWOTF_FILES="$MISSING_URWOTF_FILES $f"
+    else
+      URWOTF_FILES="$URWOTF_FILES $f"
+    fi
+  done
+fi
+if test "$URWOTF_DIR" = "" -o "$MISSING_URWOTF_FILES" != ""; then
+  { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+
+    eval "OPTIONAL"=\"`eval echo \"'$'OPTIONAL\" \"URW++ OTF fonts\"`\"
+
+  if test "$URWOTF_DIR" = ""; then
+    if test "$FCLIST" = ""; then
+
+    eval "OPTIONAL"=\"`eval echo \"'$'OPTIONAL\" \"'(install the fc-list utility from FontConfig, or use --with-urwotf-dir)'\"`\"
+
+    else
+
+    eval "OPTIONAL"=\"`eval echo \"'$'OPTIONAL\" \""(download OTF files from 'http://git.ghostscript.com/?p=urw-core35-fonts.git;a=commit;h=79bcdfb34fbce12b592cce389fa7a19da6b5b018' and put them under '~/.local/share/fonts' etc., or use --with-urwotf-dir)"\"`\"
+
+    fi
+  else
+
+    eval "OPTIONAL"=\"`eval echo \"'$'OPTIONAL\" \"'(these files are missing: $MISSING_URWOTF_FILES)'\"`\"
+
+  fi
+else
+  { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+fi
 
 ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'