output to a file


   I am compiling some packages and like to have "all" the compiling messages to be redirected to a file. I use "make xxx > log" or "make xxx 1 > log", but the file does not have all the logs...

   How to do the commands that can capture all the output on the screen to a file?
appstarAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

TimYatesCommented:
you can try:

    make xxx 1>out.txt 2>err.txt

or, you can use the "script" command:

    script output.txt
    make xxx
    exit
    cat output.txt

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
TimYatesCommented:
Duncan RoeSoftware DeveloperCommented:
You might find the script command is more to your liking than redirection. Do a "man script" for details.

I always use
(time nice make)2>&1|tee hee
- I have a record of how long it took
- the make is niced, so other interactive commands stay quick
- I can see what's happening in the xterm
- the hee file is a complete record of the process, errors and all

I keep the output from ./configure [config opts] in heeconf. I keep the configure line in confline - ready for the next release
make install -> heeinst. and so on...
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux OS Dev

From novice to tech pro — start learning today.