From d1fb5f16d591d8f32c151152b0b0d159a5cbc4c2 Mon Sep 17 00:00:00 2001 From: eban Date: Wed, 27 Sep 2000 06:48:23 +0000 Subject: [PATCH] eban git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@979 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- configure.in | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/configure.in b/configure.in index 023ede7080..0df95deaf3 100644 --- a/configure.in +++ b/configure.in @@ -902,20 +902,25 @@ RUBY_INSTALL_NAME="${ri_prefix}ruby${ri_suffix}" case "$target_os" in cygwin*|mingw*|*djgpp*) RUBY_LIB_PREFIX="/lib/ruby" - SITEDIR='/lib/ruby/site_ruby' ;; *) RUBY_LIB_PREFIX="${prefix}/lib/ruby" - SITEDIR='${prefix}/lib/ruby/site_ruby' ;; esac RUBY_LIB_PATH="${RUBY_LIB_PREFIX}/${MAJOR}.${MINOR}" -sitedir='${prefix}/lib/ruby/site_ruby' + AC_ARG_WITH(sitedir, [--with-sitedir=DIR site libraries in DIR [PREFIX/lib/ruby/site_ruby]], [sitedir=$withval], - [sitedir=`eval "echo ${SITEDIR}"`]) -RUBY_SITE_LIB_PATH="${sitedir}" + [sitedir='${prefix}/lib/ruby/site_ruby']) +SITE_DIR="`eval "echo ${sitedir}"`" +case "$target_os" in + cygwin*|mingw*|*djgpp*) + RUBY_SITE_LIB_PATH="`expr "$SITE_DIR" : "$prefix\(/.*\)"`" || + RUBY_SITE_LIB_PATH="$SITE_DIR";; + *) + RUBY_SITE_LIB_PATH="$SITE_DIR";; +esac RUBY_SITE_LIB_PATH2="${RUBY_SITE_LIB_PATH}/${MAJOR}.${MINOR}" AC_DEFINE_UNQUOTED(RUBY_LIB, "${RUBY_LIB_PATH}")