Changeset 8230977
- Timestamp:
- 05/18/2006 07:33:25 PM (18 years ago)
- Branches:
- 1.0, 2.3, 2.3.x, 2.4, ablfs, ablfs-more, legacy, new_features, trunk
- Children:
- ca4c634
- Parents:
- 4bc3c2b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
contrib/jhalfs-paco.patch
r4bc3c2b r8230977 1 1 Index: LFS/master.sh 2 2 =================================================================== 3 --- LFS/master.sh (revision 2 695)3 --- LFS/master.sh (revision 2702) 4 4 +++ LFS/master.sh (working copy) 5 @@ -180,6 +180,18 @@ 5 @@ -173,6 +173,11 @@ 6 # Keep the script file name 7 this_script=`basename $file` 8 9 + # If $this_script corresponds to a paco script, then skip it 10 + case "${this_script}" in 11 + *paco) continue ;; 12 + esac 13 + 14 # We'll run the chroot commands differently than the others, so skip them in the 15 # dependencies and target creation. 16 case "${this_script}" in 17 @@ -180,6 +185,18 @@ 6 18 *stripping*) [[ "${STRIP}" = "0" ]] && continue ;; 7 19 esac … … 22 34 name=`echo ${this_script} | sed -e 's@[0-9]\{3\}-@@'` 23 35 24 @@ -223,7 +2 35,9 @@36 @@ -223,7 +240,9 @@ 25 37 # and not to use chroot. 26 38 case "${this_script}" in … … 33 45 34 46 # Remove the build directory(ies) except if the package build fails. 35 @@ -243,6 +2 57,16 @@47 @@ -243,6 +262,16 @@ 36 48 PREV=${this_script}${N} 37 49 # Set system_build envar for iteration targets … … 50 62 } 51 63 52 @@ -304,6 +3 28,14 @@64 @@ -304,6 +333,14 @@ 53 65 wrt_run_as_chroot2 "$this_script" "$file" 54 66 fi … … 67 79 Index: LFS/lfs.xsl 68 80 =================================================================== 69 --- LFS/lfs.xsl (revision 2 695)81 --- LFS/lfs.xsl (revision 2702) 70 82 +++ LFS/lfs.xsl (working copy) 71 83 @@ -32,6 +32,9 @@ … … 113 125 <xsl:otherwise> 114 126 <xsl:apply-templates/> 115 Index: BLFS/master.sh116 ===================================================================117 --- BLFS/master.sh (revision 2695)118 +++ BLFS/master.sh (working copy)119 @@ -79,6 +79,19 @@120 EOF121 ) >> $MKFILE122 123 + if [[ $USE_PACO != 0 ]]; then124 +(125 + cat << EOF126 + @echo -e "\n\`date\`\n\nKB: \`du -sk --exclude=logs/* /\`\n" >logs/$this_script && \\127 + source $JHALFSDIR/pacovars && \\128 + rm -f $PACO_TMPFILE && \\129 + $JHALFSDIR/${PROGNAME}-commands/$file >>logs/$this_script 2>&1 && \\130 + echo -e "\n\`date\`\n\nKB: \`du -sk --exclude=logs/* /\`\n" >>logs/$this_script131 +EOF132 +) >> $MKFILE133 + wrt_paco_log_blfs134 +135 + else136 # Insert date and disk usage at the top of the log file, the script run137 # and date and disk usage again at the bottom of the log file.138 (139 @@ -88,6 +101,7 @@140 echo -e "\n\`date\`\n\nKB: \`du -sk --exclude=logs/* /\`\n" >>logs/$this_script141 EOF142 ) >> $MKFILE143 + fi144 145 # Include a touch of the target name so make can check146 # if it's already been made.147 Index: BLFS/blfs.xsl148 ===================================================================149 --- BLFS/blfs.xsl (revision 2695)150 +++ BLFS/blfs.xsl (working copy)151 @@ -159,7 +159,7 @@152 <xsl:when test="@role = 'nodump'"/>153 <xsl:otherwise>154 <xsl:if test="@role = 'root'">155 - <xsl:text>sudo </xsl:text>156 + <xsl:text>export LD_PRELOAD=/usr/lib/libpaco-log.so
</xsl:text>157 </xsl:if>158 <xsl:apply-templates select="userinput" mode="screen"/>159 </xsl:otherwise>160 127 Index: common/paco-build-hlfs.sh 161 128 =================================================================== … … 176 143 Index: common/config 177 144 =================================================================== 178 --- common/config (revision 2 695)145 --- common/config (revision 2702) 179 146 +++ common/config (working copy) 180 @@ -8 8,6 +88,14 @@147 @@ -84,6 +84,14 @@ 181 148 #--- Run farce testing 0(no)/1(yes) 182 149 RUN_FARCE=0 … … 193 160 # Don't edit it unless you know what you are doing 194 161 195 @@ - 100,3 +108,9 @@162 @@ -96,3 +104,9 @@ 196 163 197 164 #--- farce report log directory … … 205 172 Index: common/func_validate_configs.sh 206 173 =================================================================== 207 --- common/func_validate_configs.sh (revision 2 695)174 --- common/func_validate_configs.sh (revision 2702) 208 175 +++ common/func_validate_configs.sh (working copy) 209 @@ -84, 10 +84,10@@176 @@ -84,9 +84,9 @@ 210 177 inline_doc 211 178 212 179 # First internal variables, then the ones that change the book's flavour, and lastly system configuration variables 213 - local -r blfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE GETPKG DEPEND TEST OPTIMIZE"214 180 - local -r hlfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE GETPKG RUNMAKE MODEL GRSECURITY_HOST TEST OPTIMIZE REPORT COMPARE RUN_ICA RUN_FARCE ITERATIONS STRIP FSTAB CONFIG KEYMAP PAGE TIMEZONE LANG LC_ALL" 215 181 - local -r clfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE GETPKG RUNMAKE METHOD ARCH TARGET TEST OPTIMIZE REPORT COMPARE RUN_ICA RUN_FARCE ITERATIONS STRIP FSTAB BOOT_CONFIG CONFIG KEYMAP VIMLANG PAGE TIMEZONE LANG" 216 182 - local -r lfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE GETPKG RUNMAKE TEST OPTIMIZE REPORT COMPARE RUN_ICA RUN_FARCE ITERATIONS STRIP FSTAB CONFIG VIMLANG PAGE TIMEZONE LANG" 217 + local -r blfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE USE_PACO GETPKG DEPEND TEST OPTIMIZE"218 183 + local -r hlfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE USE_PACO GETPKG RUNMAKE MODEL GRSECURITY_HOST TEST OPTIMIZE REPORT COMPARE RUN_ICA RUN_FARCE ITERATIONS STRIP FSTAB CONFIG KEYMAP PAGE TIMEZONE LANG LC_ALL" 219 184 + local -r clfs_PARAM_LIST="BOOK BUILDDIR SRC_ARCHIVE USE_PACO GETPKG RUNMAKE METHOD ARCH TARGET TEST OPTIMIZE REPORT COMPARE RUN_ICA RUN_FARCE ITERATIONS STRIP FSTAB BOOT_CONFIG CONFIG KEYMAP VIMLANG PAGE TIMEZONE LANG" … … 222 187 local -r ERROR_MSG_pt1='The variable \"${L_arrow}${config_param}${R_arrow}\" value ${L_arrow}${BOLD}${!config_param}${R_arrow} is invalid,' 223 188 local -r ERROR_MSG_pt2=' check the config file ${BOLD}${GREEN}\<$(echo $PROGNAME | tr [a-z] [A-Z])/config\> or \<common/config\>${OFF}' 224 @@ -17 4,6 +174,7 @@189 @@ -173,6 +173,7 @@ 225 190 # Validate general parameters.. 226 191 GETPKG) validate_against_str "x0x x1x" ;; … … 234 199 --- common/paco-functions (revision 0) 235 200 +++ common/paco-functions (revision 0) 236 @@ -0,0 +1,1 12@@201 @@ -0,0 +1,105 @@ 237 202 +#!/bin/bash 238 203 + … … 328 293 +) >> $MKFILE.tmp 329 294 +fi 330 +} 331 + 332 + 333 +#----------------------------------# 334 +wrt_paco_log_blfs() { # If the tmpfile exist, then log the current package 335 +#----------------------------------# and remove tempfile 336 +if [ $USE_PACO != 0 ] ; then 295 + 296 +# Glibc uses 'sln' to install symlinks in /lib 297 +# add these to the log since paco can't track statically linked executables 298 +# Glibc is the first package to install into /lib, so a simple 'find' will suffice 299 +if [ $USE_PACO != 0 ] && [ "$name" = "glibc" ]; then 337 300 +( 338 301 +cat << EOF 339 + @PACKAGE=\`head -n1 /tmp/unpacked | sed 's@^./@@;s@/.*@@'\` && \\ 340 + if [ -e $PACO_TMPFILE ]; then \\ 341 + paco -lp \$\$PACKAGE < $PACO_TMPFILE && \\ 342 + rm -f $PACO_TMPFILE; \\ 343 + fi; 302 + @\$(CHROOT1) 'find /lib -type l | paco -lp+ $PACKAGE' 344 303 +EOF 345 +) >> $MKFILE 304 +) >> $MKFILE.tmp 346 305 +fi 347 306 +} 348 +349 307 Index: common/paco-build-lfs.sh 350 308 =================================================================== … … 363 321 Index: common/common-functions 364 322 =================================================================== 365 --- common/common-functions (revision 2 695)323 --- common/common-functions (revision 2702) 366 324 +++ common/common-functions (working copy) 367 325 @@ -65,6 +65,9 @@ … … 375 333 Optimize [0-2] 376 334 0 = no optimization 377 @@ -5 81,6 +584,7 @@335 @@ -556,6 +559,7 @@ 378 336 --stringparam lc_all $LC_ALL \ 379 337 --stringparam keymap $KEYMAP \ … … 383 341 ;; 384 342 lfs) 385 @@ -5 92,6 +596,7 @@343 @@ -567,6 +571,7 @@ 386 344 --stringparam timezone $TIMEZONE \ 387 345 --stringparam page $PAGE \ … … 390 348 -o ./${PROGNAME}-commands/ $XSL $BOOK/index.xml >>$LOGDIR/$LOG 2>&1 391 349 ;; 392 blfs)350 *) exit 1 ;; 393 351 Index: HLFS/hlfs.xsl 394 352 =================================================================== 395 --- HLFS/hlfs.xsl (revision 2 695)353 --- HLFS/hlfs.xsl (revision 2702) 396 354 +++ HLFS/hlfs.xsl (working copy) 397 355 @@ -39,6 +39,9 @@ … … 444 402 Index: HLFS/master.sh 445 403 =================================================================== 446 --- HLFS/master.sh (revision 2 695)404 --- HLFS/master.sh (revision 2702) 447 405 +++ HLFS/master.sh (working copy) 448 @@ -254,6 +254,18 @@ 406 @@ -245,6 +245,11 @@ 407 # Keep the script file name 408 this_script=`basename $file` 409 410 + # If this script is *-paco, then skip it 411 + case $this_script in 412 + *paco ) continue ;; 413 + esac 414 + 415 # Skip this script depending on jhalfs.conf flags set. 416 case $this_script in 417 # We'll run the chroot commands differently than the others, so skip them in the 418 @@ -254,6 +259,18 @@ 449 419 *-stripping* ) [[ "$STRIP" = "0" ]] && continue ;; 450 420 esac … … 465 435 name=`echo $this_script | sed -e 's@[0-9]\{3\}-@@'` 466 436 467 @@ -324,7 +3 36,9 @@437 @@ -324,7 +341,9 @@ 468 438 wrt_run_as_root "${this_script}" "${file}" 469 439 ;; … … 475 445 esac 476 446 # 477 @@ -357,6 +37 1,16 @@447 @@ -357,6 +376,16 @@ 478 448 PREV=${this_script}${N} 479 449 # Set system_build envar for iteration targets … … 492 462 493 463 } 494 @@ -419,6 +44 3,15 @@464 @@ -419,6 +448,15 @@ 495 465 wrt_run_as_chroot2 "${this_script}" "${file}" 496 466 fi … … 510 480 Index: master.sh 511 481 =================================================================== 512 --- master.sh (revision 2 695)482 --- master.sh (revision 2702) 513 483 +++ master.sh (working copy) 514 484 @@ -147,6 +147,8 @@ … … 521 491 test $# = 1 && eval "$exit_missing_arg" 522 492 shift 523 @@ -4 63,6 +465,14 @@493 @@ -438,6 +440,14 @@ 524 494 [[ $VERBOSITY > 0 ]] && echo "OK" 525 495 fi … … 536 506 if [[ "$OPTIMIZE" != "0" ]]; then 537 507 [[ $VERBOSITY > 0 ]] && echo -n "Loading optimization module..." 538 @@ - 507,6 +517,15@@508 @@ -482,7 +492,11 @@ 539 509 # 540 510 if [[ "$PWD" != "$JHALFSDIR" ]]; then 541 511 cp $COMMON_DIR/makefile-functions $JHALFSDIR/ 542 + if [[ $USE_PACO != "0" ]] ; then 543 + if [[ $PROGNAME != "blfs" ]]; then 544 + cp $COMMON_DIR/paco-build-$PROGNAME.sh $JHALFSDIR/ 545 + else 546 + echo -e "export PACO_INCLUDE=$PACO_INCLUDE" > $JHALFSDIR/pacovars 547 + echo -e "export PACO_EXCLUDE=~/sources:$JHALFSDIR:$PACO_EXCLUDE" >> $JHALFSDIR/pacovars 548 + echo -e "export PACO_TMPFILE=$PACO_TMPFILE" >> $JHALFSDIR/pacovars 549 + fi 550 + fi 512 + # 513 + [[ $USE_PACO != "0" ]] && cp $COMMON_DIR/paco-build-$PROGNAME.sh $JHALFSDIR/ 514 + # 551 515 [[ "$OPTIMIZE" != "0" ]] && cp optimize/opt_override $JHALFSDIR/ 516 + # 552 517 if [[ "$COMPARE" != "0" ]] ; then 553 518 mkdir -p $JHALFSDIR/extras 519 cp extras/* $JHALFSDIR/extras
Note:
See TracChangeset
for help on using the changeset viewer.