Make mklib propogate all errors
authorJon TURNEY <jon.turney@dronecode.org.uk>
Thu, 18 Feb 2010 19:25:56 +0000 (19:25 +0000)
committerBrian Paul <brianp@vmware.com>
Thu, 18 Feb 2010 19:47:01 +0000 (12:47 -0700)
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
bin/mklib

index 2ef902287d2c30bc23507627b1c535dd14c44ce7..68d22052c94b3ee14bed71b501fb53e3ab3e1f37 100755 (executable)
--- a/bin/mklib
+++ b/bin/mklib
 # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
+# propagate any errors
+function errtrap {
+    es=$?
+    exit $es
+}
+trap errtrap ERR
 
 # Given a list of files, look for .a archives and unpack them.
 # Return the original list of files minus the .a files plus the unpacked files.