From 159663cebabbc8dcd94c2f64f110ca2536cf24fc Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Thu, 1 Aug 2013 08:53:06 +0200 Subject: [PATCH] Remove no longer needed HAIKU_STRIP_DEBUG_FROM_OPTIONAL_PACKAGES --- build/jam/DefaultBuildProfiles | 2 -- build/jam/ImageRules | 22 +++---------------- build/jam/UserBuildConfig.ReadMe | 4 ---- build/jam/images/HaikuCD | 1 - build/jam/images/HaikuImageCommon | 1 - build/scripts/build_haiku_image | 36 +------------------------------ build/scripts/build_haiku_package | 4 +--- 7 files changed, 5 insertions(+), 65 deletions(-) diff --git a/build/jam/DefaultBuildProfiles b/build/jam/DefaultBuildProfiles index a503c08903..066528cb7f 100644 --- a/build/jam/DefaultBuildProfiles +++ b/build/jam/DefaultBuildProfiles @@ -33,7 +33,6 @@ rule DefineDefaultBuildProfiles HAIKU_ROOT_USER_REAL_NAME = "Yourself" ; AddGroupToHaikuImage party : 101 : user sshd ; HAIKU_IMAGE_HOST_NAME = shredder ; - HAIKU_STRIP_DEBUG_FROM_OPTIONAL_PACKAGES = 1 ; HAIKU_IMAGE_SIZE = 800 ; AddHaikuImagePackages @@ -75,7 +74,6 @@ rule DefineDefaultBuildProfiles HAIKU_ROOT_USER_NAME = user ; HAIKU_ROOT_USER_REAL_NAME = "Yourself" ; AddGroupToHaikuImage party : 101 : user sshd ; - HAIKU_STRIP_DEBUG_FROM_OPTIONAL_PACKAGES = 1 ; HAIKU_IMAGE_HOST_NAME = shredder ; HAIKU_IMAGE_SIZE = 600 ; diff --git a/build/jam/ImageRules b/build/jam/ImageRules index f9846c0494..7440efcec3 100644 --- a/build/jam/ImageRules +++ b/build/jam/ImageRules @@ -412,7 +412,7 @@ rule ExtractArchiveToContainer container : directoryTokens : archiveFile # ExtractArchiveToContainer : : # : [ ] : ; # - # Supported flags: alwaysUpdate, stripDebugSymbols + # Supported flags: alwaysUpdate # If the container shall only be updated, we extract only, if explicitely # requested. @@ -423,14 +423,9 @@ rule ExtractArchiveToContainer container : directoryTokens : archiveFile local directory = [ AddDirectoryToContainer $(container) : $(directoryTokens) ] ; - local stripDebugSymbols ; - if stripDebugSymbols in $(flags) { - stripDebugSymbols = 1 ; - } ARCHIVE_FILES_TO_INSTALL on $(directory) += $(archiveFile) ; ARCHIVE_SUBDIR_TO_INSTALL_FROM on $(archiveFile) = $(extractedSubDir) ; - ARCHIVE_FILES_TO_STRIP on $(archiveFile) = $(stripDebugSymbols) ; } rule AddDriversToContainer container : relativeDirectoryTokens : targets @@ -799,11 +794,6 @@ rule CreateContainerExtractFilesScript container : script ARCHIVE_SUBDIR_TO_INSTALL_FROM on $(dummyTarget) = $(extractedSubDir:E=.) ; - local stripDebugSymbols = [ on $(archiveFile) - return $(ARCHIVE_FILES_TO_STRIP) ] ; - STRIP_DEBUG_SYMBOLS_FROM_ARCHIVE on $(dummyTarget) = - $(stripDebugSymbols) ; - Depends $(dummyTarget) : $(initScript) $(archiveFile) $(serializationDependency) ; Depends $(script) : $(dummyTarget) ; @@ -819,8 +809,7 @@ rule CreateContainerExtractFilesScript container : script actions AddExtractFileToContainerExtractFilesScript { echo extractFile "\"$(2[2])\"" "\"$(TARGET_DIR)\"" \ - "\"$(ARCHIVE_SUBDIR_TO_INSTALL_FROM)\"" \ - "\"$(STRIP_DEBUG_SYMBOLS_FROM_ARCHIVE)\"" >> $(2[1]) + "\"$(ARCHIVE_SUBDIR_TO_INSTALL_FROM)\"" >> $(2[1]) } @@ -1068,7 +1057,7 @@ rule InstallOptionalHaikuImagePackage url : dirTokens : flags # directory relative to the image's root directory where the content of # the archive will be extracted to. # - # Supported flags: cdPackage, stripDebugSymbols/!stripDebugSymbols + # Supported flags: cdPackage local package = $(url:BS) ; @@ -1087,11 +1076,6 @@ rule InstallOptionalHaikuImagePackage url : dirTokens : flags # copy onto image AddFilesToHaikuImage _packages_ : $(archiveFile) ; } else { - if $(HAIKU_STRIP_DEBUG_FROM_OPTIONAL_PACKAGES) = 1 - && ! stripDebugSymbols in $(flags) - && ! !stripDebugSymbols in $(flags) { - flags += stripDebugSymbols ; - } # extract onto image ExtractArchiveToHaikuImage $(dirTokens) : $(archiveFile) : $(flags) ; } diff --git a/build/jam/UserBuildConfig.ReadMe b/build/jam/UserBuildConfig.ReadMe index 2252fd9ab4..e51cb7963b 100644 --- a/build/jam/UserBuildConfig.ReadMe +++ b/build/jam/UserBuildConfig.ReadMe @@ -62,10 +62,6 @@ HAIKU_IMAGE_NAME = walter.image ; HAIKU_IMAGE_DIR = /tmp ; HAIKU_IMAGE_SIZE = 100 ; -# Enable stripping the debug symbols from optional packages. -# Note, some optional packages may override this to prevent stripping. -HAIKU_STRIP_DEBUG_FROM_OPTIONAL_PACKAGES = 1 ; - # Set image volume label to "Walter". Default label is "Haiku". HAIKU_IMAGE_LABEL = Walter ; diff --git a/build/jam/images/HaikuCD b/build/jam/images/HaikuCD index 6d1a2a99af..30b9afb461 100644 --- a/build/jam/images/HaikuCD +++ b/build/jam/images/HaikuCD @@ -27,7 +27,6 @@ AddTargetVariableToScript $(script) : rc ; AddTargetVariableToScript $(script) : resattr ; AddTargetVariableToScript $(script) : unzip ; AddTargetVariableToScript $(script) : generate_attribute_stores ; -AddVariableToScript $(script) : stripCommand : $(HAIKU_STRIP) ; if $(HOST_RM_ATTRS_TARGET) { AddTargetVariableToScript $(script) : $(HOST_RM_ATTRS_TARGET) : rmAttrs ; } else { diff --git a/build/jam/images/HaikuImageCommon b/build/jam/images/HaikuImageCommon index 66627895ee..dceb795ce9 100644 --- a/build/jam/images/HaikuImageCommon +++ b/build/jam/images/HaikuImageCommon @@ -83,7 +83,6 @@ AddTargetVariableToScript $(script) : get_package_dependencies : getPackageDependencies ; AddTargetVariableToScript $(script) : unzip ; AddTargetVariableToScript $(script) : vmdkimage ; -AddVariableToScript $(script) : stripCommand : $(HAIKU_STRIP) ; if $(HOST_RM_ATTRS_TARGET) { AddTargetVariableToScript $(script) : $(HOST_RM_ATTRS_TARGET) : rmAttrs ; } else { diff --git a/build/scripts/build_haiku_image b/build/scripts/build_haiku_image index 39fb725f65..a345e532ba 100755 --- a/build/scripts/build_haiku_image +++ b/build/scripts/build_haiku_image @@ -37,7 +37,6 @@ set -o errexit # The following is only for cd types: # generate_attribute_stores # isCD -# stripCommand # if [ $# -gt 0 ]; then . $1 @@ -148,27 +147,12 @@ else fi -stripDebugInfo() -{ - file="$1" - - # Determine whether the file is an ELF file by checking the ELF signature, - # or at least the printable characters. - elfMarker=`dd "if=$file" bs=1 skip=1 count=3 2> /dev/null` - if [ "$elfMarker" = 'ELF' ]; then - # make user-writable first -- some files aren't - chmod u+w "$file" - "$stripCommand" --strip-debug "$file" - fi -} - extractFile() { - # extractFile + # extractFile archiveFile=$1 targetExtractedDir=$2 extractedSubDir=$3 - stripDebugSymbols=$4 extractDir=$tmpDir/extract $rmAttrs -rf "$extractDir" @@ -205,24 +189,6 @@ extractFile() rm $extractDir/.OptionalPackageDescription fi - if [ "$stripDebugSymbols" = "1" ]; then - # strip executables in common/bin - if [ -d $extractDir/common/bin ]; then - for file in `find $extractDir/common/bin -type f -a -perm +100 \ - -a -size +1k`; do - stripDebugInfo "$file" - done - fi - - # strip libraries in common/lib - if [ -d $extractDir/common/lib ]; then - for file in `find $extractDir/common/lib -type f -a -size +1k \ - -a -name lib\*`; do - stripDebugInfo "$file" - done - fi - fi - $cp -r "${sPrefix}$extractDir/$extractedSubDir/." \ "${tPrefix}$targetExtractedDir" diff --git a/build/scripts/build_haiku_package b/build/scripts/build_haiku_package index d0d65093a2..46c1a20a0a 100755 --- a/build/scripts/build_haiku_package +++ b/build/scripts/build_haiku_package @@ -61,12 +61,10 @@ mkindex=mkindex extractFile() { - # extractFile + # extractFile archiveFile=$1 targetExtractedDir=$2 extractedSubDir=$3 - # Ignore stripDebugSymbols. It's not relevant here, since executables and - # libraries shouldn't come from zip files or other archives anymore. extractDir=$tmpDir/extract $rmAttrs -rf "$extractDir"