Changeset 733 for trunk/technical
- Timestamp:
- Jan 26, 2009, 4:33:42 PM (16 years ago)
- Location:
- trunk/technical/common/build
- Files:
-
- 1 deleted
- 1 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/technical/common/build/build.sh
r719 r733 21 21 # the rest is controlled by environment variables 22 22 # 23 # build.sh uses sudo su. /etc/sudoers needs a line like: 24 # %users ALL=(ALL) NOPASSWD: /bin/su 25 # for automatic building 23 # build.sh uses sudo. /etc/sudoers needs a line like: 24 # %users ALL=(ALL) NOPASSWD: /usr/local/bin/buildscript 25 # for automatic building (create a symlink or copy the file, 26 # see also the Variable BUILDSCRIPT and content of this script) 26 27 # 27 28 # return codes: … … 37 38 38 39 39 40 # set LANG to default (english) 41 # required for SVN 42 export LC_ALL=C 40 43 41 44 CONFIG_FILE=/usr/local/etc/build 45 BUILDSCRIPT=buildscript 42 46 BUILD_CMD=build 43 47 BUILDUSER=$USER … … 50 54 [ -z $DEST_DIR ] && DEST_DIR="/tmp/build.$BUILDUSER" 51 55 BUILDTEMP=$DEST_DIR/buildsrc/ 52 BUILDSCRIPT=$BUILDTEMP/buildscript.$$ 56 #BUILDSCRIPT=$BUILDTEMP/buildscript.$$ 57 BUILDVARS=$BUILDTEMP/build.vars 53 58 54 59 [ -z "$BUILD_USES_SVN" ] && BUILD_USES_SVN="yes" … … 216 221 fi 217 222 218 # create buildscript 219 cat > $BUILDSCRIPT <<EOF 220 #!/bin/bash 221 # local buildscript 222 export BUILD_ROOT=$BUILD_ROOT 223 export BUILD_DIST=$BUILD_DIST 224 export BUILD_RPMS=${DEST_DIR}/${BUILD_DIST}:$BUILD_RPMS 225 export BUILD_PREPARE_SPEC=$BUILD_PREPARE_SPEC 226 227 cd ${BUILDTEMP}/src/${PACKAGE} 228 $BUILD_CMD $BUILD_MODE 223 # # create buildscript 224 # cat > $BUILDSCRIPT <<EOF 225 # #!/bin/bash 226 # # local buildscript 227 # export BUILD_ROOT=$BUILD_ROOT 228 # export BUILD_DIST=$BUILD_DIST 229 # export BUILD_RPMS=${DEST_DIR}/${BUILD_DIST}:$BUILD_RPMS 230 # export BUILD_PREPARE_SPEC=$BUILD_PREPARE_SPEC 231 # 232 # cd ${BUILDTEMP}/src/${PACKAGE} 233 # $BUILD_CMD $BUILD_MODE 234 # EOF 235 # 236 # chmod a+x $BUILDSCRIPT 237 # sudo /bin/su -c $BUILDSCRIPT 238 # rm -f $BUILDSCRIPT 239 240 # create file for buildvars (see $BUILDSCRIPT) 241 cat > $BUILDVARS <<EOF 242 # Variables for build-Prozess (export is needed in buildscript) 243 BUILD_ROOT=$BUILD_ROOT 244 BUILD_DIST=$BUILD_DIST 245 BUILD_RPMS=${DEST_DIR}/${BUILD_DIST}:$BUILD_RPMS 246 247 # Variables for execute the build-proggy 248 BUILD_MODE="$BUILD_MODE" 249 BUILD_PLACE=${BUILDTEMP}/src/${PACKAGE} 250 EXTRA_RPMS="$EXTRA_RPMS" 229 251 EOF 230 252 231 chmod a+x $BUILDSCRIPT 232 sudo su -c $BUILDSCRIPT 233 rm -f $BUILDSCRIPT 253 sudo $BUILDSCRIPT $BUILDVARS 254 #rm -f $BUILDVARS 255 256 234 257 235 258 mkdir -p ${DEST_DIR}/src
Note:
See TracChangeset
for help on using the changeset viewer.