Repository: lucy Updated Branches: refs/heads/master 672ede982 -> 12d87a852
Switch to Clownfish's setup_env.sh Project: http://git-wip-us.apache.org/repos/asf/lucy/repo Commit: http://git-wip-us.apache.org/repos/asf/lucy/commit/12d87a85 Tree: http://git-wip-us.apache.org/repos/asf/lucy/tree/12d87a85 Diff: http://git-wip-us.apache.org/repos/asf/lucy/diff/12d87a85 Branch: refs/heads/master Commit: 12d87a852896b8f68f14f33ebd047da36b55a9b8 Parents: 672ede9 Author: Nick Wellnhofer <[email protected]> Authored: Mon Jul 21 19:06:02 2014 +0200 Committer: Nick Wellnhofer <[email protected]> Committed: Mon Jul 21 19:08:57 2014 +0200 ---------------------------------------------------------------------- c/INSTALL | 8 +++- devel/bin/setup_clownfish_env.sh | 74 ----------------------------------- perl/INSTALL | 27 +++++++++++-- 3 files changed, 29 insertions(+), 80 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/lucy/blob/12d87a85/c/INSTALL ---------------------------------------------------------------------- diff --git a/c/INSTALL b/c/INSTALL index a92a74c..0134d1f 100644 --- a/c/INSTALL +++ b/c/INSTALL @@ -22,9 +22,13 @@ make sure to use the --clownfish-prefix configure option: It's also possible to build Lucy with an uninstalled Clownfish build from the Clownfish source directory. To setup the required environment variables, -run the following from the lucy/c directory before configuration: +source the file devel/bin/setup_env.sh from the Clownfish source tree: - $ source ../devel/bin/setup_clownfish_env.sh clownfish-source-dir + $ source path_to_clownfish/devel/bin/setup_env.sh + +Or, if you're on the Windows shell: + + $ path_to_clownfish/devel/bin/setup_env.bat Building under UNIX and derivatives or Cygwin --------------------------------------------- http://git-wip-us.apache.org/repos/asf/lucy/blob/12d87a85/devel/bin/setup_clownfish_env.sh ---------------------------------------------------------------------- diff --git a/devel/bin/setup_clownfish_env.sh b/devel/bin/setup_clownfish_env.sh deleted file mode 100644 index 2ec107d..0000000 --- a/devel/bin/setup_clownfish_env.sh +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/sh - -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Set up PATH, LIBRARY_PATH, LD_LIBRARY_PATH and CLOWNFISH_INCLUDE to build -# Lucy with an uninstalled Clownfish source tree. Useful for development. -# -# Usage: . setup_clownfish_env.sh path_to_clownfish_source - -contains() { - string="$1" - substring="$2" - test "${string#*$substring}" != "$string" -} - -add_to_path() { - path="$1" - dir="$2" - if [ -z "$path" ]; then - echo "$dir" - elif ! contains ":$path:" ":$dir:"; then - echo "$dir:$path" - else - echo "$path" - fi -} - -if [ -z "$1" ]; then - echo "Usage: . setup_clownfish_env.sh path_to_clownfish_source" - return 1 2>/dev/null || exit 1 -fi - -if [ ! -d "$1" ]; then - echo "Not a directory: $1" - return 1 2>/dev/null || exit 1 -fi - -src_dir=`cd "$1" && pwd` - -if [ ! -d "$src_dir/compiler" ] || [ ! -d "$src_dir/runtime" ] -then - echo "Doesn't look like a Clownfish source directory: $src_dir" - return 1 2>/dev/null || exit 1 -fi - -compiler_dir=$src_dir/compiler -runtime_dir=$src_dir/runtime - -export PATH=`add_to_path "$PATH" "$compiler_dir/c"` -export C_INCLUDE_PATH=`add_to_path "$C_INCLUDE_PATH" "$runtime_dir/perl/xs"` -export LIBRARY_PATH=`add_to_path "$LIBRARY_PATH" "$runtime_dir/c"` -export CLOWNFISH_INCLUDE=`add_to_path "$CLOWNFISH_INCLUDE" "$runtime_dir/core"` -export PERL5LIB=`add_to_path "$PERL5LIB" "$compiler_dir/perl/blib/arch"` -export PERL5LIB=`add_to_path "$PERL5LIB" "$compiler_dir/perl/blib/lib"` -export PERL5LIB=`add_to_path "$PERL5LIB" "$runtime_dir/perl/blib/arch"` -export PERL5LIB=`add_to_path "$PERL5LIB" "$runtime_dir/perl/blib/lib"` - -if [ `uname` != Darwin ]; then - export LD_LIBRARY_PATH=`add_to_path "$LD_LIBRARY_PATH" "$runtime_dir/c"` -fi - http://git-wip-us.apache.org/repos/asf/lucy/blob/12d87a85/perl/INSTALL ---------------------------------------------------------------------- diff --git a/perl/INSTALL b/perl/INSTALL index 8eb001e..1cbd356 100644 --- a/perl/INSTALL +++ b/perl/INSTALL @@ -1,6 +1,29 @@ Installing Apache Lucy with Perl bindings ========================================= +Requirements +------------ + +Module::Build is required. Since Perl 5.10.0, Module::Build has been bundled +with the Perl core, but on older systems it may be necessary to install it +from CPAN first. + +Lucy also depends on the Clownfish compiler and runtime which are available +as Perl distributions Clownfish and Clownfish::CFC. + +It's also possible to build Lucy with an uninstalled Clownfish build from +the Clownfish source directory. To setup the required environment variables, +source the file devel/bin/setup_env.sh from the Clownfish source tree: + + $ source path_to_clownfish/devel/bin/setup_env.sh + +Or, if you're on the Windows shell: + + $ path_to_clownfish/devel/bin/setup_env.bat + +Build and installation +---------------------- + To install Apache Lucy as a suite of Perl modules, run the following commands: perl Build.PL @@ -8,7 +31,3 @@ To install Apache Lucy as a suite of Perl modules, run the following commands: perl Build test perl Build install -Module::Build is required. Since Perl 5.10.0, Module::Build has been bundled -with the Perl core, but on older systems it may be necessary to install it -from CPAN first. -
