setsdkenv_unix.sh.in (599cc5b4) | setsdkenv_unix.sh.in (b3ba5bc7) |
---|---|
1#! /bin/sh 2############################################################### 3# 4# Licensed to the Apache Software Foundation (ASF) under one 5# or more contributor license agreements. See the NOTICE file 6# distributed with this work for additional information 7# regarding copyright ownership. The ASF licenses this file 8# to you under the Apache License, Version 2.0 (the --- 21 unchanged lines hidden (view full) --- 30 31# Installation directory of the Software Development Kit. 32# Example: OO_SDK_HOME=/opt/openoffice/basis4.0/sdk 33OO_SDK_HOME='@OO_SDK_HOME@' 34 35# Office installation directory. 36# Example: OFFICE_HOME=/opt/openoffice4 37OFFICE_HOME='@OFFICE_HOME@' | 1#! /bin/sh 2############################################################### 3# 4# Licensed to the Apache Software Foundation (ASF) under one 5# or more contributor license agreements. See the NOTICE file 6# distributed with this work for additional information 7# regarding copyright ownership. The ASF licenses this file 8# to you under the Apache License, Version 2.0 (the --- 21 unchanged lines hidden (view full) --- 30 31# Installation directory of the Software Development Kit. 32# Example: OO_SDK_HOME=/opt/openoffice/basis4.0/sdk 33OO_SDK_HOME='@OO_SDK_HOME@' 34 35# Office installation directory. 36# Example: OFFICE_HOME=/opt/openoffice4 37OFFICE_HOME='@OFFICE_HOME@' |
38OFFICE_BASE_HOME='@OFFICE_BASE_HOME@' | |
39 | 38 |
40# URE installation directory. 41# Example: OO_SDK_URE_HOME=/opt/openoffice/ure 42OO_SDK_URE_HOME='@OO_SDK_URE_HOME@' 43export OO_SDK_URE_HOME 44 | |
45# Directory of the make command. 46# Example: OO_SDK_MAKE_HOME=/usr/bin 47OO_SDK_MAKE_HOME=@OO_SDK_MAKE_HOME@ 48 49# Directory of the zip command. 50# Example: OO_SDK_ZIP_HOME=/usr/bin 51OO_SDK_ZIP_HOME=@OO_SDK_ZIP_HOME@ 52 --- 57 unchanged lines hidden (view full) --- 110 111# Set office program path (only set when using an Office). 112if [ "${OFFICE_HOME}" ] 113then 114 OFFICE_PROGRAM_PATH=${OFFICE_HOME}/${programdir} 115 export OFFICE_PROGRAM_PATH 116fi 117 | 39# Directory of the make command. 40# Example: OO_SDK_MAKE_HOME=/usr/bin 41OO_SDK_MAKE_HOME=@OO_SDK_MAKE_HOME@ 42 43# Directory of the zip command. 44# Example: OO_SDK_ZIP_HOME=/usr/bin 45OO_SDK_ZIP_HOME=@OO_SDK_ZIP_HOME@ 46 --- 57 unchanged lines hidden (view full) --- 104 105# Set office program path (only set when using an Office). 106if [ "${OFFICE_HOME}" ] 107then 108 OFFICE_PROGRAM_PATH=${OFFICE_HOME}/${programdir} 109 export OFFICE_PROGRAM_PATH 110fi 111 |
118# Set office program path (only set when using an Office). 119if [ "${OFFICE_BASE_HOME}" ] 120then 121 OFFICE_BASE_PROGRAM_PATH=${OFFICE_BASE_HOME}/program 122 export OFFICE_BASE_PROGRAM_PATH 123fi 124 125 | |
126# Set UNO path, necessary to ensure that the cpp examples using the 127# new UNO bootstrap mechanism use the configured office installation (only set 128# when using an Office). 129if [ "${OFFICE_HOME}" ] 130then 131 UNO_PATH=${OFFICE_PROGRAM_PATH} 132 export UNO_PATH 133fi 134 | 112# Set UNO path, necessary to ensure that the cpp examples using the 113# new UNO bootstrap mechanism use the configured office installation (only set 114# when using an Office). 115if [ "${OFFICE_HOME}" ] 116then 117 UNO_PATH=${OFFICE_PROGRAM_PATH} 118 export UNO_PATH 119fi 120 |
135if [ "${OO_SDK_URE_HOME}" ] 136then 137 OO_SDK_URE_BIN_DIR=${OO_SDK_URE_HOME}/bin 138 OO_SDK_URE_LIB_DIR=${OO_SDK_URE_HOME}/lib 139 OO_SDK_URE_JAVA_DIR=${OO_SDK_URE_HOME}/share/java 140else 141 OO_SDK_URE_BIN_DIR=${OFFICE_PROGRAM_PATH} 142 OO_SDK_URE_LIB_DIR=${OFFICE_BASE_PROGRAM_PATH} 143 OO_SDK_URE_JAVA_DIR=${OFFICE_BASE_PROGRAM_PATH}/classes 144fi | 121OO_SDK_URE_BIN_DIR=${OFFICE_PROGRAM_PATH} 122OO_SDK_URE_LIB_DIR=${OFFICE_PROGRAM_PATH} 123OO_SDK_URE_JAVA_DIR=${OFFICE_PROGRAM_PATH}/classes 124 |
145export OO_SDK_URE_BIN_DIR 146export OO_SDK_URE_LIB_DIR 147export OO_SDK_URE_JAVA_DIR 148 149OO_SDK_OUT=$OO_SDK_HOME 150# Prepare appropriate output directory. 151if [ -n "${OO_SDK_OUTPUT_DIR}" ] 152then --- 31 unchanged lines hidden (view full) --- 184 185 directoryname=macosx 186 comid=gcc3 187 pltfrm=gcc 188 soext=dylib 189 exampleout=MACOSXexample.out 190 platform=MacOSX 191 stldebug=_stldebug | 125export OO_SDK_URE_BIN_DIR 126export OO_SDK_URE_LIB_DIR 127export OO_SDK_URE_JAVA_DIR 128 129OO_SDK_OUT=$OO_SDK_HOME 130# Prepare appropriate output directory. 131if [ -n "${OO_SDK_OUTPUT_DIR}" ] 132then --- 31 unchanged lines hidden (view full) --- 164 165 directoryname=macosx 166 comid=gcc3 167 pltfrm=gcc 168 soext=dylib 169 exampleout=MACOSXexample.out 170 platform=MacOSX 171 stldebug=_stldebug |
192 DYLD_LIBRARY_PATH=${OO_SDK_OUT}/${directoryname}/lib:${OO_SDK_OUT}/${exampleout}/lib:${OO_SDK_URE_LIB_DIR}:.:${DYLD_LIBRARY_PATH} | 172 DYLD_LIBRARY_PATH=/usr/lib:${OO_SDK_OUT}/${directoryname}/lib:${OO_SDK_OUT}/${exampleout}/lib:${OO_SDK_URE_LIB_DIR}:.:${DYLD_LIBRARY_PATH} |
193 export DYLD_LIBRARY_PATH 194 ;; 195 196 linux-gnu) 197 if [ -n "$OO_SDK_CPP_HOME" ] 198 then 199 SDK_GXX_INCLUDE_PATH=`echo "#include <cstring>" | ${OO_SDK_CPP_HOME}/g++ -E -xc++ - | sed -n '/.*1*"\(.*\)\/cstring".*/s//\1/p' | head -n 1` 200 export SDK_GXX_INCLUDE_PATH --- 51 unchanged lines hidden (view full) --- 252 fi 253 ;; 254esac 255 256# Add directory of the SDK tools to the path. 257PATH=${OO_SDK_HOME}/bin:${OO_SDK_OUT}/${exampleout}/bin:${OO_SDK_URE_BIN_DIR}:${OFFICE_PROGRAM_PATH}:.:${PATH} 258 259# Set the classpath | 173 export DYLD_LIBRARY_PATH 174 ;; 175 176 linux-gnu) 177 if [ -n "$OO_SDK_CPP_HOME" ] 178 then 179 SDK_GXX_INCLUDE_PATH=`echo "#include <cstring>" | ${OO_SDK_CPP_HOME}/g++ -E -xc++ - | sed -n '/.*1*"\(.*\)\/cstring".*/s//\1/p' | head -n 1` 180 export SDK_GXX_INCLUDE_PATH --- 51 unchanged lines hidden (view full) --- 232 fi 233 ;; 234esac 235 236# Add directory of the SDK tools to the path. 237PATH=${OO_SDK_HOME}/bin:${OO_SDK_OUT}/${exampleout}/bin:${OO_SDK_URE_BIN_DIR}:${OFFICE_PROGRAM_PATH}:.:${PATH} 238 239# Set the classpath |
260CLASSPATH=${OO_SDK_URE_JAVA_DIR}/juh.jar:${OO_SDK_URE_JAVA_DIR}/jurt.jar:${OO_SDK_URE_JAVA_DIR}/ridl.jar:${OO_SDK_URE_JAVA_DIR}/unoloader.jar:${OFFICE_BASE_PROGRAM_PATH}/classes/unoil.jar:${CLASSPATH} | 240CLASSPATH=${OO_SDK_URE_JAVA_DIR}/juh.jar:${OO_SDK_URE_JAVA_DIR}/jurt.jar:${OO_SDK_URE_JAVA_DIR}/ridl.jar:${OO_SDK_URE_JAVA_DIR}/unoloader.jar:${OO_SDK_URE_JAVA_DIR}/unoil.jar:${CLASSPATH} |
261export CLASSPATH 262 263 264# Add directory of the command make to the path, if necessary. 265if [ -n "${OO_SDK_MAKE_HOME}" ] 266then 267 PATH=${OO_SDK_MAKE_HOME}:${PATH} 268 export OO_SDK_MAKE_HOME --- 65 unchanged lines hidden (view full) --- 334 "${OO_SDK_OUT}/${directoryname}/lib/libuno_purpenvhelper${comid}.${soext}" 335 336 if [ -L "${OO_SDK_OUT}/${directoryname}/lib/libstlport_${pltfrm}${STLDEBUG}.${soext}" ] 337 then 338 rm -rf "${OO_SDK_OUT}/${directoryname}/lib/libstlport_${pltfrm}${STLDEBUG}.${soext}" 339 fi 340 341# prepare links | 241export CLASSPATH 242 243 244# Add directory of the command make to the path, if necessary. 245if [ -n "${OO_SDK_MAKE_HOME}" ] 246then 247 PATH=${OO_SDK_MAKE_HOME}:${PATH} 248 export OO_SDK_MAKE_HOME --- 65 unchanged lines hidden (view full) --- 314 "${OO_SDK_OUT}/${directoryname}/lib/libuno_purpenvhelper${comid}.${soext}" 315 316 if [ -L "${OO_SDK_OUT}/${directoryname}/lib/libstlport_${pltfrm}${STLDEBUG}.${soext}" ] 317 then 318 rm -rf "${OO_SDK_OUT}/${directoryname}/lib/libstlport_${pltfrm}${STLDEBUG}.${soext}" 319 fi 320 321# prepare links |
342 if [ "${OO_SDK_URE_HOME}" ] | 322 if [ "${OFFICE_HOME}" ] |
343 then 344 mkdir -p "${OO_SDK_OUT}/${directoryname}/lib" 345 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_cppu.${soext}.3" \ 346 "${OO_SDK_OUT}/${directoryname}/lib/libuno_cppu.${soext}" 347 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_cppuhelper${comid}.${soext}.3" \ 348 "${OO_SDK_OUT}/${directoryname}/lib/libuno_cppuhelper${comid}.${soext}" 349 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_sal.${soext}.3" \ 350 "${OO_SDK_OUT}/${directoryname}/lib/libuno_sal.${soext}" --- 14 unchanged lines hidden (view full) --- 365# Prepare shell with all necessary environment variables. 366echo 367echo " ************************************************************************" 368echo " *" 369echo " * SDK environment is prepared for ${platform}" 370echo " *" 371echo " * SDK = $OO_SDK_HOME" 372echo " * Office = $OFFICE_HOME" | 323 then 324 mkdir -p "${OO_SDK_OUT}/${directoryname}/lib" 325 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_cppu.${soext}.3" \ 326 "${OO_SDK_OUT}/${directoryname}/lib/libuno_cppu.${soext}" 327 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_cppuhelper${comid}.${soext}.3" \ 328 "${OO_SDK_OUT}/${directoryname}/lib/libuno_cppuhelper${comid}.${soext}" 329 ln -s "${OO_SDK_URE_LIB_DIR}/libuno_sal.${soext}.3" \ 330 "${OO_SDK_OUT}/${directoryname}/lib/libuno_sal.${soext}" --- 14 unchanged lines hidden (view full) --- 345# Prepare shell with all necessary environment variables. 346echo 347echo " ************************************************************************" 348echo " *" 349echo " * SDK environment is prepared for ${platform}" 350echo " *" 351echo " * SDK = $OO_SDK_HOME" 352echo " * Office = $OFFICE_HOME" |
373echo " * Office Base = $OFFICE_BASE_HOME" 374echo " * URE = $OO_SDK_URE_HOME" | |
375echo " * Make = $OO_SDK_MAKE_HOME" 376echo " * Zip = $OO_SDK_ZIP_HOME" 377echo " * cat = $OO_SDK_CAT_HOME" 378echo " * sed = $OO_SDK_SED_HOME" 379echo " * C++ Compiler = $OO_SDK_CPP_HOME" 380echo " * Java = $OO_SDK_JAVA_HOME" 381echo " * SDK Output directory = $OO_SDK_OUT" 382echo " * Auto deployment = $SDK_AUTO_DEPLOYMENT" 383echo " *" 384echo " ************************************************************************" 385 386echo "]2;Shell prepared with the SDK environment" 387 | 353echo " * Make = $OO_SDK_MAKE_HOME" 354echo " * Zip = $OO_SDK_ZIP_HOME" 355echo " * cat = $OO_SDK_CAT_HOME" 356echo " * sed = $OO_SDK_SED_HOME" 357echo " * C++ Compiler = $OO_SDK_CPP_HOME" 358echo " * Java = $OO_SDK_JAVA_HOME" 359echo " * SDK Output directory = $OO_SDK_OUT" 360echo " * Auto deployment = $SDK_AUTO_DEPLOYMENT" 361echo " *" 362echo " ************************************************************************" 363 364echo "]2;Shell prepared with the SDK environment" 365 |