Dave's Brain

Browse - Computer Tips - How do I capture the output of a make command?

Date: 2010mar4
OS: Linux
Level: beginner

Q.  How do I capture the output of a make command?

A.  Do this:

make 2>log 1>&2
The output will be in file log. This captures both stdout and stderr. Stdout will say what's being compiled. More detail: This says put file 2 (stderr) into file "log" and put file 1 (stdout) in the same place as file 2 (stderr).

Add a comment

Sign in to add a comment
Copyright © 2008-2017, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.