From 12b1ec62645e772174cd710a208f59ab823eafe0 Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Fri, 20 Jul 2012 07:38:12 -0700 Subject: refactor to build llphysicsextensions_tpv package for sublicensees --- autobuild.xml | 12 +- build.sh | 55 +++++-- indra/cmake/LLPhysicsExtensions.cmake | 18 ++- package_physicsextensions.sh | 52 ------ package_physicsextensions.xml | 292 ---------------------------------- 5 files changed, 58 insertions(+), 371 deletions(-) delete mode 100755 package_physicsextensions.sh delete mode 100644 package_physicsextensions.xml diff --git a/autobuild.xml b/autobuild.xml index 7f06291caf..a25056ac87 100644 --- a/autobuild.xml +++ b/autobuild.xml @@ -1158,11 +1158,11 @@ archive hash - 9bba702fbbd41d3f6cd288ae1c763753 + 4a9a12f396c4486cf9a456b251397150 hash_algorithm md5 url - http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/llphysicsextensions-source/rev/261592/arch/Darwin/installer/llphysicsextensions_source-0.2-darwin-20120711.tar.bz2 + http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/oz_llphysicsextensions-source/rev/262209/arch/Darwin/installer/llphysicsextensions_source-0.3-darwin-20120720.tar.bz2 name darwin @@ -1172,9 +1172,9 @@ archive hash - 7989a1e993a5e08cd9832d9f68cd025f + 156abe6878ff3427c1c21d8cb6f9f3c5 url - http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/llphysicsextensions-source/rev/261592/arch/Linux/installer/llphysicsextensions_source-0.2-linux-20120711.tar.bz2 + http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/oz_llphysicsextensions-source/rev/262209/arch/Linux/installer/llphysicsextensions_source-0.3-linux-20120720.tar.bz2 name linux @@ -1184,9 +1184,9 @@ archive hash - 846b4efadf740b2fe6ea800d4f8608c1 + d123648105c8c363ef4b445bef983fd5 url - http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/llphysicsextensions-source/rev/261592/arch/CYGWIN/installer/llphysicsextensions_source-0.2-windows-20120711.tar.bz2 + http://s3-proxy.lindenlab.com/private-builds-secondlife-com/hg/repo/oz_llphysicsextensions-source/rev/262209/arch/CYGWIN/installer/llphysicsextensions_source-0.3-windows-20120720.tar.bz2 name windows diff --git a/build.sh b/build.sh index d19d8a5d6b..bd71de762c 100755 --- a/build.sh +++ b/build.sh @@ -70,19 +70,46 @@ pre_build() end_section "Pre$variant" } +package_llphysicsextensions_tpv() +{ + begin_section "PhysicsExtensions_TPV" + tpv_status=0 + if [ "$variant" = "Release" ] + then + llpetpvcfg=$build_dir/packages/llphysicsextensions/autobuild-tpv.xml + "$AUTOBUILD" build --verbose --config-file $llpetpvcfg -c Tpv + + # capture the package file name for use in upload later... + PKGTMP=`mktemp -t pgktpv.XXXXXX` + trap "rm $PKGTMP* 2>/dev/null" 0 + "$AUTOBUILD" package --verbose --config-file $llpetpvcfg > $PKGTMP + tpv_status=$? + sed -n -e 's/^wrote *//p' $PKGTMP > $build_dir/llphysicsextensions_package + else + echo "Do not provide llphysicsextensions_tpv for $variant" + llphysicsextensions_package="" + fi + end_section "PhysicsExtensions_TPV" + return $tpv_status +} + build() { local variant="$1" if $build_viewer then begin_section "Viewer$variant" - if "$AUTOBUILD" build --no-configure -c $variant + "$AUTOBUILD" build --no-configure -c $variant + viewer_build_ok=$? + end_section "Viewer$variant" + package_llphysicsextensions_tpv + tpvlib_build_ok=$? + if [ $viewer_build_ok -eq 0 -a $tpvlib_build_ok -eq 0 ] then echo true >"$build_dir"/build_ok else echo false >"$build_dir"/build_ok fi - end_section "Viewer$variant" fi } @@ -196,11 +223,6 @@ do mkdir -p "$build_dir" mkdir -p "$build_dir/tmp" - # Install packages. - begin_section "AutobuildInstall" - "$AUTOBUILD" install --verbose --skip-license-check - end_section "AutobuildInstall" - if pre_build "$variant" "$build_dir" >> "$build_log" 2>&1 then if $build_link_parallel @@ -270,21 +292,22 @@ then upload_item quicklink "$package" binary/octet-stream [ -f summary.json ] && upload_item installer summary.json text/plain - # Upload crash reporter files and symbolfile for public llphysicsextensions build. case "$last_built_variant" in Release) + # Upload crash reporter files for symbolfile in $symbolfiles do upload_item symbolfile "$build_dir/$symbolfile" binary/octet-stream done - - mapfilepath=$build_dir/newview - gzip $mapfilepath/secondlife-bin.MAP - mapfile=secondlife-bin-$arch.MAP.gz - mv $mapfilepath/secondlife-bin.MAP.gz $mapfilepath/$mapfile - upload_item mapfile "$mapfilepath/$mapfile" binary/octet-stream - echo "Uploaded mapfile for $last_built_variant" - + + # Upload the llphysicsextensions_tpv package, if one was produced + if [ -r "$build_dir/llphysicsextensions_package" ] + then + llphysicsextensions_package=$(cat $build_dir/llphysicsextensions_package) + upload_item private_artifact "$llphysicsextensions_package" binary/octet-stream + else + echo "No llphysicsextensions_package" + fi ;; *) echo "Skipping mapfile for $last_built_variant" diff --git a/indra/cmake/LLPhysicsExtensions.cmake b/indra/cmake/LLPhysicsExtensions.cmake index 72ac35e02b..e6afee762e 100644 --- a/indra/cmake/LLPhysicsExtensions.cmake +++ b/indra/cmake/LLPhysicsExtensions.cmake @@ -1,22 +1,30 @@ # -*- cmake -*- include(Prebuilt) -# Note that the use_prebuilt_binary macros below do not in fact include binaries; -# the llphysicsextensions_* packages are source only and are built here. -# The source package and the stub package both build libraries of the same name. +# There are three possible solutions to provide the llphysicsextensions: +# - The full source package, selected by -DHAVOK:BOOL=ON +# - The stub source package, selected by -DHAVOK:BOOL=OFF +# - The prebuilt package available to those with sublicenses, selected by -DHAVOK_TPV:BOOL=ON -# Using the real wrapper or the stub can be controlled with -DHAVOK:BOOL={ON,OFF} -# the default if (INSTALL_PROPRIETARY) set(HAVOK ON CACHE BOOL "Use Havok physics library") endif (INSTALL_PROPRIETARY) + +# Note that the use_prebuilt_binary macros below do not in fact include binaries; +# the llphysicsextensions_* packages are source only and are built here. +# The source package and the stub package both build libraries of the same name. + if (HAVOK) include(Havok) use_prebuilt_binary(llphysicsextensions_source) set(LLPHYSICSEXTENSIONS_SRC_DIR ${LIBS_PREBUILT_DIR}/llphysicsextensions/src) set(LLPHYSICSEXTENSIONS_LIBRARIES llphysicsextensions) +elseif (HAVOK_TPV) + use_prebuilt_binary(llphysicsextensions_tpv) + set(LLPHYSICSEXTENSIONS_LIBRARIES llphysicsextensions_tpv) + else (HAVOK) use_prebuilt_binary(llphysicsextensions_stub) set(LLPHYSICSEXTENSIONS_SRC_DIR ${LIBS_PREBUILT_DIR}/llphysicsextensions/stub) diff --git a/package_physicsextensions.sh b/package_physicsextensions.sh deleted file mode 100755 index 5b4c23ecc9..0000000000 --- a/package_physicsextensions.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/bash - -cd "$(dirname "$0")" - -# turn on verbose debugging output for parabuild logs. -set -x -# make errors fatal -set -e - -if [ -z "$AUTOBUILD" ] ; then - fail -fi - -if [ "$OSTYPE" = "cygwin" ] ; then - export AUTOBUILD="$(cygpath -u $AUTOBUILD)" -fi - -# load autbuild provided shell functions and variables -eval "$("$AUTOBUILD" source_environment)" - -projectDir="$(pwd)" - -#directories we need the headers from -projects="llcommon llimage llmath llrender" - -source="$projectDir/indra" - -stage="$projectDir/stage/include" -mkdir -p $stage - -for project in $projects -do - dstIncludeDir="$stage/$project" - mkdir -p $dstIncludeDir - headers="$source/$project/*.h" - cp $headers "$dstIncludeDir" - headers="$source/$project/*.inl" - # not all projects have .inl files - files=$(ls $headers 2> /dev/null | wc -l) - if [ "$files" != "0" ] ; then - cp $headers "$dstIncludeDir" - fi -done - -# Copy the license files into place for packaging -srcLicenseDir="$projectDir/doc" -dstLicenseDir="$projectDir/stage/LICENSES" - -mkdir -p "$dstLicenseDir" -cp "$srcLicenseDir/LGPL-licence.txt" "$dstLicenseDir/LGPL-licence.txt" - -pass diff --git a/package_physicsextensions.xml b/package_physicsextensions.xml deleted file mode 100644 index 0bde6ad770..0000000000 --- a/package_physicsextensions.xml +++ /dev/null @@ -1,292 +0,0 @@ - - - - package_description - - description - include files referenced in the llphysicsextensions - license - LGPL - license_file - LICENSES/LGPL-licence.txt - name - pathfinding_includes - platforms - - common - - build_directory - stage - configurations - - Debug - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - True - name - Debug - - Release - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - True - name - Release - - RelWithDebInfo - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - True - name - RelWithDebInfo - - - name - common - - darwin - - build_directory - stage - configurations - - Debug - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - Debug - - Release - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - Release - - RelWithDebInfo - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - RelWithDebInfo - - - name - darwin - - linux - - build_directory - stage - configurations - - Debug - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - name - Debug - - Release - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - name - Release - - RelWithDebInfo - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - name - RelWithDebInfo - - - manifest - - include - LICENSES - - name - linux - - windows - - build_directory - stage - configurations - - Debug - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - Debug - - Release - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - Release - - RelWithDebInfo - - build - - command - bash - options - - -c ../package_physicsextensions.sh - - - default - true - manifest - - include/ - LICENSES - - name - RelWithDebInfo - - - name - windows - - - version - 1.0 - - type - autobuild - version - 1.2 - - -- cgit v1.2.3