tools/strip: Add utility

master
Mike Gerwitz 2017-05-16 10:54:05 -04:00
parent b7596515b3
commit 652465a0a0
3 changed files with 15 additions and 4 deletions

View File

@ -93,11 +93,11 @@
<xsl:if test="$debugval = 'yes' or $debug-force">
<xsl:text>; </xsl:text>
<xsl:text>( debug['</xsl:text>
<xsl:text>/*!+*/( debug['</xsl:text>
<xsl:value-of select="@_id" />
<xsl:text>'] || ( debug['</xsl:text>
<xsl:value-of select="@_id" />
<xsl:text>'] = [] ) ).push( result ); </xsl:text>
<xsl:text>'] = [] ) ).push( result );/*!-*/ </xsl:text>
<xsl:text>return result; </xsl:text>
<xsl:text>} )() </xsl:text>

View File

@ -918,11 +918,11 @@
<text>;</text>
<text>( debug['</text>
<text>/*!+*/( debug['</text>
<value-of select="@_id" />
<text>'] || ( debug['</text>
<value-of select="@_id" />
<text>'] = [] ) ).push( tmp ); </text>
<text>'] = [] ) ).push( tmp );/*!-*/ </text>
<text>result = </text>

11
tools/strip 100755
View File

@ -0,0 +1,11 @@
#!/bin/bash
#
# Strip debugging information from object files and executables.
#
# Analogous to GNU strip used for ELF and other binary formats.
# Note that calculation breakdowns will not work after stripping.
##
# debug assignments
sed -i 's#/\*!+\*/[^!]\+/\*!-\*/##g' ui/package.js