diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2015-10-03 17:20:03 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2015-10-03 17:28:09 +0300 |
commit | 5443d418821a5f87f3f7bff2c04d2918d6c94374 (patch) | |
tree | 2663fcec1167306c908debb67c868c4d5399013e /build_files/build_environment/install_deps.sh | |
parent | d9d3a2a5009c76f68fd2e6456db7dac61c4d2e49 (diff) |
InstallDeps: Fix broken OSL (would not generate valid default names for its .oso pre-compiled files).
Also, externalize temp/hacky patches in own dir, much much cleaner than integrating them in bash script!
Diffstat (limited to 'build_files/build_environment/install_deps.sh')
-rwxr-xr-x | build_files/build_environment/install_deps.sh | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/build_files/build_environment/install_deps.sh b/build_files/build_environment/install_deps.sh index 2d839858b80..d4728014db5 100755 --- a/build_files/build_environment/install_deps.sh +++ b/build_files/build_environment/install_deps.sh @@ -44,6 +44,7 @@ INST="/opt/lib" TMP="/tmp" CWD=$PWD INFO_PATH=$CWD +SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) # Do not install some optional, potentially conflicting libs by default... WITH_ALL=false @@ -1378,19 +1379,7 @@ compile_LLVM() { cd $_src # XXX Ugly patching hack! - cat << EOF | patch -p1 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -13,7 +13,7 @@ - set(LLVM_VERSION_MAJOR 3) - set(LLVM_VERSION_MINOR 1) - --set(PACKAGE_VERSION "\${LLVM_VERSION_MAJOR}.\${LLVM_VERSION_MINOR}svn") -+set(PACKAGE_VERSION "\${LLVM_VERSION_MAJOR}.\${LLVM_VERSION_MINOR}") - - set_property(GLOBAL PROPERTY USE_FOLDERS ON) - -EOF + patch -p1 -i "$SCRIPT_DIR/install_deps_patches/llvm.patch" cd $CWD @@ -1460,10 +1449,10 @@ compile_OSL() { # Clean install if needed! magic_compile_check osl-$OSL_VERSION $osl_magic - #~ if [ $? -eq 1 -o $OSL_FORCE_REBUILD == true ]; then + if [ $? -eq 1 -o $OSL_FORCE_REBUILD == true ]; then #~ rm -Rf $_src # XXX Radical, but not easy to change remote repo fully automatically - #~ clean_OSL - #~ fi + clean_OSL + fi if [ ! -d $_inst ]; then INFO "Building OpenShadingLanguage-$OSL_VERSION" @@ -1492,6 +1481,9 @@ compile_OSL() { # Stick to same rev as windows' libs... git checkout $OSL_SOURCE_REPO_UID git reset --hard + + # XXX Ugly patching hack! + patch -p1 -i "$SCRIPT_DIR/install_deps_patches/osl.patch" fi # Always refresh the whole build! @@ -1533,6 +1525,9 @@ compile_OSL() { fi fi + #~ cmake_d="$cmake_d -D CMAKE_EXPORT_COMPILE_COMMANDS=ON" + #~ cmake_d="$cmake_d -D CMAKE_VERBOSE_MAKEFILE=ON" + cmake $cmake_d .. make -j$THREADS && make install |