From: <ges...@us...> - 2011-12-26 10:09:00
|
Revision: 6188 http://ipcop.svn.sourceforge.net/ipcop/?rev=6188&view=rev Author: gespinasse Date: 2011-12-26 10:08:54 +0000 (Mon, 26 Dec 2011) Log Message: ----------- Hide strip error message with non ELF files using grep -v 'File format not recognized' Use xargs strip as this is faster than starting strip for each file Gain is not so visible on update as there is usually not a big number of files to stripe. As xargs strip know strip fail for non ELF files, use '|| true' to hide that. Use same '|| true' construction for tar as that avoid an 'Error 1 (ignored)' message in cas update is still empty. Modified Paths: -------------- ipcop/trunk/lfs/update Modified: ipcop/trunk/lfs/update =================================================================== --- ipcop/trunk/lfs/update 2011-12-26 09:59:15 UTC (rev 6187) +++ ipcop/trunk/lfs/update 2011-12-26 10:08:54 UTC (rev 6188) @@ -66,16 +66,12 @@ tar -c --files-from=$(IPCOP_UPDATE_DIR)/ROOTFILES.${MACHINE}-${PASS} \ -f /tmp/patch.tar --exclude='#*' cd /tmp && tar -xf /tmp/patch.tar && rm /tmp/patch.tar - # same code as cdrom except allow find to fail as files are not necessary present - -cd /tmp && find ./{bin,sbin} -type f -exec /$(TOOLS_DIR)/bin/strip --strip-all {} \; - # kernel modules are compressed, so no risk actually to strip them - -cd /tmp && find ./lib/{.,iptables,udev} -maxdepth 1 -type f -exec /$(TOOLS_DIR)/bin/strip --strip-all {} \; - -cd /tmp && find ./usr/{bin,lib,libexec,local,sbin} -type f -exec /$(TOOLS_DIR)/bin/strip --strip-all {} \; -ifeq "$(MACHINE)" "i486" - -cd /tmp && find ./etc/Conexant -type f -exec /$(TOOLS_DIR)/bin/strip --strip-all {} \; -endif + # Same stripping code as lfs/cdrom plus hide empty path from find that may happen + cd /tmp && find ${EXEC_PATH} -type f 2>/dev/null | xargs /$(TOOLS_DIR)/bin/strip --strip-all 2>&1 | \ + grep -v 'File format not recognized' || true + # allow tar to fail when nothing yet is include in update - -cd /tmp && tar -cz --exclude=/tmp/patch.tar.gz -f /tmp/patch.tar.gz * + cd /tmp && tar -cz --exclude=/tmp/patch.tar.gz -f /tmp/patch.tar.gz * || true # now remove everything except the package as other files are inside find /tmp/* -not -name patch.tar.gz -delete This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |